Browse Source

refactor: Sum and equal sign

remotes/origin/develop
fdai7460 2 years ago
parent
commit
5379815cc5
  1. 16
      src/main/java/src/TasksFrame.java

16
src/main/java/src/TasksFrame.java

@ -143,7 +143,7 @@ public class TasksFrame extends JFrame {
y.setVisible(true);
JTextField result = new JTextField();
result.setBounds(100,50,30,20);
result.setBounds(100,50,40,20);
result.setVisible(true);
JButton difference = new JButton("Difference");
@ -180,12 +180,22 @@ public class TasksFrame extends JFrame {
a.setBounds(10, 50, 30, 20);
a.setVisible(true);
JLabel sum = new JLabel();
sum.setBounds(40, 50, 10, 20);
sum.setVisible(true);
sum.setText("+");
JTextField b = new JTextField();
b.setBounds(50, 50, 30, 20);
b.setVisible(true);
JLabel equal = new JLabel();
equal.setBounds(90, 50, 30, 20);
equal.setVisible(true);
equal.setText("=");
JTextField result = new JTextField();
result.setBounds(100, 50, 30, 20);
result.setBounds(100, 50, 40, 20);
result.setVisible(true);
JButton add = new JButton("add");
@ -205,8 +215,10 @@ public class TasksFrame extends JFrame {
jPanel.add(a);
jPanel.add(b);
jPanel.add(equal);
jPanel.add(result);
jPanel.add(add);
jPanel.add(sum);
}

Loading…
Cancel
Save