Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » How to create multiple Display objects?
How to create multiple Display objects? [message #1768667] Fri, 21 July 2017 07:26 Go to next message
Ralph Reichts is currently offline Ralph ReichtsFriend
Messages: 1
Registered: July 2017
Junior Member
Hello guys,

due to a massive memory leak with the SWT browser widget (ref https://bugs.eclipse.org/bugs/show_bug.cgi?id=134646) I am in need to create at least one other Display instance. I am fully aware that "it is not recommended" and any application should "almost always" only use one display instance. Though I haven't found any specific reasons why this is supported (on windows) but in fact a bad idea. So I still do hope, that there is a workaround for that.

My goal is to use another display instance to draw (only) the browser in a part so I can dispose the display when the part is closed and finally be able to free all allocated memory.

As I am already in the GUI-Thread when the part is created and I try to create another object instance, I of course recieve the "invalid thread exception".

Does anyone know a way to get around this problem? Any help would be much appreciated. Even if it's a clear statement, that this is at the moment not achievable.

Thank a lot!
Re: How to create multiple Display objects? [message #1769013 is a reply to message #1768667] Tue, 25 July 2017 16:22 Go to previous message
Brian de Alwis is currently offline Brian de AlwisFriend
Messages: 772
Registered: January 2012
Senior Member

You'll have to fork a new thread and create the new display instance there. That thread will become your UI thread for that second instance.

Eclipse Platform committer. Ask me about Eclipse support, training, and consulting.
Previous Topic:Eclipse 4 with Spring and Hibernate
Next Topic:Could not resolve module: org.eclipse.equinox.security.ui
Goto Forum:
  


Current Time: Mon Sep 24 01:37:05 GMT 2018

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

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

Back to the top