Examples of ExplorerTree


Examples of org.latexlab.docs.client.widgets.ExplorerTree

     */
    private void showExplorerView() {
    if (entries == null) {
      return;
    }
      ExplorerTree tree = new ExplorerTree(false, false, false, new StarHandler(){
      @Override
      public void onStar(String id) {
        CommandEvent.fire(new SystemStarDocumentCommand(id));
      }
      @Override
      public void onUnstar(String id) {
        CommandEvent.fire(new SystemUnstarDocumentCommand(id));
      }
      });
      tree.setEntries(entries);
      documentsPanel = new ScrollPanel(tree);
      rightPanel.add(documentsPanel);
      resize();
    }
View Full Code Here

Examples of org.latexlab.docs.client.widgets.ExplorerTree

  /**
   * Builds the form.
   */
  private void buildForm() {
      scroll = new ScrollPanel();
    tree = new ExplorerTree(true, false, true, null);
    tree.setSize("100%", "100%");
    tree.setExcludedOpen(true);
    tree.addSelectionHandler(new SelectionHandler<TreeItem>() {
        @Override
      public void onSelection(SelectionEvent<TreeItem> event) {
View Full Code Here

Examples of org.latexlab.docs.client.widgets.ExplorerTree

      panel = new VerticalPanel();
      panel.setWidth("400px");
      panel.setVerticalAlignment(VerticalPanel.ALIGN_TOP);
      initWidget(panel);
      scroll = new ScrollPanel();
    tree = new ExplorerTree(true, true, true, null);
    tree.setSize("100%", "100%");
    tree.setExcludedOpen(true);
    scroll.add(tree);
    ok = new Button("OK", new ClickHandler(){
      public void onClick(ClickEvent event) {
View Full Code Here

Examples of org.openquark.gems.client.explorer.ExplorerTree

     */
    private void maybeAddGem() {

        if (gemCutter.getGUIState() == GemCutter.GUIState.ADD_GEM) {

            ExplorerTree explorerTree = tableTopExplorer.getExplorerTree();
            DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode) explorerTree.getLastSelectedPathComponent();
            Object userObject = treeNode != null ? treeNode.getUserObject() : null;

            if (gemCutter.getAddingDisplayedGem() == null) {

                // This means we have to invoke Intellicut to add a gem.

                if (treeNode == null) {
                    treeNode = (DefaultMutableTreeNode) explorerTree.getModel().getRoot();
                    explorerTree.setSelectionPath(new TreePath(treeNode.getPath()));
                }

                Rectangle location = getIntellicutLocation(treeNode);
                DisplayedPartConnectable displayedPart = null;

View Full Code Here

Examples of org.openquark.gems.client.explorer.ExplorerTree

            private static final long serialVersionUID = 5114481077769168106L;

            public void actionPerformed(ActionEvent evt) {

                ExplorerTree explorerTree = tableTopExplorer.getExplorerTree();
                DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode) explorerTree.getLastSelectedPathComponent();

                if (treeNode == null) {
                    treeNode = (DefaultMutableTreeNode) explorerTree.getModel().getRoot();
                    explorerTree.setSelectionPath(new TreePath(treeNode.getPath()));
                }

                Rectangle location = getIntellicutLocation(treeNode);

                gemCutter.getIntellicutManager().startIntellicutMode(null, location, false, null, explorerTree);
View Full Code Here

Examples of org.openquark.gems.client.explorer.ExplorerTree

     * @param treeNode the tree node to get the intellicut position for
     * @return the position at which intellicut should be displayed for a given node
     */
    private Rectangle getIntellicutLocation(DefaultMutableTreeNode treeNode) {

        ExplorerTree explorerTree = tableTopExplorer.getExplorerTree();
        Rectangle location = explorerTree.getPathBounds(new TreePath(treeNode.getPath()));

        if (treeNode == explorerTree.getModel().getRoot()) {
            // For the root node we want to display Intellicut off to the right.
            // This is so it doesn't obscure the rest of the tree.
            location.x += location.width + 3;
            location.y += 3;
            location.height = 0;
View Full Code Here

Examples of org.openquark.gems.client.explorer.ExplorerTree

     * This is called by the GemCutter if the user activates the Intellicut keyboard shortcut.
     * @return true if menu was displayed, false otherwise
     */
    boolean maybeDisplayIntellicut() {

        ExplorerTree explorerTree = getTableTopExplorer().getExplorerTree();

        if (explorerTree.isFocusOwner()) {

            DefaultMutableTreeNode treeNode = (DefaultMutableTreeNode) explorerTree.getLastSelectedPathComponent();

            if (treeNode == null) {
                treeNode = (DefaultMutableTreeNode) explorerTree.getModel().getRoot();
            }               

            Rectangle location = getIntellicutLocation(treeNode);
            Object userObject = treeNode.getUserObject();

View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.