• Post Reply Bookmark Topic Watch Topic
  • New Topic

Disable Window closing

 
MEHULecs DIKSHITecs
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
public class DSInfoDlg extends JDialog
{
super (fParent, RM.getString(R_designer.DLGT_DS_INFO));
setModal (true);
setDefaultCloseOperation(JDialog.DO_NOTHING_ON_CLOSE);
}
This works fine but the [X] button in title bar for window closing shows as enable. This creates a doubt to the user who may use this work of mine as to why the window is not closing.
I wanted to know if we can disable (totally remove) this button in the title bar.
please help me out in this.
Regards
Mehul
 
Mark Spritzler
ranger
Sheriff
Posts: 17309
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is this question in regards to the SCJD? It might be better answered in the Swing or Java Beginner's forums.
Also your name does not conform to our JavaRanch naming standards. Please change your name accordingly in your profile page. Thanks and welcome to JavaRanch.
Mark
 
Gravity is a harsh mistress. But this tiny ad is pretty easy to deal with:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!