Monday, February 29, 2016

Several GWT modules on one page and RootPanel.get().addDomHandler()

Hi All,

I have a problem with several GWT modules on one page which all try to register a keydown handler on the page body element.
The problem seems to be that only one GWT module can call RootPanel.get() which will be perform a DOM.setListener() on the body.
The second call of RootPanel.get() from another model will overwrite the body.__listener so that com.google.gwt.user.client.impl.DOMImpl#getEventListener 
doesn't work anymore for all GWT modules (of course because the connection between dom and widget was overwritten)

My current solution is to add all handler for the body element using JSNI which is a little bit ugly!
So other / better ideas?

BR
Rocco

   

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at https://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment