Re: [gtkmm] right-click in declarated Gtk::TreeView



On Mon, 2004-06-07 at 21:43 +0200, B.Hakvoort wrote:
> On Mon, 2004-06-07 at 16:49, Murray Cumming wrote:
> > You might experiment with connect(slot , true /* before */), which needs
> > a return value for the slot.
> 
> Could you elaborate a bit please? i tried:
> -----------------------------------------------------------------
> treeview.signal_button_press_event().connect_notify( 
> sigc::mem_fun(*this, &DetailWindow::treeview_click), true );
> -----------------------------------------------------------------
> and my treeview_click() wasn't called anymore. using false instead of
> true results in the same behaviour as described in my first mail.

Did you experiment with the return values (true or false) of your signal
handler?:
http://www.gtkmm.org/docs/gtkmm-2.4/docs/tutorial/html/apbs06.html

> I experimented a bit with connect instead of connect_notify and changed
> return value from void to boolean and back. But nothing helps
> 
> What exactly is the difference between connect and connect_notify()  ? 
> 
> I think i can create a workaround for this by using
> signal_cursor_changed icw signal_button_press_event, but i'd rather
> prefer the clean way by calling the normal handler for such clickevent
> and THEN execute my code.

-- 
Murray Cumming
murrayc murrayc com
www.murrayc.com





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