• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

Modal/Modeless Dialogs

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How do I achieve the following effect:
From my "tool box" dialog window, I can couble click and start one of several "tools". Several tools will be active at the same time.
Each tool is implemented as a main dialog box. It is possible to launch new dialogs from the main dialog boxes of each tool.
I need to have the dialog boxes of different tool "modeless" with respect to one another, while within a single tool, they should be "modal". The effect being that I cannot have more ONE ACTIVE DIALOG FROM THE SAME TOOL, but I will have ONE ACTIVE DIALOG FROM EACH TOOL. This is a kind of mixture of both modal and modeless. Tried to achieve it with threads, but failed.
If anyone understood my problem: Please, a hint will be greatly appreciated!
 
Ranch Hand
Posts: 135
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Rolf Moholth:

Each tool is implemented as a main dialog box. It is possible to launch new dialogs from the main dialog boxes of each tool.
I need to have the dialog boxes of different tool "modeless" with respect to one another, while within a single tool, they should be "modal". The effect being that I cannot have more ONE ACTIVE DIALOG FROM THE SAME TOOL, but I will have ONE ACTIVE DIALOG FROM EACH TOOL. This is a kind of mixture of both modal and modeless. Tried to achieve it with threads, but failed.


Create two dialog classes namely ToolDialog and InternalToolDialog which extend JDialog.Make InternalToolDialog modal in it's constructor or using setModal(true).
Use ToolDialog for your tools and in tools use InternalToolDialog
 
Politics n. Poly "many" + ticks "blood sucking insects". Tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic