Java examples for Swing:JFrame
Maximizes a JFrame, just like the 'maximize window' button does.
//package com.java2s; import java.awt.Frame; import javax.swing.JFrame; public class Main { /**/*from ww w. j a v a 2s . c o m*/ * Maximizes a JFrame, just like the 'maximize window' button does. * <p> * @param f The frame to maximize. */ public static void maximizeJFrame(JFrame f) { f.setExtendedState(Frame.MAXIMIZED_BOTH); } }