Reputation: 757
Here's the code:
public class MyEntryPoint implements EntryPoint {
PopupPanel popupPanel = new PopupPanel(false,true);
FocusPanel focusPanel = new FocusPanel();
VerticalPanel popupContent = new VerticalPanel();
public void onModuleLoad() {
popupContent.add(new Label("Simple popup test"));
popupContent.add(new Label("_"));
focusPanel.add(popupContent);
popupPanel.setWidget(focusPanel);
popupPanel.center();
focusPanel.addMouseWheelHandler(new MouseWheelHandler(){
public void onMouseWheel(MouseWheelEvent event) {
System.out.println("deltaY = " + event.getDeltaY());
}
});
}
}
If you run a GWT app in Firefox, move your mouse over the text "Simple popup test" and scroll the mouse wheel, then onMouseWheel will be called.
If this application is running in Chrome or Safari, place your mouse over the text "Simple popup test" and scroll the mouse wheel, then onMouseWheel not called. If you place the mouse cursor is not on the GWT Label and scroll the mouse wheel, the event will be called onMouseWheel.
Maybe someone has already corrected this? Thank you very much.
Upvotes: 0
Views: 880
Reputation: 1462
The Bug can be found on the GWT issue tracker:
http://code.google.com/p/google-web-toolkit/issues/detail?id=7349
There is a link to a Google goups discussion in the issue text.
I solved the problem by set the popup to modal = false.
Upvotes: 0