Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Invalid thread acces after workbench.close();
Invalid thread acces after workbench.close(); [message #118178] Sun, 11 January 2009 05:38 Go to next message
Boris Stepanov is currently offline Boris StepanovFriend
Messages: 68
Registered: July 2009
Member
Hi all!

I invoked workbench.close() in WorkbenchAdvisor.postStartup() and
exception is occured:

org.eclipse.swt.SWTException: Invalid thread access
at org.eclipse.swt.SWT.error(SWT.java:2572)
at org.eclipse.swt.SWT.error(SWT.java:2492)
at org.eclipse.swt.SWT.error(SWT.java:2463)
at org.eclipse.swt.widgets.Widget.error(Widget.java:790)
at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:720)
at org.eclipse.swt.widgets.Control.getBounds(Control.java:752)
at
org.eclipse.rwt.lifecycle.ControlLCAUtil.readBounds(ControlL CAUtil.java:171)
at
org.eclipse.swt.internal.widgets.shellkit.ShellLCA.readData( ShellLCA.java:61)
at
org.eclipse.swt.internal.widgets.displaykit.DisplayLCA$1.doV isit(DisplayLCA.java:322)
at
org.eclipse.swt.internal.widgets.WidgetTreeVisitor$AllWidget TreeVisitor.visit(WidgetTreeVisitor.java:32)
at
org.eclipse.swt.internal.widgets.WidgetTreeVisitor.accept(Wi dgetTreeVisitor.java:46)
at
org.eclipse.swt.internal.widgets.displaykit.DisplayLCA.readD ata(DisplayLCA.java:329)
at org.eclipse.rwt.internal.lifecycle.ReadData.execute(ReadData .java:26)
at
org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.continueLife Cycle(RWTLifeCycle.java:206)
at
org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadCont roller.run(RWTLifeCycle.java:115)
at java.lang.Thread.run(Thread.java:595)

Do you have any ideas how to fix it?
Re: Invalid thread acces after workbench.close(); [message #118290 is a reply to message #118178] Mon, 12 January 2009 13:03 Go to previous messageGo to next message
Rüdiger Herrmann is currently offline Rüdiger HerrmannFriend
Messages: 581
Registered: July 2009
Senior Member
are you sure that you cant to close the workbench at startup? If so,
please provide the code that causes the exception.


Boris Stepanov wrote:
> Hi all!
>
> I invoked workbench.close() in WorkbenchAdvisor.postStartup() and
> exception is occured:
>
> org.eclipse.swt.SWTException: Invalid thread access
> at org.eclipse.swt.SWT.error(SWT.java:2572)
> at org.eclipse.swt.SWT.error(SWT.java:2492)
> at org.eclipse.swt.SWT.error(SWT.java:2463)
> at org.eclipse.swt.widgets.Widget.error(Widget.java:790)
> at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:720)
> at org.eclipse.swt.widgets.Control.getBounds(Control.java:752)
> at
> org.eclipse.rwt.lifecycle.ControlLCAUtil.readBounds(ControlL CAUtil.java:171)
>
> at
> org.eclipse.swt.internal.widgets.shellkit.ShellLCA.readData( ShellLCA.java:61)
>
> at
> org.eclipse.swt.internal.widgets.displaykit.DisplayLCA$1.doV isit(DisplayLCA.java:322)
>
> at
> org.eclipse.swt.internal.widgets.WidgetTreeVisitor$AllWidget TreeVisitor.visit(WidgetTreeVisitor.java:32)
>
> at
> org.eclipse.swt.internal.widgets.WidgetTreeVisitor.accept(Wi dgetTreeVisitor.java:46)
>
> at
> org.eclipse.swt.internal.widgets.displaykit.DisplayLCA.readD ata(DisplayLCA.java:329)
>
> at
> org.eclipse.rwt.internal.lifecycle.ReadData.execute(ReadData .java:26)
> at
> org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.continueLife Cycle(RWTLifeCycle.java:206)
>
> at
> org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadCont roller.run(RWTLifeCycle.java:115)
>
> at java.lang.Thread.run(Thread.java:595)
>
> Do you have any ideas how to fix it?
Re: Invalid thread acces after workbench.close(); [message #118470 is a reply to message #118290] Thu, 15 January 2009 09:07 Go to previous message
Boris Stepanov is currently offline Boris StepanovFriend
Messages: 68
Registered: July 2009
Member
Hi Rüdiger,

I changed startup behavior now and don't close workbench anymore.

I closed workbench in postStartup() method, because comment for
WorkbenchAdvisor.postStartup allows it: "It is okay to call
<code>IWorkbench.close()</code> from this method." I used this ability
to check license, show error and close application in RCP based application.

> are you sure that you cant to close the workbench at startup? If so,
> please provide the code that causes the exception.
>
>
> Boris Stepanov wrote:
>> Hi all!
>>
>> I invoked workbench.close() in WorkbenchAdvisor.postStartup() and
>> exception is occured:
>>
>> org.eclipse.swt.SWTException: Invalid thread access
>> at org.eclipse.swt.SWT.error(SWT.java:2572)
>> at org.eclipse.swt.SWT.error(SWT.java:2492)
>> at org.eclipse.swt.SWT.error(SWT.java:2463)
>> at org.eclipse.swt.widgets.Widget.error(Widget.java:790)
>> at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:720)
>> at org.eclipse.swt.widgets.Control.getBounds(Control.java:752)
>> at
>> org.eclipse.rwt.lifecycle.ControlLCAUtil.readBounds(ControlL CAUtil.java:171)
>>
>> at
>> org.eclipse.swt.internal.widgets.shellkit.ShellLCA.readData( ShellLCA.java:61)
>>
>> at
>> org.eclipse.swt.internal.widgets.displaykit.DisplayLCA$1.doV isit(DisplayLCA.java:322)
>>
>> at
>> org.eclipse.swt.internal.widgets.WidgetTreeVisitor$AllWidget TreeVisitor.visit(WidgetTreeVisitor.java:32)
>>
>> at
>> org.eclipse.swt.internal.widgets.WidgetTreeVisitor.accept(Wi dgetTreeVisitor.java:46)
>>
>> at
>> org.eclipse.swt.internal.widgets.displaykit.DisplayLCA.readD ata(DisplayLCA.java:329)
>>
>> at
>> org.eclipse.rwt.internal.lifecycle.ReadData.execute(ReadData .java:26)
>> at
>> org.eclipse.rwt.internal.lifecycle.RWTLifeCycle.continueLife Cycle(RWTLifeCycle.java:206)
>>
>> at
>> org.eclipse.rwt.internal.lifecycle.RWTLifeCycle$UIThreadCont roller.run(RWTLifeCycle.java:115)
>>
>> at java.lang.Thread.run(Thread.java:595)
>>
>> Do you have any ideas how to fix it?
Previous Topic:Running an application using workspace RWT plugins
Next Topic:Using umages in branding html
Goto Forum:
  


Current Time: Fri Jan 27 02:55:04 GMT 2023

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

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

Back to the top