Bug 338186

Summary: Tree-Will-Expand Listener for SWT Tree
Product: [Eclipse Project] Platform Reporter: Bhuvan Mehta <bhuvanmehta>
Component: SWTAssignee: Platform-SWT-Inbox <platform-swt-inbox>
Status: NEW --- QA Contact:
Severity: enhancement    
Priority: P3 CC: bhuvanmehta
Version: 4.1   
Target Milestone: ---   
Hardware: PC   
OS: Windows Vista   
Whiteboard:

Description Bhuvan Mehta CLA 2011-02-25 04:24:48 EST
At the jface Treeviewer level there isn't a way to get an event before an node in the tree is expanded or collapsed.
org.eclipse.swt.events.TreeListener doesn't serve the purpose as it notifies after the node has expanded or collapsed and the getChildren() already get the call then the listeners are notifies.
Unlike in swing tree we have something like javax.swing.event.TreeWillExpandListener which notifies users before the node is expanded or collapsed so listeners can react an control the expand/collapse of the tree node.
In cases where one needs a veto power for expand/collapse of tree node and avoid tree node's children's calculation this required.
Comment 1 Lars Vogel CLA 2019-09-24 13:57:49 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.