Skip to main content



      Home
Home » Archived » Visual Editor (VE) » getClass().getName() returns org.eclipse.swt.widgets.Composite
getClass().getName() returns org.eclipse.swt.widgets.Composite [message #129375] Mon, 31 July 2006 14:24 Go to next message
Eclipse UserFriend
Hi,

If I generate the following code when dropping from Palette :

composite = new MyComposite(this,SWT.NONE);
composite.setText(getClass().getName());

the getClass().getName() returns org.eclipse.swt.widgets.Composite
instead of the current editing class. If I save the file, and reopen,
it returns the correct fully qualified classname.

It is because the current editing class never gets compiled? Thanks.
Is there anyway I can get the name of the current classname
programatically? Thanks.
Re: getClass().getName() returns org.eclipse.swt.widgets.Composite [message #129629 is a reply to message #129375] Mon, 07 August 2006 10:34 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

Yup, since it wasn't compiled yet, it used the super class instance
instead, which was compiled. It was compiled the next time so that it
could use it. There is no way to force this.


--
Thanks,
Rich Kulp
Re: getClass().getName() returns org.eclipse.swt.widgets.Composite [message #613719 is a reply to message #129375] Mon, 07 August 2006 10:34 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

Yup, since it wasn't compiled yet, it used the super class instance
instead, which was compiled. It was compiled the next time so that it
could use it. There is no way to force this.


--
Thanks,
Rich Kulp
Previous Topic:Create SWT Widget in Containment Handler of parent Composite
Next Topic:With or without the use VE?
Goto Forum:
  


Current Time: Sat Jun 14 14:24:53 EDT 2025

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

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

Back to the top