Java 类com.google.gwt.event.dom.client.DoubleClickHandler 实例源码

项目:walkaround    文件:LogPanel.java   
FilterButton(DoubleClickHandler superSelect,
    Element itemContainer,
    String containerClass,
    String itemClass,
    String label,
    String buttonClass) {
  super(label);
  this.itemContainer = itemContainer;
  this.itemClass = itemClass;
  this.containerClass = containerClass;
  setStyleName(LogPanel.css.button() + " " + LogPanel.css.enabled() + " " + buttonClass);
  addClickHandler(this);
  if (superSelect != null) {
    addDoubleClickHandler(superSelect);
  }
}
项目:walkaround    文件:LogPanel.java   
/**
 * Gets the filter for a stream, creating one if one does not already exist.
 */
private FilterButton getStreamFilter(final String stream) {
  FilterButton filter = streamFilters.get(stream);
  if (filter == null) {
    // Just in case a user can cause a stream to be called "'><script
    // src='evil.js'></script><pre '", we only use safe values for CSS
    // classes. There's no need for the class names to be human readable.
    int streamId = streamFilters.countEntries();
    String itemClass = "w-s-" + streamId;
    String containerClass = STREAM_FILTER_PREFIX + streamId;
    filter = new FilterButton(new DoubleClickHandler() {
      @Override
      public void onDoubleClick(DoubleClickEvent event) {
        enableOnlyOneStream(stream);
      }
    }, entries, containerClass, itemClass, stream, css.stream());
    self.add(filter, streamsContainer);
    streamFilters.put(stream, filter);
    // TODO(ohler): Make styles work in IE.
    if (!UserAgent.isIE()) {
      // Replace stylesheet to make the new filter work.
      style.setInnerText(style.getInnerText() + filter.getCssRule());
    }
  }
  return filter;
}
项目:geomajas-project-client-gwt    文件:CompositeGeometryIndexController.java   
public void addMapHandler(AbstractGeometryIndexMapHandler handler) {
    handler.setIndex(index);
    handler.setService(service);
    handler.setEventParser(this);
    if (handler instanceof MapDownHandler) {
        downHandlers.add((MapDownHandler) handler);
    }
    if (handler instanceof MapUpHandler) {
        upHandlers.add((MapUpHandler) handler);
    }
    if (handler instanceof MapDragHandler) {
        dragHandlers.add((MapDragHandler) handler);
    }
    if (handler instanceof MouseOverHandler) {
        overHandlers.add((MouseOverHandler) handler);
    }
    if (handler instanceof MouseOutHandler) {
        outHandlers.add((MouseOutHandler) handler);
    }
    if (handler instanceof MouseMoveHandler) {
        moveHandlers.add((MouseMoveHandler) handler);
    }
    if (handler instanceof DoubleClickHandler) {
        doubleClickHandlers.add((DoubleClickHandler) handler);
    }
}
项目:geomajas-project-client-gwt2    文件:CompositeGeometryIndexController.java   
public void addMapHandler(AbstractGeometryIndexMapHandler handler) {
    handler.setIndex(index);
    handler.setService(service);
    handler.setEventParser(this);
    if (handler instanceof MapDownHandler) {
        downHandlers.add((MapDownHandler) handler);
    }
    if (handler instanceof MapUpHandler) {
        upHandlers.add((MapUpHandler) handler);
    }
    if (handler instanceof MapDragHandler) {
        dragHandlers.add((MapDragHandler) handler);
    }
    if (handler instanceof MouseOverHandler) {
        overHandlers.add((MouseOverHandler) handler);
    }
    if (handler instanceof MouseOutHandler) {
        outHandlers.add((MouseOutHandler) handler);
    }
    if (handler instanceof MouseMoveHandler) {
        moveHandlers.add((MouseMoveHandler) handler);
    }
    if (handler instanceof DoubleClickHandler) {
        doubleClickHandlers.add((DoubleClickHandler) handler);
    }
}
项目:walkaround    文件:LogPanel.java   
private LogPanel(Logs log) {
  this.log = log;
  initWidget(BINDER.createAndBindUi(this));

  // Add filter buttons. Global filter, then log-level filters.
  StringBuilder rules = new StringBuilder();
  rules.append(css.getText());

  for (final Level level : Level.values()) {
    String itemClass = LEVEL_CLASSES.get(level);
    String containerClass = LEVEL_FILTER_PREFIX + itemClass;
    FilterButton levelFilter = new FilterButton(new DoubleClickHandler() {
      @Override
      public void onDoubleClick(DoubleClickEvent event) {
        enableOnlyMoreImportantLevels(level);
      }
    }, entries, containerClass, itemClass, level.name(), css.level());
    levelFilters.put(level, levelFilter);
    self.add(levelFilter, levelsContainer);
    rules.append(levelFilter.getCssRule());
  }

  // TODO(ohler): Make styles work in IE; the log panel consumes the entire
  // screen without them.  In IE8, I've seen this crash in setInnerText().
  if (!UserAgent.isIE()) {
    // Inject style.
    style.setInnerText(rules.toString());
    Document.get().getBody().appendChild(style);
  }

  setActive(true);
}
项目:listmaker    文件:ItemsTable.java   
protected HandlerRegistration addDoubleClickHandler(DoubleClickHandler doubleClickhandler)
{
    return addDomHandler(doubleClickhandler, DoubleClickEvent.getType());
}
项目:che    文件:ToolButton.java   
/** Blocks double clicking on the button and on the parent element. */
private void blockDoubleClicking() {
  addDomHandler(
      new DoubleClickHandler() {
        @Override
        public void onDoubleClick(DoubleClickEvent event) {
          event.stopPropagation();
          event.preventDefault();
        }
      },
      DoubleClickEvent.getType());
}
项目:firefly    文件:HistoryTagsCmd.java   
private void addDoubleClick(final TablePanel table, final boolean isTags) {
    DoubleClickHandler dch = new DoubleClickHandler() {
        public void onDoubleClick(DoubleClickEvent event) {
            resubmitSearch(table, isTags);
        }
    };
    table.addDoubleClickListner(dch);
}
项目:qafe-platform    文件:EventFactory.java   
public static DoubleClickHandler createDoubleClickListener(final EventListenerGVO ev, final List<InputVariableGVO> input) {
    return new DoubleClickHandler() {
        public void onDoubleClick(DoubleClickEvent event) {
            Map<String,String> mouseInfo = getMouseInfo(event);
            CallbackHandler.createCallBack(event.getSource(), QAMLConstants.EVENT_ONDBLCLICK, ev, input, mouseInfo);
        }
    };
}
项目:geomajas-project-client-gwt    文件:CompositeGeometryIndexController.java   
public void onDoubleClick(DoubleClickEvent event) {
    if (service.getIndexStateService().isEnabled(index)) {
        for (DoubleClickHandler handler : doubleClickHandlers) {
            handler.onDoubleClick(event);
        }
    }
}
项目:geomajas-project-client-gwt2    文件:CompositeGeometryIndexController.java   
public void onDoubleClick(DoubleClickEvent event) {
    if (service.getIndexStateService().isEnabled(index)) {
        for (DoubleClickHandler handler : doubleClickHandlers) {
            handler.onDoubleClick(event);
        }
    }
}
项目:appinventor-extensions    文件:HandlerPanel.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
  return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:Wiab.pro    文件:ImplPanel.java   
