[Gtk-sharp-list] OnMotionEvent question...
Frank Ramsay
fjramsay1234 at hotmail.com
Sun Sep 24 07:16:27 EDT 2006
I have a custom widged (derived from gtk.button) and I'm seeing something
that seems strange.
The OnMotionEvent only seems to be triggered when there is a second mouse
event happening, ie on a click, enter, leave (only if button depressed),
etc.
How do I get notified of all mouse movement when the mouse is in the widget?
you can see this behavior with this:
public class testButton: Gtk.Button
{
public testButton() : base ("")
{
this.Events = Gdk.EventMask.AllEventsMask;
}
protected override bool OnMotionNotifyEvent(Gdk.EventMotion evnt)
{
this.Label = string.Format("X:{0} Y:{1}",evnt.X, evnt.Y);
return false;
}
}
-frank
Frank J. Ramsay
fjramsay1234 at hotmail.com
More information about the Gtk-sharp-list
mailing list