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

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


    // Third child within the vector drawing area is a group for map gadget containers:
    gadgetVectorContainer = new VectorGroup();
    drawingArea.add(gadgetVectorContainer);

    // Firefox and Chrome allow for DnD of images. This default behavior is not wanted.
    addMouseDownHandler(new MouseDownHandler() {

      public void onMouseDown(MouseDownEvent event) {
        event.preventDefault();
      }
    });
View Full Code Here


      zoomInRect.close();

      add(zoomInRect);
      add(eventCatcher);

      eventCatcher.addMouseDownHandler(new MouseDownHandler() {

        public void onMouseDown(MouseDownEvent event) {
          if (event.getNativeButton() != NativeEvent.BUTTON_RIGHT) {
            dragging = true;
            x = event.getX() - offset;
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

      }

      if (m.isCanDismiss()) {
        // The hide link, it will hide the message if clicked on
        Anchor hideElement = new Anchor(L10n.get("hide"));
        hideElement.addMouseDownHandler(new MouseDownHandler() {
          @Override
          public void onMouseDown(MouseDownEvent event) {
            // Only send a request if the message is originated from the server
            if (m.getAnchor() != null) {
              FreenetRequest.sendRequest(UpdaterConstants.dismissAlertPath, new QueryParameter("anchor", m.getAnchor()), new RequestCallback() {
View Full Code Here

   
   
    void initHandlers() {

       
        canvas.addMouseDownHandler(new MouseDownHandler(){
      @Override
      public void onMouseDown(MouseDownEvent event) {
            mouseStartX = event.getRelativeX(canvas.getElement());
            mouseStartY = event.getRelativeY(canvas.getElement());
          //  garden.draw(mouseX, mouseY);
View Full Code Here

      setStyleName(res.styles().historyTable());
      FontSizer.applyNormalFontSize(this);

      if (searchResult_)
      {
         addMouseDownHandler(new MouseDownHandler()
         {
            public void onMouseDown(MouseDownEvent event)
            {
               Element el = DOM.eventGetTarget((Event) event.getNativeEvent());
               if (el != null
View Full Code Here

                    revealContent(false);
                }
            }
        });

        addMouseDownHandler(new MouseDownHandler() {

            public void onMouseDown(MouseDownEvent mouseDownEvent) {
                Scheduler.get().scheduleDeferred(new Scheduler.ScheduledCommand() {
                    public void execute() {
                        revealContent(true);
                    }
                });
            }
        });

        Scheduler.get().scheduleEntry(new Scheduler.ScheduledCommand() {
            public void execute() {
                framework.getEventBus().addHandler(LHSHighlightEvent.TYPE, LHSNavTree.this);
            }
        });


        /*
            Allow clicks on lhs titles to open thr tree
        */

        addMouseDownHandler(new MouseDownHandler() {
            public void onMouseDown(MouseDownEvent event) {
                EventTarget target = event.getNativeEvent().getEventTarget();
                com.google.gwt.dom.client.Element el = Element.as(target);
                final String title = el.getInnerText();

View Full Code Here

        layout.getElement().setAttribute(Aria.ROLE, Aria.DIALOG);
        layout.getElement().setAttribute(Aria.LABELLED_BY, header.getHeaderId());


        // dnd
        header.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() {
            public void onMouseDown(MouseDownEvent event) {
                if (dragStarMode > 0) {
                    VTransferable transferable = new VTransferable();
                    transferable.setDragSource(VDragAndDropWrapper.this);
View Full Code Here

    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

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.