Re: unresolved overloaded function signal
- From: "Paulo Flabiano Smorigo" <pfsmorigo gmail com>
- To: "klaus triendl" <klaus triendl eu>
- Cc: gtkmm-list <gtkmm-list gnome org>
- Subject: Re: unresolved overloaded function signal
- Date: Fri, 3 Oct 2008 09:52:14 -0300
Hi everybody.
Now if one of the functions don't have atributes, like:
void Red::test(int value);
void Red::test(char* value);
void Red::test(); <---
How would be the signal line?
Thanks...
Paulo Flabiano Smorigo
On Tue, Sep 16, 2008 at 17:46, klaus triendl
<klaus triendl eu> wrote:
Paulo Flabiano Smorigo schrieb:
Hi everyone,
I have a signal in my code like this:
button.signal_clicked().connect(sigc::bind<int>( sigc::mem_fun(*this, &Red::setNumber), 1));
And two overloaded functions:
void Red::setNumber(int value);
void Red::setNumber(char* value);
When compile gives me an "unresolved overloaded function signal" error.
How can I fix this?
By specifying the member function's argument type to mem_fun<>:
button.signal_clicked().connect(sigc::bind(sigc::mem_fun<int>(*this, &Red::setNumber), 1));
Klaus Triendl
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]