Java Code Examples for javax.swing.JFrame.MAXIMIZED_BOTH

The following are Jave code examples for showing how to use MAXIMIZED_BOTH of the javax.swing.JFrame class. You can vote up the examples you like. Your votes will be used in our system to get more good examples.
+ Save this method
Example 1
Project: org.alloytools.alloy   File: OurUtil.java   View Source Code Vote up 4 votes
/** This method alternatingly maximizes or restores the window. */
public static void zoom(JFrame frame) {
	int both = JFrame.MAXIMIZED_BOTH;
	frame.setExtendedState((frame.getExtendedState() & both) != both ? both : JFrame.NORMAL);
}
 
Example 2
Project: Luyten4Forge   File: WindowPosition.java   View Source Code Vote up 4 votes
public void readPositionFromWindow(JFrame window) {
	isFullScreen = (window.getExtendedState() == JFrame.MAXIMIZED_BOTH);
	if (!isFullScreen) {
		this.readPositionFromComponent(window);
	}
}
 
Example 3
Project: Tarski   File: OurUtil.java   View Source Code Vote up 4 votes
/** This method alternatingly maximizes or restores the window. */
public static void zoom(JFrame frame) {
   int both = JFrame.MAXIMIZED_BOTH;
   frame.setExtendedState((frame.getExtendedState() & both)!=both ? both : JFrame.NORMAL);
}
 
Example 4
Project: Tarski   File: OurUtil.java   View Source Code Vote up 4 votes
/** This method alternatingly maximizes or restores the window. */
public static void zoom(JFrame frame) {
   int both = JFrame.MAXIMIZED_BOTH;
   frame.setExtendedState((frame.getExtendedState() & both)!=both ? both : JFrame.NORMAL);
}