Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » JFace » Open a JFace Dialog over another JFace Dialog
icon5.gif  Open a JFace Dialog over another JFace Dialog [message #1113654] Sat, 21 September 2013 13:19 Go to next message
Jayant Gupta is currently offline Jayant GuptaFriend
Messages: 10
Registered: March 2012
Junior Member

I have a custom JFace Dialog (called PropertyDialog) which extends the FormDialog. I would like to open a modal message Dialog over the PropertryDialog as soon as it opens, to display a message to the user.

How could this be accomplished? Would I have to override the open() method? Note that it is required that the does not return until a button is pressed on the button bar.

Thanks for your help.

Re: Open a JFace Dialog over another JFace Dialog [message #1123078 is a reply to message #1113654] Wed, 02 October 2013 07:08 Go to previous message
Thorsten Schlathölter is currently offline Thorsten SchlathölterFriend
Messages: 307
Registered: February 2012
Location: Düsseldorf
Senior Member
If you want to block the dialog I would not override the open method because you would have to open your dialog before calling By that time the FormDialog shell has not yet been created and you need to show your MessageDialog over that shell. Instead you could simply add the follwing asyncExec to your implementation of createFormContent().

getShell().getDisplay().asyncExec(new Runnable() {
   public void run() {
      MessageDialog.openInformation(getShell(), "Some Title", "Some info to the user");

Previous Topic:Finding sub menu for a menu manager (Project Explorer)
Next Topic:Project Explorer Undo/Redo Operation
Goto Forum:

Current Time: Fri Nov 16 12:14:58 GMT 2018

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

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

Back to the top