• Post Reply Bookmark Topic Watch Topic
  • New Topic

JDialog [setModal(boolean modal)]

 
Adrian Krebs
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i have create a JDialog and set the modal-attribute on true. Now when I change the Window and will return to the Dialog by clicking on the Task-List then the Frame got Focus but the Dialog is in the background and isn't visible so you can't continue using the program. Just if you minimize all windows the dialog will appear.
Thanks for any help!!!
Sorry for my bad english!!!
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use the JDialog constructor that specifies a parent frame. Then, when the parent frame is selected in the taskbar, the JDialog will come to the top instead.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!