Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Problem regarding the treeviewer..
Problem regarding the treeviewer.. [message #194307] Thu, 15 February 2007 06:17 Go to next message
zakir Hussain is currently offline zakir HussainFriend
Messages: 76
Registered: July 2009
Member
Hi All,

I am having the problem in treeviewer….

How to fire the selection on the treeviewer… with out expanding all the
elements of the tree.

MyProblem:

I am having a treeviewer… with around 10lakh elements…

I have stored some elements of treeviewer in a list based on some
categeory….

I want to fire the selection on the treeviewer for the elements in the
list…

I am firing the selection in this way…

myTreeviewer.setSelection(new StructuredSelection(elementfromList),true);

But the selection is not happening.. Unless and untill I expand the tree
once….

But as I have so many elements in the tree.. .. Performance issues are
coming….

Can you plz suggest me any alternative regarding this…

Regards,

Zakir
Re: Problem regarding the treeviewer.. [message #194347 is a reply to message #194307] Thu, 15 February 2007 11:47 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: merks.ca.ibm.com

Zakir,

It sounds likely that your content provider is not behaving correctly
with respect to its getParent implementation. This method needs to be
implemented correctly in order for
AbstractTreeViewer.internalExpand/getParentElement to know which branch
to expand to find each node in the tree.


zakir wrote:
> Hi All,
>
> I am having the problem in treeviewer�.
>
> How to fire the selection on the treeviewer� with out expanding all
> the elements of the tree.
>
> MyProblem:
>
> I am having a treeviewer� with around 10lakh elements�
>
> I have stored some elements of treeviewer in a list based on some
> categeory�.
>
> I want to fire the selection on the treeviewer for the elements in the
> list�
>
> I am firing the selection in this way�
>
> myTreeviewer.setSelection(new StructuredSelection(elementfromList),true);
>
> But the selection is not happening.. Unless and untill I expand the
> tree once�.
>
> But as I have so many elements in the tree.. .. Performance issues are
> coming�.
>
> Can you plz suggest me any alternative regarding this�
>
> Regards,
>
> Zakir
>
>
Re: Problem regarding the treeviewer.. [message #194496 is a reply to message #194347] Thu, 15 February 2007 13:41 Go to previous message
zakir Hussain is currently offline zakir HussainFriend
Messages: 76
Registered: July 2009
Member
Thanks Merks,

My problem is resolved ...when i implemented... getParent() in the
contentprovider....

Thanks again..

Regards,

Zakir
Previous Topic:expanding the treeviewer internally
Next Topic:Help on creating a file within a project
Goto Forum:
  


Current Time: Fri Apr 26 06:28:55 GMT 2024

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

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

Back to the top