This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 192661 - OutlineView lacks the expandAll method for compatibility with TreeTableView
Summary: OutlineView lacks the expandAll method for compatibility with TreeTableView
Status: NEW
Alias: None
Product: platform
Classification: Unclassified
Component: Outline&TreeTable (show other bugs)
Version: 7.0
Hardware: PC Windows XP
: P3 normal with 3 votes (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-11-30 09:47 UTC by mienamoo
Modified: 2013-09-06 23:34 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mienamoo 2010-11-30 09:47:52 UTC
It would be useful if the OutlineView (or at least its Outline) could support the expandAll() method available in TableView, for compatibility with TreeTableView.

The forum discussion at http://forums.netbeans.org/viewtopic.php?t=24267&postdays=0&postorder=asc&start=0 is relevant here. I have not been able to find a bug related to this, and it appears that the method does not exist in build 201011210001.
Comment 1 scanti 2012-11-08 10:14:29 UTC
I tried to add it to the outline

    public void expandAll() {
        ExplorerManager em = ExplorerManager.find(this);
        if (em != null) {
            Node node = em.getRootContext();
            expandAll(node);
        }
    }

    private void expandAll(Node node) {
        if (node == null) {
            return;
        }

        expandNode(node);

        for (Node child : node.getChildren().getNodes()) {
            expandAll(child);
        }

    }
Comment 2 scanti 2012-11-08 10:15:16 UTC
I have also add the setRootVisible method
    public void setRootVisible(boolean vis){
        getOutline().setRootVisible(vis);
    }
Comment 3 mienamoo 2012-12-04 06:49:16 UTC
(In reply to comment #2)
> I have also add the setRootVisible method
>     public void setRootVisible(boolean vis){
>         getOutline().setRootVisible(vis);
>     }

Where did you add this? I does not appear in the daily build yet...
Comment 4 scanti 2013-09-06 23:34:00 UTC
In my RCP I create a class that extended OutlineView. I cannot commit to NetBeans sources. the code I posted is just a suggested implementation.