@Override
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
  return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:x-cure-chat    文件:DoubleClickFocusPanel.java   
@Override
public HandlerRegistration addDoubleClickHandler( DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType() );
}
项目:ephesoft    文件:Table.java   
@Override
public final HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:che    文件:FileStructureImpl.java   
@Inject
public FileStructureImpl(NodeFactory nodeFactory, JavaLocalizationConstant locale) {
  super(false);
  this.nodeFactory = nodeFactory;
  this.locale = locale;
  setWidget(UI_BINDER.createAndBindUi(this));

  NodeStorage storage =
      new NodeStorage(
          new NodeUniqueKeyProvider() {
            @Override
            public String getKey(@NotNull Node item) {
              return String.valueOf(item.hashCode());
            }
          });
  NodeLoader loader = new NodeLoader(Collections.<NodeInterceptor>emptySet());
  tree = new Tree(storage, loader);
  tree.setAutoExpand(false);
  tree.getSelectionModel().setSelectionMode(SINGLE);

  KeyboardNavigationHandler handler =
      new KeyboardNavigationHandler() {
        @Override
        public void onEnter(NativeEvent evt) {
          hide();
        }
      };
  tree.addDomHandler(
      new DoubleClickHandler() {
        @Override
        public void onDoubleClick(DoubleClickEvent event) {
          if (all(tree.getSelectionModel().getSelectedNodes(), LEAFS)) {
            hide();
          }
        }
      },
      DoubleClickEvent.getType());

  handler.bind(tree);

  treeContainer.add(tree);
}
项目:firefly    文件:ThumbnailWidget.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
     return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:firefly    文件:BasicPagingImageGrid.java   
