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 61305 - Unable to access default TreeView API
Summary: Unable to access default TreeView API
Status: RESOLVED WONTFIX
Alias: None
Product: platform
Classification: Unclassified
Component: Explorer (show other bugs)
Version: 4.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jaroslav Tulach
URL:
Keywords: API
Depends on:
Blocks:
 
Reported: 2005-07-22 18:15 UTC by Craig Conover
Modified: 2010-04-02 16:24 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 Craig Conover 2005-07-22 18:15:28 UTC
When using the default provided TreeView in the explorer, it is impossible to
programatically access its API. For example, a module developer cannot simply
get the TreeView from within a Node or Action of a node to perform
expand/collapse of a node or set of nodes. It would also be nice to be able to
detect if a node is currently expanded or collapse (also in the TreeView API).
And it would be very convenient to have an event that can be listened to when a
node is expanded or collapsed.

http://www.netbeans.org/download/dev/javadoc/org-openide-explorer/org/openide/explorer/view/TreeView.html

The basic defect is the inability to get a reference to the TreeView from the
Node API.
Comment 1 Jesse Glick 2005-07-22 19:18:00 UTC
Wrong component.

Not a defect; as designed (for now). There may be several TreeView's displaying
a given Node, or none at all. There could be a distinct API for finding a
"published" TreeView for a given Node (or some other key). Of course, if you
make your own TreeView for a new component, you can do whatever you like with it.

Conceptually related to issue #7551.
Comment 2 Trey Spiva 2005-07-22 20:54:01 UTC
There still needs to be some kind of API for tool venders to tell the tree to
show a node.  We also need to be able determine if a node is in a expanded or
collapsed state.  Currently the only approach is to use the TreeView which is a
private class.
Comment 3 Antonin Nebuzelsky 2008-02-07 16:11:05 UTC
Reassigning to new module owner Tomas Holy.
Comment 4 Jaroslav Tulach 2010-04-02 16:24:26 UTC
Node does not have any clue which component it is being displayed in. This the node cannot provide any access to TreeView.