Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » How to prevent tree node from collapse(The visible root node should not collaps and or the "+" icon should remove.)
How to prevent tree node from collapse [message #519584] Tue, 09 March 2010 11:36
Andreas is currently offline AndreasFriend
Messages: 9
Registered: February 2010
Location: Germany/Berlin
Junior Member
I try to prevent a tree node (SWT Tree or JFace TreeViewer) from collapse. Is thier a way to do that? Catch an event or so. Or is thier a possibility to remove "+" icon?

Thanks for help.
Re: How to prevent tree node from collapse [message #519654 is a reply to message #519584] Tue, 09 March 2010 10:40 Go to previous message
Grant Gayed is currently offline Grant GayedFriend
Messages: 2150
Registered: July 2009
Senior Member
Hi,

At the SWT level there isn't a way to veto an expand/collapse by the user,
other than to listen for the Expand/Collapse event and invoke the opposite
API to re-expand/re-collapse the item, which can show a flash. Also, there
is no way to hide/change the expander. I could not find existing Feature
Requests for either of these, so if you want you can log one or two with swt
at
https://bugs.eclipse.org/bugs/enter_bug.cgi?product=Platform &component=SWT&bug_severity=enhancement .

Though I don't know TreeViewer particularly well, I doubt that it would be
able to provide either of these, since it is constrained in some ways by the
beahviours of the underlying SWT Tree control.

Grant


"Andreas" <rcp_java@gmx.net> wrote in message
news:hn5bri$dah$1@build.eclipse.org...
> I try to prevent a tree node (SWT Tree or JFace TreeViewer) from collapse.
Is thier a way to do that? Catch an event or so. Or is thier a possibility
to remove "+" icon?
>
> Thanks for help.
Previous Topic:How to create modeless dialog and update it from UI thread?
Next Topic:SWT syncexec question
Goto Forum:
  


Current Time: Thu Apr 25 23:59:36 GMT 2024

Powered by FUDForum. Page generated in 0.02940 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top