Package com.googlecode.mgwt.dom.client.event.tap

Examples of com.googlecode.mgwt.dom.client.event.tap.TapHandler


  @Override
  protected void onAttach() {
    super.onAttach();

    clearButtonHandler = clearButton.addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        clearSearchField();
      }
View Full Code Here


          handleSwipeEnd(event);

        }
      });

      touchContainer.addTapHandler(new TapHandler() {

        @Override
        public void onTap(TapEvent event) {
          handleTap(event);
        }
View Full Code Here

    textLabel = new HTML();
    dialogPanel.getContent().add(textLabel);
    popinDialog.add(dialogPanel);

    dialogPanel.getOkButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        popinDialog.hide();
      }
View Full Code Here

   * @param callback - the callback that is called when the user clicks the ok button (can be null)
   */
  public static Dialog alert(String title, String text, final AlertCallback callback) {
    AlertDialog alertDialog = new AlertDialog(DEFAULT_APPEARANCE, title, text);

    alertDialog.addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        if (callback != null) {
          callback.onButtonPressed();
View Full Code Here

    textLabel = new Label();
    dialogPanel1.getContent().add(textLabel);
    popinDialog.add(dialogPanel1);

    dialogPanel1.getOkButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        popinDialog.hide();
        if (ConfirmDialog.this.callback != null)
          ConfirmDialog.this.callback.onOk();
      }
    });

    dialogPanel1.getCancelButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        popinDialog.hide();
        if (ConfirmDialog.this.callback != null)
View Full Code Here

          DOM.setCapture(getElement());
        }
      }
    });

    addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        removeStyleName(ButtonBase.this.baseAppearance.css().active());
      }
View Full Code Here

  @Override
  public void add(Widget w) {

    final WidgetListEntry widgetListEntry = new WidgetListEntry(this.appearance);
    widgetListEntry.setWidget(w);
    HandlerRegistration handlerRegistration = widgetListEntry.addTapHandler(new TapHandler() {
      @Override
      public void onTap(TapEvent event) {
        SelectionEvent.fire(WidgetList.this, container.getWidgetIndex(widgetListEntry));
      }
    });
View Full Code Here

  @Override
  protected void onAttach() {
    super.onAttach();

    clearButtonHandler = clearButton.addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        clearSearchField();
      }
View Full Code Here

    view.setTitle("Animation");
    animations = createAnimations();
    view.setAnimations(animations);

    addHandlerRegistration(view.getBackButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        ActionEvent.fire(eventBus, ActionNames.BACK);
View Full Code Here

    super.start(panel, eventBus);
    final PopupView view = clientFactory.getPopupView();

    view.getHeader().setText("Popups");

    addHandlerRegistration(view.getConfirmButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        view.confirmSomeStuff("Confirm this", "Confirm some more stuff", new ConfirmCallback() {

          @Override
          public void onOk() {

          }

          @Override
          public void onCancel() {

          }
        });

      }
    }));

    addHandlerRegistration(view.getSlideUpButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        List<OptionsDialogEntry> list = new ArrayList<OptionsDialogEntry>();
        list.add(new OptionsDialogEntry("Confirm", ButtonType.CONFIRM));
        list.add(new OptionsDialogEntry("Cancel", ButtonType.NORMAL));
        list.add(new OptionsDialogEntry("Delete", ButtonType.IMPORTANT));

        view.showSomeOptions(list, new OptionCallback() {

          @Override
          public void onOptionSelected(int index) {

          }
        });
      }
    }));

    addHandlerRegistration(view.getAlertButton().addTapHandler(new TapHandler() {

      @Override
      public void onTap(TapEvent event) {
        view.alertSomeStuff("Hi", "How are you doing?");
      }
View Full Code Here

TOP

Related Classes of com.googlecode.mgwt.dom.client.event.tap.TapHandler

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.