congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
Element.dispatchEvent
Code IndexAdd Tabnine to your IDE (free)

How to use
dispatchEvent
method
in
com.google.gwt.user.client.Element

Best Java code snippets using com.google.gwt.user.client.Element.dispatchEvent (Showing top 11 results out of 315)

origin: com.google.gwt/gwt-servlet

/**
 * Called when the user finishes clicking on this button. The default behavior
 * is to fire the click event to listeners. Subclasses that override
 * {@link #onClickStart()} should override this method to restore the normal
 * widget display.
 */
protected void onClick() {
 // Allow the click we're about to synthesize to pass through to the
 // superclass and containing elements. Element.dispatchEvent() is
 // synchronous, so we simply set and clear the flag within this method.
 allowClick = true;
 // Mouse coordinates are not always available (e.g., when the click is
 // caused by a keyboard event).
 NativeEvent evt = Document.get().createClickEvent(1, 0, 0, 0, 0, false,
   false, false, false);
 getElement().dispatchEvent(evt);
 allowClick = false;
}
origin: geogebra/geogebra

/**
 * Called when the user finishes clicking on this button. The default
 * behavior is to fire the click event to listeners. Subclasses that
 * override {@link #onClickStart()} should override this method to restore
 * the normal widget display.
 */
protected void onClick() {
  // Allow the click we're about to synthesize to pass through to the
  // superclass and containing elements. Element.dispatchEvent() is
  // synchronous, so we simply set and clear the flag within this method.
  allowClick = true;
  // Mouse coordinates are not always available (e.g., when the click is
  // caused by a keyboard event).
  NativeEvent evt = Document.get().createClickEvent(1, 0, 0, 0, 0, false,
      false, false, false);
  getElement().dispatchEvent(evt);
  allowClick = false;
}
origin: net.wetheinter/gwt-user

/**
 * Called when the user finishes clicking on this button. The default behavior
 * is to fire the click event to listeners. Subclasses that override
 * {@link #onClickStart()} should override this method to restore the normal
 * widget display.
 */
protected void onClick() {
 // Allow the click we're about to synthesize to pass through to the
 // superclass and containing elements. Element.dispatchEvent() is
 // synchronous, so we simply set and clear the flag within this method.
 allowClick = true;
 // Mouse coordinates are not always available (e.g., when the click is
 // caused by a keyboard event).
 NativeEvent evt = Document.get().createClickEvent(1, 0, 0, 0, 0, false,
   false, false, false);
 getElement().dispatchEvent(evt);
 allowClick = false;
}
origin: com.vaadin.external.gwt/gwt-user

/**
 * Called when the user finishes clicking on this button. The default behavior
 * is to fire the click event to listeners. Subclasses that override
 * {@link #onClickStart()} should override this method to restore the normal
 * widget display.
 */
protected void onClick() {
 // Allow the click we're about to synthesize to pass through to the
 // superclass and containing elements. Element.dispatchEvent() is
 // synchronous, so we simply set and clear the flag within this method.
 allowClick = true;
 // Mouse coordinates are not always available (e.g., when the click is
 // caused by a keyboard event).
 NativeEvent evt = Document.get().createClickEvent(1, 0, 0, 0, 0, false,
   false, false, false);
 getElement().dispatchEvent(evt);
 allowClick = false;
}
origin: sk.seges.acris/acris-recorder-client-core

public void fireEvent() {
  prepareEvent();
  NativeEvent event = createEvent(el);
  if (el != null) {
    el.dispatchEvent(event);
  } else {
    //well, probably generated id - bad luck
    GWT.log("Element was not found for event: " + toString(true, false));
  }
}
origin: com.vaadin.addon/vaadin-touchkit-agpl

public void onTouchEnd(TouchEndEvent event) {
  if (touchStarted) {
    event.preventDefault();
    event.stopPropagation();
    NativeEvent nativeEvent = event.getNativeEvent();
    NativeEvent evt = Document.get().createClickEvent(1,
        nativeEvent.getScreenX(), nativeEvent.getScreenY(),
        nativeEvent.getClientX(), nativeEvent.getClientY(), false,
        false, false, false);
    getElement().dispatchEvent(evt);
    touchStarted = false;
    fastClickAt = new Date();
  }
}
origin: com.vaadin.addon/vaadin-touchkit-agpl

@Override
public void onTouchEnd(TouchEndEvent event) {
  if (touchStarted) {
    event.preventDefault();
    event.stopPropagation();
    NativeEvent nativeEvent = event.getNativeEvent();
    NativeEvent evt = Document.get().createClickEvent(1,
        nativeEvent.getScreenX(), nativeEvent.getScreenY(),
        nativeEvent.getClientX(), nativeEvent.getClientY(), false,
        false, false, false);
    getElement().dispatchEvent(evt);
    touchStarted = false;
    fastClickAt = new Date();
  }
}
origin: dennisjzh/GwtMobile-UI

public static void loadUrl(String url) {
  Anchor a = new Anchor("", url);
  RootLayoutPanel.get().add(a);
  NativeEvent event = Document.get().createClickEvent(1, 1, 1, 1, 1, false, false, false, false);
  a.getElement().dispatchEvent(event);
  RootLayoutPanel.get().remove(a);
}
origin: info.magnolia.ui/magnolia-ui-vaadin-common-widgets

  @Override
  public void onMultiTap(MultiTapEvent event) {
    if (BrowserInfo.get().isTouchDevice()) {
      final NativeEvent doubleClickEvent =
          Document.get().createDblClickEvent(
              0,
              event.getTouchStarts().get(0).get(0).getPageX(),
              event.getTouchStarts().get(0).get(0).getPageY(),
              event.getTouchStarts().get(0).get(0).getPageX(),
              event.getTouchStarts().get(0).get(0).getPageY(),
              false,
              false,
              false,
              false);
      getElement().dispatchEvent(doubleClickEvent);
    }
  }
}, MultiTapEvent.getType());
origin: com.haulmont.cuba/cuba-web-toolkit

target.getElement().dispatchEvent(createMouseDownEvent(event));
return null;
origin: org.vaadin.addons/dragdroplayouts

target.getElement().dispatchEvent(createMouseDownEvent(event));
return null;
com.google.gwt.user.clientElementdispatchEvent

Popular methods of Element

  • getStyle
  • setAttribute
  • appendChild
  • setId
  • getParentElement
  • cast
  • setInnerText
  • getId
  • setInnerHTML
  • addClassName
  • getAttribute
  • getInnerHTML
  • getAttribute,
  • getInnerHTML,
  • getFirstChildElement,
  • getInnerText,
  • getClientWidth,
  • removeChild,
  • getChildCount,
  • getOffsetHeight,
  • removeAttribute,
  • removeClassName

Popular in Java

  • Running tasks concurrently on multiple threads
  • findViewById (Activity)
  • requestLocationUpdates (LocationManager)
  • onRequestPermissionsResult (Fragment)
  • OutputStream (java.io)
    A writable sink for bytes.Most clients will use output streams that write data to the file system (
  • String (java.lang)
  • Selector (java.nio.channels)
    A controller for the selection of SelectableChannel objects. Selectable channels can be registered w
  • HttpServlet (javax.servlet.http)
    Provides an abstract class to be subclassed to create an HTTP servlet suitable for a Web site. A sub
  • JTable (javax.swing)
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,
  • From CI to AI: The AI layer in your organization
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now