|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.vaadin.terminal.gwt.client.EventHelper
public class EventHelper
Helper class for attaching/detaching handlers for Vaadin client side components, based on identifiers in UIDL. Helpers expect Paintables to be both listeners and sources for events. This helper cannot be used for more complex widgets.
Possible current registration is given as parameter. The returned registration (possibly the same as given, should be store for next update.
Pseudocode what helpers do:
if paintable has event listener in UIDL if registration is null register paintable as as handler for event return the registration else if registration is not null remove the handler from paintable return null
Constructor Summary | |
---|---|
EventHelper()
|
Method Summary | ||
---|---|---|
static
|
updateBlurHandler(T connector,
com.google.gwt.event.shared.HandlerRegistration handlerRegistration)
Adds or removes a blur handler depending on if the connector has blur listeners on the server side or not. |
|
static
|
updateFocusHandler(T connector,
com.google.gwt.event.shared.HandlerRegistration handlerRegistration)
Adds or removes a focus handler depending on if the connector has focus listeners on the server side or not. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public EventHelper()
Method Detail |
---|
public static <T extends ComponentConnector & com.google.gwt.event.dom.client.FocusHandler> com.google.gwt.event.shared.HandlerRegistration updateFocusHandler(T connector, com.google.gwt.event.shared.HandlerRegistration handlerRegistration)
connector
- The connector to update. Must implement focusHandler.handlerRegistration
- The old registration reference or null no handler has been
registered previously
public static <T extends ComponentConnector & com.google.gwt.event.dom.client.BlurHandler> com.google.gwt.event.shared.HandlerRegistration updateBlurHandler(T connector, com.google.gwt.event.shared.HandlerRegistration handlerRegistration)
connector
- The connector to update. Must implement BlurHandler.handlerRegistration
- The old registration reference or null no handler has been
registered previously
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |