Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » JFace » Show Tree in TreeViewer
Show Tree in TreeViewer [message #1095073] Mon, 26 August 2013 11:30 Go to next message
anthony palmieri is currently offline anthony palmieri
Messages: 20
Registered: July 2013
Junior Member
Hello ,
I Construct a tree with a method , but i have a problem . This code show nothing because items of tree becames null :/
So how can i display a tree in a treeviewer without change input ? Or without display the tree ?
data.initTree(parent, SWT.BORDER);
		treeViewer = new TreeViewer(data.getTree());
		
		treeViewer.setContentProvider(contentprovider);
		treeViewer.setLabelProvider(new WorkspaceLabelProvider());
		System.out.println(data.getItems());
		treeViewer.setInput(data.getItems());

And actually when i let only the constructor only one node is showed whereas when i use SWT tree as
initTree(composite parent, SWT.Border)
all node are visible

Thanks for your answers

[Updated on: Tue, 27 August 2013 04:12]

Report message to a moderator

Re: Show Tree in TreeViewer [message #1397113 is a reply to message #1095073] Wed, 09 July 2014 04:05 Go to previous message
Hussein MHANNA is currently offline Hussein MHANNA
Messages: 30
Registered: February 2014
Location: LAVAL
Member
Hi Anthony,

Can you give more details about your problem (because I didn't really understand the problem and what the method initTree do).

Kind Regards,

Hussein


ALL4TEC
Previous Topic:TreeViewer can not delete the firstchild
Next Topic:TableViewer evaluation
Goto Forum:
  


Current Time: Wed Aug 27 19:20:33 EDT 2014

Powered by FUDForum. Page generated in 0.02292 seconds