Re: a slot problem!
- From: Matthew Ryan Hurne <matthew hurne gmail com>
- To: Slim He <slimxp gmail com>
- Cc: gtkmm-list gnome org
- Subject: Re: a slot problem!
- Date: Sun, 26 Dec 2004 10:24:29 -0500
On Sun, 2004-12-26 at 21:27 +0800, Slim He wrote:
> I just started a study about gtkmm under windows,using dev-cpp.I like
> it very much.When reading the gtkmm.sourceforge.net online book
> ---"Programming with gtkmm" ,I found a problem.
> At the fourth chapter,the first example "buttons" shows some
> mistakes.The compliing prompt message is these:
>
> m_button.signal_clicked().connect( SigC::slot(*this,
> &ExampleWindow::on_button_clicked) );
>
> 19 D:\gtkmm\examplewindow\examplewindow.cc
> `slot' undeclared in namespace `SigC'
>
> I don't why the 'slot' is undeclared in 'SigC',
> Help please,thanks a lot!
> _______________________________________________
> gtkmm-list mailing list
> gtkmm-list gnome org
> http://mail.gnome.org/mailman/listinfo/gtkmm-list
That is for libsigc++ 1.x. In 2.x, the namespace is sigc (all
lowercase), and there isn't a public slot function that I know of - for
the example you will need to use sigc::mem_fun(). I also had to figure
this out as I was reading through the tutorial book. Check which
libsigc++ you are using - if you are using Gtkmm 2.4 then you have to be
using libsigc++ 2.x.
HTH,
Matt
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]