[gtkmm] Re: [gtkmm] RadioElem Signal



>How to select the right one ?
>Working with something like flags or semaphore in the callback ?

The radio button itself provides the flag. Its the get_active()
method. You can check it in your signal handler. If it returns
true the button has been selected. If it returns false the
button has been unselected.

You have to get the widget from the toolbar. RadioElem is just
a helper to build the button.

e.g. m_Toolbar.tools()[1].get_widget()->get_active()
or you store the the widget in a class-member right after creating
it
e.g. m_VertexButton = m_toolbar.tools().back ().get_widget();
     m_VertexButton->get_active() (in your callback)

 Andreas



________________________________________
Online Fotoalben - jetzt kostenlos bei http://www.ePost.de





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