File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Swing / AWT / SWT and the fly likes SWT window freezes swing windows Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "SWT window freezes swing windows" Watch "SWT window freezes swing windows" New topic
Author

SWT window freezes swing windows

Liwuen Chew
Greenhorn

Joined: Mar 11, 2010
Posts: 24
Hi everyone!
Right now I'm facing with a "swing freeze" problem. I have two forms, one made using swing and the second using SWT. If I call the SWT one from the swing one, everything in the swing one freeze until the SWT form is closed.
Well, I have a Jmenu which lets me access to the SWT form. If I click the option, the menu freeze still open (and the whole form also freeze) and the SWT form is open. If I close the SWT one, everything comes back again to normal in the swing world.

I have something like this in the swing window


which opens the SWT form. Am I doing something wrong? Thanks!
Liwuen Chew
Greenhorn

Joined: Mar 11, 2010
Posts: 24
Hey that was easy!
Only made a thread and make your SWT application to implement Runnable and that's it!

It would be something like

a) In the SWT form:


b) When you call it:


With these two items, you can use both the SWT and swing forms at the same time!

Hope this helps everyone with the same issue!
 
 
subject: SWT window freezes swing windows