calculator.java
1 |
|
2 |
|
3 |
class calculator { |
4 |
public calculator() { |
5 |
JPanel panel = new JPanel(); |
6 |
createGUI(); |
7 |
} |
8 |
|
9 |
public void createGUI() { |
10 |
JFrame window = new JFrame("Rekenmachine"); |
11 |
|
12 |
for(int i = 0; i<10; i++) { |
13 |
JButton button = new NumberButton(i); |
14 |
window.add(button); |
15 |
} |
16 |
window.setVisible(true); |
17 |
} |
18 |
|
19 |
public static void main(String[] args) { |
20 |
} |
21 |
} |
22 |