Re: [gtk-list] Problems with gtk-- Gtk_Main::idle



Lukas Knutsson <lukas@spray.se> writes:
> This has me stumped ! What am I missing here? The following code fragment
> below does not compile. Anybody have any suggestions ? This problem appears
> so simple am I sure that I have misunderstood something here.
>   connect_to_method(Gtk_Main::idle, &app, &(MyApp::duh));

connect_to_method(Gtk_Main::idle(), &app, &(MyApp::duh));

> This genrates an error message that says roughly,
> 
> ..no matching function for call to connect_to_method

Yup, the signature was wrong... idle() and timeout() are methods in
Gtk_Main, not variables. (this allows passing arguments to timeout()
and calling gtk_timeout_add() inside it...)

-- 
-- Tero Pulkkinen -- terop@modeemi.cs.tut.fi --



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]