Package com.allen_sauer.gwt.dnd.client

Examples of com.allen_sauer.gwt.dnd.client.PickupDragController


    dndBoundary.setSize("200px", "100%");
    leftLayout.add(dndBoundary);
    layerPanel = new VerticalPanel();
    dndBoundary.add(layerPanel);

    layerDragController = new PickupDragController(dndBoundary, false);
    layerDragController.setBehaviorMultipleSelection(false);
    layerDragController.registerDropController(new VerticalPanelDropController(layerPanel));
    layerDragController.addDragHandler(new LayerDragHandler());

    // Create the MapPresenter and add an InitializationHandler:
View Full Code Here


     * @param boundaryPanel the boundary panel
     */
    public WindowController(AbsolutePanel boundaryPanel) {
      this.boundaryPanel = boundaryPanel;

      pickupDragController = new PickupDragController(boundaryPanel, true);
      pickupDragController.setBehaviorConstrainedToBoundaryPanel(false);
      pickupDragController.setConstrainWidgetToBoundaryPanel(false);
      pickupDragController.setBehaviorMultipleSelection(false);

      resizeDragController = new WindowResizeDragController(boundaryPanel);
View Full Code Here

    root = new AbsolutePanel();
    root.setSize("100%", "100%");
    root.add(contentPane);
    RootPanel.get().add(root);
   
    PickupDragController dragController = new PickupDragController(root, true);
    dragController.setBehaviorConstrainedToBoundaryPanel(true);
    dragController.setBehaviorMultipleSelection(false);
    dragController.setBehaviorDragStartSensitivity(1);
    execute(new SystemApplyCompilerSettingsCommand());
    loadDocument();
  }
View Full Code Here

      }
    }
    });
    RootPanel.get().add(wrap);
    windowManager = new WindowManager(root);
    PickupDragController dragController = new PickupDragController(root, true);
    dragController.setBehaviorConstrainedToBoundaryPanel(true);
    dragController.setBehaviorMultipleSelection(false);
    dragController.setBehaviorDragStartSensitivity(1);
  }
View Full Code Here

    dragController.unregisterDropController(dropController);
  }
 
  @Override
  public void initializeDragging(DragHandler dragHandler) {
    dragController = new PickupDragController(backgroundArea, false);
    dragController.setBehaviorDragStartSensitivity(3);
    dragController.addDragHandler(dragHandler);
    dragController.makeDraggable(chip10);
    dragController.makeDraggable(chip20);
    dragController.makeDraggable(chip50);
View Full Code Here

    private Panel createLayout(final String id) {
        Widget area;
        mainLayoutPanel.add(createHeader(), DockPanel.NORTH);

        tabDragController = new PickupDragController(RootPanel.get(), false);
        tabDragController.setBehaviorBoundaryPanelDrop(false);
        tabDragController.addDragHandler(new TabDragHandler(this));

        mainLayoutPanel.add(area = createNavigator(), DockPanel.WEST);
        mainLayoutPanel.setCellHeight(area, "100%");
View Full Code Here

        initWidget(timeline);

        dropController = new AbsolutePositionDropController(timeline);

        dragController = new PickupDragController(timeline, false);
        dragController.setBehaviorDragProxy(true);
        dragController.setBehaviorMultipleSelection(false);
        dragController.setBehaviorConstrainedToBoundaryPanel(true);

        dragController.registerDropController(dropController);
View Full Code Here

        this.serviceCache = serviceCache;

        VerticalPanel mainPanel = new VerticalPanel();
        rankPanelPanel = new VerticalPanel();

        entryDragController = new PickupDragController(RootPanel.get(),
                false);

        IndexedDropController rankDropController = new IndexedDropController(
                rankPanelPanel);
        entryDragController.registerDropController(rankDropController);
View Full Code Here

  private HorizontalPanel mainPanel = new HorizontalPanel();

  public ThemeManager(DreamCalc calc, String[] themes) {
    this.calc = calc;
    Button button;
    PickupDragController dragController = new PickupDragController(
        RootPanel.get(), false);

    // themes buttons don't disappear
    dragController.setBehaviorDragProxy(true);

    for (String theme : themes) {
      button = new Button(theme);
      mainPanel.add(button);
      dragController.makeDraggable(button);
    }

    SimpleDropController dropController = new SimpleDropController(calc
        .getMainPanel()) {
      public void onDrop(DragContext context) {
        super.onDrop(context);

        Button b = (Button) context.draggable;
        setStyle(b.getText());
      }
    };
    dragController.registerDropController(dropController);
  }
View Full Code Here

        new VerticalPanelDropController(currentVerticalPanel);

    boundaryPanel.add(currentVerticalPanel);
    DragHandler dragHandler = createDragHandler(currentVerticalPanel);

    PickupDragController widgetDragController = new PickupDragController(boundaryPanel, false);
    widgetDragController.setBehaviorMultipleSelection(false);
    widgetDragController.addDragHandler(dragHandler);
    widgetDragController.registerDropController(widgetDropController);

    // Add each widget to the VerticalPanel and enable dragging via its DragTarget.
    for (T widget : widgets) {
      currentVerticalPanel.add(widget);
      widgetDragController.makeDraggable(widget, getDragTarget.apply(widget));
    }
  }
View Full Code Here

TOP

Related Classes of com.allen_sauer.gwt.dnd.client.PickupDragController

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.