Package com.google.gwt.event.dom.client

Examples of com.google.gwt.event.dom.client.MouseDownHandler


    this.handle = handle;
    this.appearance = appearance;

    dragWidgetElement = dragWidget.getElement().cast();

    handler = new MouseDownHandler() {
      @Override
      public void onMouseDown(MouseDownEvent event) {
        Draggable.this.onMouseDown(event);
      }
    };
View Full Code Here


        titleBar.closeButton.addClickHandler( new ClickHandler() {
            public void onClick(ClickEvent event) {
                hide();
            }
        } );
        titleBar.addMouseDownHandler( new MouseDownHandler() {

            public void onMouseDown(MouseDownEvent event) {
                dragged = true;
                dragStartX = event.getRelativeX( getElement() );
                dragStartY = event.getRelativeY( getElement() );
View Full Code Here

    public VDragAndDropWrapper() {
        super();
        hookHtml5Events(getElement());
        setStyleName(CLASSNAME);

        addDomHandler(new MouseDownHandler() {

            @Override
            public void onMouseDown(final MouseDownEvent event) {
                if (getConnector().isEnabled()
                        && event.getNativeEvent().getButton() == Event.BUTTON_LEFT
View Full Code Here

                Button.this.removeStyleDependentName(FACE_DOWN_CSS_CLASS);
            }
        }));

        // Change to the "down" face when the button is pressed
        internalHandlerRegistration.addRegistration(addMouseDownHandler(new MouseDownHandler() {
            public void onMouseDown(MouseDownEvent event) {
                Button.this.addStyleDependentName(FACE_DOWN_CSS_CLASS);
            }
        }));
View Full Code Here

      public void onClick(ClickEvent event) {
        doClick();
      }
    }, ClickEvent.getType());
   
    this.addDomHandler(new MouseDownHandler() {
     
      @Override
      public void onMouseDown(MouseDownEvent event) {
        if (event.getNativeButton() == NativeEvent.BUTTON_MIDDLE) {
          doClick();
View Full Code Here

    this.selectionMode = mode;
    if (boundarySelectionHandler != null) {
      boundarySelectionHandler.removeHandler();
    }

    boundarySelectionHandler = this.boundaryPanel.addDomHandler(new MouseDownHandler() {

      public void onMouseDown(MouseDownEvent event) {

        int mouseLeft = event.getX();
        int mouseTop = event.getY();
View Full Code Here

              }
            }
          };
        });
   
    ((HasMouseDownHandlers)display.getDragWidget()).addMouseDownHandler(new MouseDownHandler(){
      public void onMouseDown(MouseDownEvent event) {
        onDragMouseDown(event);
      }     
    });
   
    ((HasMouseMoveHandlers)display.getDragWidget()).addMouseMoveHandler(new MouseMoveHandler(){
      public void onMouseMove(MouseMoveEvent event) {
        onDragMouseMove(event);
      }     
    });
   
    ((HasMouseUpHandlers)display.getDragWidget()).addMouseUpHandler(new MouseUpHandler(){
      public void onMouseUp(MouseUpEvent event) {
        onDragMouseUp(event);
      }     
    });
   
    ((HasMouseDownHandlers)display.getScaleWidget()).addMouseDownHandler(new MouseDownHandler() {
      public void onMouseDown(MouseDownEvent event) {
        onScaleMouseDown(event);
      }
    });
   
    ((HasMouseDownHandlers)display.getRootWidget()).addMouseDownHandler(new MouseDownHandler() {
      public void onMouseDown(MouseDownEvent event) {
        onRootMouseDown(event);
      }
    })
   
    ((HasMouseOverHandlers)display.getRootWidget()).addMouseOverHandler(new MouseOverHandler() {
      public void onMouseOver(MouseOverEvent event) {
        onRootMouseOver(event);
      }
    })

    ((HasMouseOutHandlers)display.getRootWidget()).addMouseOutHandler(new MouseOutHandler() {
      public void onMouseOut(MouseOutEvent event) {
        onRootMouseOut(event);
      }
    })
   
    ArrayList<Widget> lessWidgets = display.getLessWidgets();
    if (lessWidgets != null) {
      for (int i = 0; i < lessWidgets.size(); i++) {
        ((HasMouseDownHandlers) lessWidgets.get(i))
            .addMouseDownHandler(new MouseDownHandler() {
              public void onMouseDown(MouseDownEvent event) {
                onLessMouseDown(event);
              }
            });
      }
    }

    ArrayList<Widget> moreWidgets = display.getMoreWidgets();
    if (moreWidgets != null) {
      for (int i = 0; i < moreWidgets.size(); i++) {
        ((HasMouseDownHandlers) moreWidgets.get(i))
            .addMouseDownHandler(new MouseDownHandler() {
              public void onMouseDown(MouseDownEvent event) {
                onMoreMouseDown(event);
              }
            });
      }
View Full Code Here

    public VDragAndDropWrapper() {
        super();
        hookHtml5Events(getElement());
        setStyleName(CLASSNAME);
        addDomHandler(new MouseDownHandler() {
            public void onMouseDown(MouseDownEvent event) {
                if (startDrag(event.getNativeEvent())) {
                    event.preventDefault(); // prevent text selection
                }
            }
View Full Code Here

        super();
        sinkEvents(VTooltip.TOOLTIP_EVENTS);

        hookHtml5Events(getElement());
        setStyleName(CLASSNAME);
        addDomHandler(new MouseDownHandler() {
            public void onMouseDown(MouseDownEvent event) {
                if (startDrag(event.getNativeEvent())) {
                    event.preventDefault(); // prevent text selection
                }
            }
View Full Code Here

    button.addClickHandler(new ClickHandler() {
      public void onClick(ClickEvent event) {
        passTest(event.getNativeEvent());
      }
    });
    button.addMouseDownHandler(new MouseDownHandler() {
      public void onMouseDown(MouseDownEvent event) {
        event.getNativeButton();
        passTest(event.getNativeEvent());
      }
    });
View Full Code Here

TOP

Related Classes of com.google.gwt.event.dom.client.MouseDownHandler

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.