Hi,
I have an Fl_GL_Window where I need to override the handle() and test
for FL_ENTER and FL_LEAVE events.
However I am getting a lot of dummy FL_LEAVE events for which I need
extra testing if the mouse *really* leaves the window.
Even more the Fl::event_inside(this), Fl::event_x(), Fl::event_y() give
me inconsistent results an I have to make a workaround and use something
like:
case FL_LEAVE:{
int X = Fl::event_x_root() - top_window->x() - x();
int Y = Fl::event_y_root() - top_window->y() - y();
if(X<0 || X>w() || Y<0 || Y>h()){
... // really leaving
}else{
... // not really leaving
}
}
which seems to work fine.
My question is:
Is event_x() and event_y() supposed to be set during FL_LEAVE and
relative to which window (parent, or the window itself)?
Is getting these dummy FL_LEAVE events (which exceed the number of
FL_ENTER events) a bug?
Has homebody else experienced this?
Using 1.1.9.
Thanks,
R.
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk