Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » What's the point of Display.findDisplay(Thread) ?
What's the point of Display.findDisplay(Thread) ? [message #823892] Mon, 19 March 2012 02:06 Go to next message
Chris Fairhall is currently offline Chris FairhallFriend
Messages: 5
Registered: July 2009
Junior Member
I have a reference to the UIThread, if I call Display.findDisplay(Thread), I get an exception saying no context is available. I can't call UICallback.runNonUIThreadWithFakeContext to run in a fake context because I don't have the display yet...

I've checked the cvs history and this would have worked before rev 1.116 of Display.java.

"Applied patch from bug 337787: [Refactoring]: remove singletons and static fields in
RWT"


My problem is I have a background thread that goes through the open sessions and does some clean up. Its got access to the ui thread as it is stored in the session. There is no public way to get a Display object from a UIThread.
Re: What's the point of Display.findDisplay(Thread) ? [message #824091 is a reply to message #823892] Mon, 19 March 2012 08:49 Go to previous message
Ivan Furnadjiev is currently offline Ivan FurnadjievFriend
Messages: 2426
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
Hi Chris,
if your code works before the mentioned revision 1.116 of the Display
and not after it's probably a bug. Could you open a bugzilla with a
snippet to reproduce it?
Best,
Ivan

On 3/19/2012 4:06 AM, Chris Fairhall wrote:
> I have a reference to the UIThread, if I call
> Display.findDisplay(Thread), I get an exception saying no context is
> available. I can't call UICallback.runNonUIThreadWithFakeContext to
> run in a fake context because I don't have the display yet...
>
> I've checked the cvs history and this would have worked before rev
> 1.116 of Display.java.
> "Applied patch from bug 337787: [Refactoring]: remove singletons and
> static fields in RWT"
>
>
> My problem is I have a background thread that goes through the open
> sessions and does some clean up. Its got access to the ui thread as it
> is stored in the session. There is no public way to get a Display
> object from a UIThread.

--
Ivan Furnadjiev

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
Previous Topic:What's the point of Display.findDisplay(Thread) ?
Next Topic:How to change the background-color of Eclipse RAP view title bar?
Goto Forum:
  


Current Time: Sat Apr 27 02:54:54 GMT 2024

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

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

Back to the top