import javax.swing.*;
import java.awt.*;
+import static java.awt.BorderLayout.CENTER;
+import static javax.swing.WindowConstants.DISPOSE_ON_CLOSE;
+
class Main {
JFrame frame = new JFrame("Sixth 3D engine demos");
// Keep application running until last frame is closed.
- frame.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE);
+ frame.setDefaultCloseOperation(DISPOSE_ON_CLOSE);
frame.getContentPane().setLayout(new BorderLayout());
- frame.getContentPane().add(new ApplicationListPanel(), BorderLayout.CENTER);
+ frame.getContentPane().add(new ApplicationListPanel(), CENTER);
frame.setSize(400, 300);
frame.setLocationRelativeTo(null); // center frame on screen