Package com.google.gwt.user.client.ui

Examples of com.google.gwt.user.client.ui.TreeItem$ContentPanel


    /**
     * flag the 'active' item and revel content if necessary
     */
    private void revealContent(boolean open) {

        TreeItem activeItem = getSelectedItem();

        if(activeItem instanceof LHSNavTreeItem)
        {
            ((LHSNavTreeItem)activeItem).reveal();
        }
View Full Code Here


            });
        }
    }

    private void openParents(TreeItem treeItem) {
        TreeItem parentItem = treeItem.getParentItem();
        if(parentItem !=null)
        {
            parentItem.setState(true);
            openParents(parentItem);
        }

    }
View Full Code Here

    }

    public void expandTopLevel() {
        for(int i=0; i<getItemCount(); i++)
        {
            TreeItem item = getItem(i);
            item.setState(true);
        }
    }
View Full Code Here

        tree = new Tree();
        tree.getElement().addClassName("browser-tree");
        tree.addSelectionHandler(new SelectionHandler<TreeItem>() {
            @Override
            public void onSelection(SelectionEvent<TreeItem> selection) {
                TreeItem selectedItem = selection.getSelectedItem();
                final LinkedList<String> path = resolvePath(selectedItem);

                rawView.clearDisplay();
                descView.clearDisplay();
                nodeHeader.clearDisplay();
View Full Code Here

    }

    @Override
    public void updateChildrenNames(ModelNode address, List<ModelNode> modelNodes) {

        TreeItem rootItem = findTreeItem(tree, address);

        assert rootItem!=null : "unable to find matching tree item: "+address;

        addChildrenNames(rootItem, modelNodes);
View Full Code Here

        rootItem.removeItems();

        for(ModelNode child : modelNodes)
        {
            TreeItem childItem = new TreeItem(child.asString());
            childItem.addItem(new PlaceholderItem());
            rootItem.addItem(childItem);
        }
    }
View Full Code Here

        if(modelNodes.isEmpty())
            rootItem.addItem(new PlaceholderItem());

        for(ModelNode child : modelNodes)
        {
            TreeItem childItem = new TreeItem(child.asString());
            childItem.addItem(new PlaceholderItem());
            rootItem.addItem(childItem);
        }
    }
View Full Code Here

            }
        }

        final Iterator<String> iterator = path.iterator();

        TreeItem next = null;

        if(iterator.hasNext())
        {
            final String pathName = iterator.next();
            for(int i=0; i<root.getItemCount(); i++)
View Full Code Here

            return findTreeItem(next, iterator);
    }

    private static TreeItem findTreeItem(TreeItem root, Iterator<String> iterator)
    {
        TreeItem next = null;
        if(iterator.hasNext())
        {
            final String pathName = iterator.next();
            for(int i=0; i<root.getChildCount(); i++)
            {
View Full Code Here

            Tree tree = new Tree();

            // Position relative does not work here in IE7
            DOM.setStyleAttribute(tree.getElement(), "position", "");

            TreeItem root = new TreeItem("Root problems");
            for (int i = 0; i < size; i++) {
                printLayoutError(valueMapArray.get(i), root, ac);
            }
            panel.add(tree);
            tree.addItem(root);
View Full Code Here

TOP

Related Classes of com.google.gwt.user.client.ui.TreeItem$ContentPanel

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.