my dog learned polymorphism
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

SWT window freezes swing windows

Liwuen Chew

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

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!
Have you checked out Aspose?
subject: SWT window freezes swing windows
It's not a secret anymore!