How to get the "released" signal of a mouse click in a window?



Hi,

I have a scrolled window inside a window and I am
connecting the "pressed" and "released" mouse button
signals to their respective handling functions. While
I get the pressed signal, I can not get the release
signal. I've tried things like:

  gtk_widget_add_events(mainwin,
GDK_BUTTON_PRESS_MASK);
//  gtk_widget_add_events(mainwin,
GDK_ALL_EVENTS_MASK);
  gtk_widget_add_events(mainwin,
GDK_FOCUS_CHANGE_MASK);
  
  gtk_widget_add_events(background,
GDK_POINTER_MOTION_MASK);	
  gtk_signal_connect(GTK_OBJECT(mainwin),
"button_press_event",
GTK_SIGNAL_FUNC(button_press_event), 0);  
  gtk_signal_connect(GTK_OBJECT(mainwin),
"button_release_event",
GTK_SIGNAL_FUNC(button_release_event), 0);    

And all its combinations, all in vain.

Any help would be greatly appreciated.

Rick

__________________________________________________
Do You Yahoo!?
LAUNCH - Your Yahoo! Music Experience
http://launch.yahoo.com



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