mirror of
https://github.com/macocianradu/javaGUItoolkit.git
synced 2026-03-19 06:00:04 +00:00
initial setup with top-bottom approach
This commit is contained in:
20
src/Main.java
Normal file
20
src/Main.java
Normal file
@@ -0,0 +1,20 @@
|
||||
import java.awt.event.WindowAdapter;
|
||||
import java.awt.event.WindowEvent;
|
||||
|
||||
public class Main {
|
||||
public static void main(String[] args) {
|
||||
Window win = new Window();
|
||||
win.setVisible(true);
|
||||
win.setSize(640, 480);
|
||||
win.setPositionRelativeTo(null);
|
||||
win.addWindowListener(new WindowAdapter() {
|
||||
@Override
|
||||
public void windowClosing(WindowEvent e) {
|
||||
win.dispose();
|
||||
}
|
||||
});
|
||||
|
||||
Button button = new Button();
|
||||
win.addVisual(button);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user