• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JDialog questions

 
Ranch Hand
Posts: 2378
MySQL Database Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi racnhers, please help on the following scenarios....
(1) Can i hide the title bar of a JDialog? If yes, how? I know if i dont need title bar then its better to use JWindow....but i need JDialog in my case.
(2) Say my parent JWindow or JFrame has 5 JDialogs....then when i click on one dialog i want all the other dialog boxes to go in the back or be minimized/disabled and my activated dialog come front with visibilty. I am facing problem with this...
 
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No, I don't believe you can get rid of the title bar of a JDialog.
My question is why so many JDialogs all at once? And are they all modal?
Maybe if you explained to us what you are doing, we could help you figure out the best way to go about it. Maybe help you with some design issues??
 
Ashik Uzzaman
Ranch Hand
Posts: 2378
MySQL Database Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thnx Gregg, I know u r always helpful.
For the first title bar problem, ya i also think so but wanted some suports...
For the secodn issue, my frnd & colleague Wahid Sadik showed me from swing API that there is a method for JInternalFrame moveToFront(JInternalFrame f) to select among a bunch of internal frames which one to come out at first. So the problem is partially solved....now just if i can manage another method for JDialogs that would be excellent....yet to find out one...
We r working in a medium-large project using Swing, Beans, Oracle, XML & some popular design patterns with Java.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, I did some testing with some NON-MODAL JDialogs and found out that there is a toFront() method just like with all other Windows that will pull whatever JDialog you want to the front. However, If your JDialogs are MODAL, then the problem lies with the nature of MODAL windows. When a window is MODAL, then as soon as you set it to visible(true), any other events that take place after that line of code in the event are put on hold until that MODAL window gets terminated. So without knowing what you need your program to do, it is kind of hard to figure out an alternative for you.
My main question is why so many JDialog Windows and are they all MODAL?
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic