Skip to main content



      Home
Home » Eclipse Projects » e(fx)clipse » Opening a dialog from within a dialog(working with multiple dialogs)
Opening a dialog from within a dialog [message #1309448] Tue, 22 April 2014 14:05 Go to next message
Eclipse UserFriend
I create a dialog that opens from a menu click. There is a button on the dialog that when clicked, opens a second dialog. It works but it places the second dialog behind the first and it isn't visible. Is there a way to make the second dialog come to the front?
Re: Opening a dialog from within a dialog [message #1309479 is a reply to message #1309448] Tue, 22 April 2014 14:30 Go to previous messageGo to next message
Eclipse UserFriend
Well you probably want to pass the current dialog as the parent but
without showing us your current code I can't give you a better info.

Tom

On 22.04.14 20:05, Betsy Kramer wrote:
> I create a dialog that opens from a menu click. There is a button on
> the dialog that when clicked, opens a second dialog. It works but it
> places the second dialog behind the first and it isn't visible. Is there
> a way to make the second dialog come to the front?
Re: Opening a dialog from within a dialog [message #1309504 is a reply to message #1309479] Tue, 22 April 2014 14:47 Go to previous messageGo to next message
Eclipse UserFriend
I thought of that but the efxclipse dialog class constructor requires the first argument to be the parent window and complains when I pass it the dialog as the parent. (MessageDialog extends Dialog)

Here is my code:

public MessageDialog(Window parent, String title) {
super(parent, title);
}
Re: Opening a dialog from within a dialog [message #1309518 is a reply to message #1309504] Tue, 22 April 2014 14:57 Go to previous messageGo to next message
Eclipse UserFriend
So you pass null?

You should get access to the window e.g. of the button by calling
button.getScene().getWindow() and pass that.

Tom

On 22.04.14 20:47, Betsy Kramer wrote:
> I thought of that but the efxclipse dialog class constructor requires
> the first argument to be the parent window and complains when I pass it
> the dialog as the parent. (MessageDialog extends Dialog)
>
> Here is my code:
>
> public MessageDialog(Window parent, String title) {
> super(parent, title); }
Re: Opening a dialog from within a dialog [message #1309532 is a reply to message #1309518] Tue, 22 April 2014 15:09 Go to previous message
Eclipse UserFriend
Tom,
You are a genius! Thanks! Very Happy
Previous Topic:problem installing e(fx)clipse on my JUNO
Next Topic:javaFX in e4 vs Java application
Goto Forum:
  


Current Time: Fri Apr 18 10:42:48 EDT 2025

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

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

Back to the top