PIbd-21 Belianin N.N. LabWork03 Hard #4
@ -26,7 +26,7 @@ public class FormTank {
|
||||
private AbstractStrategy abstractStrategy;
|
||||
Canvas canv;
|
||||
static int pictureBoxWidth = 980;
|
||||
static int pictureBoxHeight = 570;
|
||||
static int pictureBoxHeight = 560;
|
||||
public JButton buttonSelectTank;
|
||||
public JFrame Frame;
|
||||
|
||||
@ -37,7 +37,7 @@ public class FormTank {
|
||||
public FormTank() {
|
||||
SelectedVehicle = null;
|
||||
Frame = new JFrame("Tank");
|
||||
JButton buttonCreate = new JButton("Добавить бронетехнику");
|
||||
JButton buttonCreateArmoVehicle = new JButton("Добавить бронетехнику");
|
||||
JButton buttonCreateTank = new JButton("Добавить танк");
|
||||
JButton buttonStrategysStep = new JButton("Шаг");
|
||||
buttonSelectTank = new JButton("Добавить");
|
||||
@ -139,7 +139,7 @@ public class FormTank {
|
||||
}
|
||||
}
|
||||
);
|
||||
buttonCreate.addActionListener(
|
||||
buttonCreateArmoVehicle.addActionListener(
|
||||
new ActionListener() {
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
Random random = new Random();
|
||||
@ -195,7 +195,7 @@ public class FormTank {
|
||||
Frame.setLayout(null);
|
||||
canv = new Canvas();
|
||||
canv.setBounds(0, 0, pictureBoxWidth, pictureBoxHeight);
|
||||
buttonCreate.setBounds(2, 520, 180, 40);
|
||||
buttonCreateArmoVehicle.setBounds(2, 520, 180, 40);
|
||||
buttonCreateTank.setBounds(185, 520, 150, 40);
|
||||
up.setBounds(900, 480, 40, 40);
|
||||
down.setBounds(900, 520, 40, 40);
|
||||
@ -206,7 +206,7 @@ public class FormTank {
|
||||
buttonSelectTank.setBounds(pictureBoxWidth / 2, 530, 150, 30);
|
||||
Frame.add(buttonSelectTank);
|
||||
Frame.add(canv);
|
||||
Frame.add(buttonCreate);
|
||||
Frame.add(buttonCreateArmoVehicle);
|
||||
Frame.add(buttonCreateTank);
|
||||
Frame.add(up);
|
||||
Frame.add(down);
|
||||
|
Loading…
Reference in New Issue
Block a user