• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

Problem with two Dialogs sharing a parent

 
Ranch Hand
Posts: 401
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have an applet which appears as a button, and when the user clicks on it, a modal Dialog (mainDialog) is opened.

When certain events occur on mainDialog, a smaller modal Dialog (subDialog) appears.

Both Dialogs have the applet frame as their parents, and the problem is that input is be blocked to subDialog when it is shown.

I have tried to call mainDialog.setModal(false) just before subDialog is constructed and displayed, but it has no effect. (However, just to test, when making mainDialog non-modal at construction everything works fine).

Does anyone have the solution workaround for how I can make these two modal Dialogs successfully share the same parent?

Thanks in advance,
James
 
author and iconoclast
Posts: 24203
43
Mac OS X Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Shouldn't the main dialog be the parent of the subdialog?
 
James Hodgkiss
Ranch Hand
Posts: 401
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ernest, thanks for the reply. Unfortunately I'm working with JDK1.1 so the parent must be a Frame...
 
If you live in a cold climate and on the grid, incandescent light can use less energy than LED. Tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic