Added .gitignore and application frame class

This commit is contained in:
2019-03-21 21:05:34 +01:00
parent bdb2279152
commit 2bbaec0939
5 changed files with 132 additions and 0 deletions

View File

@ -0,0 +1,47 @@
package dev.kske.minesweeper;
import java.awt.EventQueue;
import javax.swing.JFrame;
public class Minesweeper {
private JFrame mframe;
/**
* Launch the application.
*/
public static void main(String[] args) {
EventQueue.invokeLater(new Runnable() {
public void run() {
try {
Minesweeper window = new Minesweeper();
window.mframe.setVisible(true);
} catch (Exception e) {
e.printStackTrace();
}
}
});
}
/**
* Create the application.
*/
public Minesweeper() {
initialize();
}
/**
* Initialize the contents of the frame.
*/
private void initialize() {
mframe = new JFrame();
mframe.setResizable(false);
mframe.setTitle("Minesweeper");
mframe.setBounds(100, 100, 450, 300);
mframe.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
}

3
src/module-info.java Normal file
View File

@ -0,0 +1,3 @@
module Minesweeper {
requires java.desktop;
}