Examples of TreeGrid


Examples of com.inmethod.grid.treegrid.TreeGrid

    columns.add(new PropertyColumn(new Model("Property 4"), "userObject.property4"));
    columns.add(new PropertyColumn(new Model("Property 5"), "userObject.property5"));
    columns.add(new PropertyColumn(new Model("Property 6"), "userObject.property6"));
   
    TreeModel model = TreeModelFactory.createTreeModel();
    TreeGrid grid = new TreeGrid("grid", model, columns);
   
    grid.setContentHeight(23, SizeUnit.EM);
   
    // expand the root node
    grid.getTreeState().expandAll();
   
    add(grid);
  }
View Full Code Here

Examples of com.inmethod.grid.treegrid.TreeGrid

    );
    columns.add(new PropertyColumn(new Model("Property 5"), "userObject.property5"));
    columns.add(new PropertyColumn(new Model("Property 6"), "userObject.property6"));

    TreeModel model = TreeModelFactory.createTreeModel();
    TreeGrid grid = new TreeGrid("grid", model, columns);

    // expand the root node
    grid.getTreeState().expandNode((TreeNode) model.getRoot());
    grid.setContentHeight(23, SizeUnit.EM);

    add(grid);
  }
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

   * customize certain aspects through subclassing)
   *
   * @return
   */
  protected TreeGrid createTreeGrid() {
    return new TreeGrid();
  }
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

      GWT.log("TODO");
    }
  }

  protected TreeGrid createTreeGridInfoWindowRollover() {
    return new TreeGrid() {
      private HLayout rollOverTools;
      private HLayout emptyRollOver;

      @Override
      protected Canvas getRollOverCanvas(Integer rowNum, Integer colNum) {
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

      }
    };
  }

  protected TreeGrid createTreeGridFullRollover() {
    return new TreeGrid() {
      private HLayout rollOverTools;
      private HLayout emptyRollOver;
      private Canvas[] toolButtons;

      @Override
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

                globalPermissions = (permissions != null) ? permissions : EnumSet.noneOf(Permission.class);

                List<NavigationSection> sections = getNavigationSections();
                sectionsByName = new HashMap<String, NavigationSection>(sections.size());
                for (NavigationSection section : sections) {
                    TreeGrid treeGrid = buildTreeGridForSection(section);
                    addSection(treeGrid);
                    treeGrid.getTree().openAll();
                    sectionsByName.put(section.getName(), section);
                }

                addMember(sectionStack);
                addMember(contentCanvas);
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

    protected abstract Canvas defaultView();

    protected abstract List<NavigationSection> getNavigationSections();

    private TreeGrid buildTreeGridForSection(NavigationSection navigationSection) {
        final TreeGrid treeGrid = new TreeGrid();
        treeGrid.setLeaveScrollbarGap(false);
        treeGrid.setShowHeader(false);
        treeGrid.setSelectionType(SelectionStyle.SINGLE);
        treeGrid.setHeight(50);
//        treeGrid.setExtraSpace(5);
        treeGrid.addStyleName("noOutline");
        treeGrid.setAutoFitData(Autofit.VERTICAL);


        List<NavigationItem> navigationItems = navigationSection.getNavigationItems();
        TreeNode[] treeNodes = new TreeNode[navigationItems.size()];
        for (int i = 0, navigationItemsSize = navigationItems.size(); i < navigationItemsSize; i++) {
            NavigationItem item = navigationItems.get(i);
            final TreeNode treeNode = new EnhancedTreeNode(item.getName(), item.getTitle());
            treeNode.setIcon(item.getIcon());
            treeNode.setEnabled(item.isEnabled());
            treeNodes[i] = treeNode;
        }

        TreeNode rootNode = new EnhancedTreeNode(navigationSection.getName(), navigationSection.getTitle(), treeNodes);
        Tree tree = new Tree();
        tree.setRoot(rootNode);
        treeGrid.setData(tree);

        return treeGrid;
    }
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

        }
    }

    private void initSectionPageTreeGrids() {
        for (String name : treeGrids.keySet()) {
            TreeGrid treeGrid = treeGrids.get(name);
            treeGrid.deselectAllRecords();
            this.currentSectionViewId = null;
            this.currentPageViewId = null;
        }
    }
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

        }
    }

    private void selectSectionPageTreeGridNode(String sectionName, String pageName) {
        for (String name : treeGrids.keySet()) {
            TreeGrid treeGrid = treeGrids.get(name);
            if (!name.equals(sectionName)) {
                treeGrid.deselectAllRecords();
            } else {
                Tree tree = treeGrid.getTree();
                TreeNode node = tree.find(sectionName + "/" + pageName);
                if (node != null) {
                    treeGrid.selectSingleRecord(node);
                } else {
                    CoreGUI.getErrorHandler().handleError(MSG.view_leftNav_unknownPage(pageName, sectionName));
                }
            }
        }
View Full Code Here

Examples of com.smartgwt.client.widgets.tree.TreeGrid

    @Override
    protected void onInit() {
        super.onInit();

        treeGrid = new TreeGrid();

        treeGrid.setHeight100();

        dataSource = new AutodiscoveryQueueDataSource(treeGrid);
        treeGrid.setDataSource(dataSource);
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.