Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Removing individual TreeItems from a Tree
Removing individual TreeItems from a Tree [message #454174] Mon, 18 April 2005 19:33 Go to next message
Greg Hilton is currently offline Greg HiltonFriend
Messages: 2
Registered: July 2009
Junior Member
I see that support has been added in 3.1M6 for indexing TreeItems:

Tree supports indices
New API has been added so that items in a Tree can be referenced by index.
The index is relative to the immediate parent which for top level nodes is
the Tree and for sub-nodes is the parent TreeItem. The new API includes
Tree/TreeItem.indexOf(TreeItem) and Tree/TreeItem.getItem(index). In
addition, you can remove the children of a tree item using
TreeItem.removeAll().

Does anyone know if there are plans to add remove(index) to remove a single
TreeItem? Or is this accomplished through something like
TreeItem.dispose()?

Thanks,
Greg
Re: Removing individual TreeItems from a Tree [message #454177 is a reply to message #454174] Mon, 18 April 2005 20:07 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: doug-list.threepenny.net

dispose() is correct and available now so I don't think they'll be
adding a remove(index).

Doug

Greg Hilton wrote:

> I see that support has been added in 3.1M6 for indexing TreeItems:
>
> Tree supports indices
> New API has been added so that items in a Tree can be referenced by index.
> The index is relative to the immediate parent which for top level nodes is
> the Tree and for sub-nodes is the parent TreeItem. The new API includes
> Tree/TreeItem.indexOf(TreeItem) and Tree/TreeItem.getItem(index). In
> addition, you can remove the children of a tree item using
> TreeItem.removeAll().
>
> Does anyone know if there are plans to add remove(index) to remove a single
> TreeItem? Or is this accomplished through something like
> TreeItem.dispose()?
>
> Thanks,
> Greg
>
>
Re: Removing individual TreeItems from a Tree [message #454196 is a reply to message #454174] Mon, 18 April 2005 22:14 Go to previous message
Steve Northover is currently offline Steve NorthoverFriend
Messages: 1636
Registered: July 2009
Senior Member
It's possible that the API will be removed for 3.1. Sorry, that's all I can
say right now.

"Greg Hilton" <none@nospam.com> wrote in message
news:d412h9$gms$1@news.eclipse.org...
> I see that support has been added in 3.1M6 for indexing TreeItems:
>
> Tree supports indices
> New API has been added so that items in a Tree can be referenced by index.
> The index is relative to the immediate parent which for top level nodes is
> the Tree and for sub-nodes is the parent TreeItem. The new API includes
> Tree/TreeItem.indexOf(TreeItem) and Tree/TreeItem.getItem(index). In
> addition, you can remove the children of a tree item using
> TreeItem.removeAll().
>
> Does anyone know if there are plans to add remove(index) to remove a
single
> TreeItem? Or is this accomplished through something like
> TreeItem.dispose()?
>
> Thanks,
> Greg
>
>
Previous Topic:Hide a coolbar
Next Topic:SWT startup problem
Goto Forum:
  


Current Time: Tue Mar 02 15:10:25 GMT 2021

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

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

Back to the top