Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » XWT.
XWT. [message #574054] Tue, 13 April 2010 14:43 Go to next message
Konstantin Scheglov is currently offline Konstantin Scheglov
Messages: 554
Registered: July 2009
Senior Member
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.

<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>

java.lang.IllegalArgumentException: object is not an instance of declaring class
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.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.initSegmentAttrib ute(ResourceLoader.java:1610)
at org.eclipse.e4.xwt.javabean.ResourceLoader.initAttribute(Res ourceLoader.java:1388)
at org.eclipse.e4.xwt.javabean.ResourceLoader.init(ResourceLoad er.java:1056)
at org.eclipse.e4.xwt.javabean.ResourceLoader.initSegmentAttrib ute(ResourceLoader.java:1643)
at org.eclipse.e4.xwt.javabean.ResourceLoader.initAttribute(Res ourceLoader.java:1388)
at org.eclipse.e4.xwt.javabean.ResourceLoader.init(ResourceLoad er.java:1056)
at org.eclipse.e4.xwt.javabean.ResourceLoader.doCreate(Resource Loader.java:622)
at org.eclipse.e4.xwt.javabean.ResourceLoader.doCreate(Resource Loader.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)

--
Konstantin Scheglov,
Instantiations, Inc.


Konstantin Scheglov,
Google, Inc.
Re: XWT. [message #574159 is a reply to message #574054] Wed, 14 April 2010 07:48 Go to previous message
Yves YANG is currently offline Yves YANG
Messages: 687
Registered: July 2009
Senior Member
The tests on Tree is limited. Please fill a bug and we will take care of it
ASAP.

Thanks
yves
"Konstantin Scheglov" <Konstantin.Scheglov@gmail.com> wrote in message
news:hq1vv2$1t8$1@build.eclipse.org...
> 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.
>
> <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>
>
> java.lang.IllegalArgumentException: object is not an instance of declaring
> class
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.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.initSegmentAttrib ute(ResourceLoader.java:1610)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.initAttribute(Res ourceLoader.java:1388)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.init(ResourceLoad er.java:1056)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.initSegmentAttrib ute(ResourceLoader.java:1643)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.initAttribute(Res ourceLoader.java:1388)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.init(ResourceLoad er.java:1056)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.doCreate(Resource Loader.java:622)
> at
> org.eclipse.e4.xwt.javabean.ResourceLoader.doCreate(Resource Loader.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)
>
> --
> Konstantin Scheglov,
> Instantiations, Inc.
Previous Topic:XWT. TreeViewer with TreeColumn.
Next Topic:XWT. Support for TableColumnLayout.
Goto Forum:
  


Current Time: Sat Sep 20 00:05:28 GMT 2014

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

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