Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

close option in JDialog

 
Ling Chung
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
how can i provide a JDialog that doesn't have a close option (the 'x' in the top right corner of the frame)?
Thanks for the help!!
 
Gregg Bolinger
GenRocket Founder
Ranch Hand
Posts: 15302
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, but you can make it so that the x doesn't do anything.
setDefaultCloseOperation(DO_NOTHING_ON_CLOSE);
The other option is you could just use a JWindow which most people use for a splash screen as it has not "Title Bar" at all.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic