Java Code Examples for com.google.gwt.user.client.Element#as()
The following examples show how to use
com.google.gwt.user.client.Element#as() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ListPopupPanel2.java From consulo with Apache License 2.0 | 5 votes |
/** See class docs */ @Override public void onPreviewNativeEvent(Event.NativePreviewEvent nativePreviewEvent) { if (nativePreviewEvent.getTypeInt() != Event.ONCLICK) { return; } Element source = (Element) Element.as(nativePreviewEvent.getNativeEvent().getEventTarget()); if (!DOM.isOrHasChild(getElement(), source) && !DOM.isOrHasChild(getComboBox().getElement(), source)) { hide(); getComboBox().getChoiceButton().setDown(false); } }
Example 2
Source File: MobileUniversalPopup.java From swellrt with Apache License 2.0 | 4 votes |
/** Helper function to create a DivElement with a given style name */ private Element createDiv(String style) { DivElement x = Document.get().createDivElement(); x.setClassName(style); return (Element) Element.as(x); }
Example 3
Source File: MobileUniversalPopup.java From incubator-retired-wave with Apache License 2.0 | 4 votes |
/** Helper function to create a DivElement with a given style name */ private Element createDiv(String style) { DivElement x = Document.get().createDivElement(); x.setClassName(style); return (Element) Element.as(x); }