Bug 309078 - TreeViewer with TreeColumn
Summary: TreeViewer with TreeColumn
Status: NEW
Alias: None
Product: XWT
Classification: Technology
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows Vista
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-04-14 04:48 EDT by Konstantin Scheglov CLA
Modified: 2013-01-24 15:32 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Konstantin Scheglov CLA 2010-04-14 04:48:39 EDT
Build Identifier: 

See http://www.eclipse.org/forums/index.php?t=msg&th=166248&start=0& for message with formatting.

Following code causes exception.
It seems that by some reason "headerVisible" is trying to apply to TreeColumn instead of Tree itself.

Same code, with replacement of word "Tree" with "Table" works without any problem.

[code]<Shell xmlns="http://www.eclipse.org/xwt/presentation" xmlns:x="http://www.eclipse.org/xwt">
	<Shell.layout>
		<RowLayout/>
	</Shell.layout>
	<TreeViewer x:Style="BORDER">
		<TreeViewer.tree headerVisible="true" linesVisible="true">
			<TreeColumn text="New Column" width="100"/>
		</TreeViewer.tree>
	</TreeViewer>
</Shell>[/code]

[code]java.lang.IllegalArgumentException: object is not an instance of declaring class
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.eclipse.e4.xwt.javabean.metadata.properties.BeanProperty.setValue(BeanProperty.java:72)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.initSegmentAttribute(ResourceLoader.java:1610)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.initAttribute(ResourceLoader.java:1388)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.init(ResourceLoader.java:1056)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.initSegmentAttribute(ResourceLoader.java:1643)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.initAttribute(ResourceLoader.java:1388)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.init(ResourceLoader.java:1056)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.doCreate(ResourceLoader.java:622)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.doCreate(ResourceLoader.java:658)
	at org.eclipse.e4.xwt.javabean.ResourceLoader.createCLRElement(ResourceLoader.java:363)
	at org.eclipse.e4.xwt.internal.core.Core.createCLRElement(Core.java:606)
	at org.eclipse.e4.xwt.internal.core.Core.load(Core.java:646)
	at org.eclipse.e4.xwt.internal.core.Core.load(Core.java:633)
	at org.eclipse.e4.xwt.XWTLoader.loadWithOptions(XWTLoader.java:835)
	at org.eclipse.e4.xwt.XWTLoader$1.run(XWTLoader.java:768)
	at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
	at org.eclipse.e4.xwt.XWTLoader.open(XWTLoader.java:762)
	at org.eclipse.e4.xwt.XWTLoader.open(XWTLoader.java:714)
	at org.eclipse.e4.xwt.XWT.open(XWT.java:416)
	at test.MyTest.main(MyTest.java:21)
[/code]

Reproducible: Always