public void addDoubleClickHandler(DoubleClickHandler doubleClickHandler) {
    this.doubleClickHandler = doubleClickHandler;
}
项目:firefly    文件:BasicPagingTable.java   
public void addDoubleClickListener(DoubleClickHandler dch){
    this.addDomHandler(dch, DoubleClickEvent.getType());
}
项目:firefly    文件:TablePanel.java   
public void addDoubleClickListner(DoubleClickHandler dch) {
    table.addDoubleClickListener(dch);
}
项目:fullmetalgalaxy    文件:WgtIntBox.java   
@Override
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler p_handler)
{
  return m_intBox.addDoubleClickHandler( p_handler );
}
项目:qafe-platform    文件:GWTUIGenerator.java   
private static void createDesktopIcon(final WindowGVO windowGVO, final String uuid, final String title, final String appId) {
        if (windowGVO != null && windowGVO.getIcon() != null && windowGVO.getIcon().length() > 0) {
            final String windowId = windowGVO.getId();
            final DesktopIcon desktopIcon = new DesktopIcon(windowGVO.getIcon(), title);
            fillInMandatoryOnly(windowGVO, desktopIcon, uuid, windowId, appId);

            desktopIcon.addDoubleClickHandler(new DoubleClickHandler() {

                public void onDoubleClick(DoubleClickEvent event) {
                    // ClientApplicationContext.getInstance().removeWindow(windowId,
                    // uuid);
                    WindowPanel existingWindowPanel = ClientApplicationContext.getInstance().windowIdExists(windowId, uuid);
                    if (existingWindowPanel == null) {
                        EventListenerGVO[] events = windowGVO.getEvents();
                        if (events != null) {
                            String eventType = QAMLConstants.EVENT_ONCLICK;
                            for (EventListenerGVO eventGVO : events) {
                                if (eventGVO.getEventComponentId().equals(windowId) && eventGVO.getEventListenerType().equals(eventType)) {
                                    createCallBack4OpenWindow(desktopIcon, eventType, eventGVO);
                                    break;
                                }
                            }
                        }
//                      MainFactoryActions.getUIByUUID(uuid, windowId);
                    } else {
                        Iterator itr = ClientApplicationContext.getInstance().getHorizontalPanel().iterator();
                        while (itr.hasNext()) {
                            Widget w = (Widget) itr.next();
                            if (w.getTitle().equals(title)) {
                                existingWindowPanel.setWindowState(WindowState.NORMAL);
                                existingWindowPanel.show();
                                ClientApplicationContext.getInstance().getHorizontalPanel().remove(w);
                            }
                        }
                        existingWindowPanel.toFront();
                    }

                }
            });
            ClientApplicationContext.getInstance().getDragController().makeDraggable(desktopIcon, desktopIcon.getTitleLabel());
            ClientApplicationContext.getInstance().addDesktopIcon(desktopIcon);
        }
    }
项目:qafe-platform    文件:SpreadsheetCell.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:qafe-platform    文件:DesktopIcon.java   
public HandlerRegistration addDoubleClickHandler(final DoubleClickHandler handler) { 
    return addDomHandler(handler, DoubleClickEvent.getType()); 
}
项目:qafe-platform    文件:DesktopIcon.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return image.addDoubleClickHandler(handler);
}
项目:gwt-gantt    文件:HTMLTable.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
  return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:hexa.tools    文件:DataTable.java   
public HandlerRegistration addCellDoubleClickHandler( final DoubleClickHandler handler )
{
    return addDomHandler( handler, DoubleClickEvent.getType() );
}
项目:putnami-web-toolkit    文件:AbstractInput.java   
@Override
public com.google.gwt.event.shared.HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return this.addDomHandler(handler, DoubleClickEvent.getType());
}
项目:putnami-web-toolkit    文件:ListItem.java   
@Override
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return this.addDomHandler(handler, DoubleClickEvent.getType());
}
项目:putnami-web-toolkit    文件:Anchor.java   
@Override
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return this.addDomHandler(handler, DoubleClickEvent.getType());
}
项目:opennmszh    文件:MapQuestMapPanel.java   
/** {@inheritDoc} */
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:opennmszh    文件:OpenLayersMapPanel.java   
/** {@inheritDoc} */
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:ListBuilder    文件:VListBuilder.java   
@Override
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:ListBuilder    文件:VListBuilder.java   
@Override
public HandlerRegistration addDoubleClickHandler(
        DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:geomajas-project-client-gwt    文件:CompositeGeometryIndexController.java   
public void addDoubleClickHandler(DoubleClickHandler handler) {
    doubleClickHandlers.add(handler);
}
项目:geomajas-project-client-gwt    文件:GraphicsWidget.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return widget.addDoubleClickHandler(handler);
}
项目:geomajas-project-client-gwt2    文件:CompositeGeometryIndexController.java   
public void addDoubleClickHandler(DoubleClickHandler handler) {
    doubleClickHandlers.add(handler);
}
项目:geomajas-project-client-gwt2    文件:MapWidgetImpl.java   
public HandlerRegistration addDoubleClickHandler(DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:gwtbootstrap3    文件:LinkedGroupItem.java   
@Override
public HandlerRegistration addDoubleClickHandler(final DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}
项目:gwtbootstrap3    文件:ThumbnailLink.java   
/**
 * {@inheritDoc}
 */
@Override
public HandlerRegistration addDoubleClickHandler(final DoubleClickHandler handler) {
    return addDomHandler(handler, DoubleClickEvent.getType());
}