I'm using GWT 2.0.3 and using UiBinder am adding a composite to the
RootPanel. The composite contains some PushButtons which I am defining
fully using UiBinder with g:upFace, g:upHoveringFace and g:downFace.
The issue is that it's very easy to "fool" all of these buttons just
by moving the mouse quickly across them - they stay in the hover state
and even have the "gwt-PushButton-up-hovering" CSS class attached.
If I replace a button with an Image and add my own code for mouse
over, mouse out and mouse up it works absolutely fine and I'm not able
to "fool" the fake button. Obviously though I'd like to use the built
in widgets as they provide at lot of added extras such as
accessibility (amongst other things).
Looking at the source code for CustomButton which PushButton extends,
I can't understand line 623-631 (in current trunk but has been there
for a while). I think there are more situations where setHovering
should be set to false but I may be misunderstanding the isOrHasChild/
eventGetTarget methods.
case Event.ONMOUSEOUT:
Element to = DOM.eventGetToElement(event);
if (DOM.isOrHasChild(getElement(), DOM.eventGetTarget(event))
&& (to == null || !DOM.isOrHasChild(getElement(), to))) {
if (isCapturing) {
onClickCancel();
}
setHovering(false);
}
break;
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-web-toolkit?hl=en.