мелкие ошибки

This commit is contained in:
AnnaLioness 2023-11-07 16:05:40 +04:00
parent 7770c539ae
commit 5508315dd2
2 changed files with 11 additions and 13 deletions

View File

@ -181,7 +181,6 @@ public class FormContainerShip{
right.addActionListener(actioListener);
w.setSize (1000, 600);
w.setDefaultCloseOperation (JFrame.EXIT_ON_CLOSE);
w.setLayout(null);
canv = new Canvas();
canv.setBounds(0, 0, 1000, 600);

View File

@ -149,9 +149,8 @@ public class FormShipCollection {
return;
}
FormContainerShip form = new FormContainerShip();
form._drawingShip = removedShips.peek();
form._drawingShip = removedShips.pop();
form._drawingShip.SetPosition(100, 100);
removedShips.pop();
form.Draw();
}
}
@ -203,17 +202,17 @@ public class FormShipCollection {
w.setDefaultCloseOperation (JFrame.EXIT_ON_CLOSE);
w.setLayout(null);
canv.setBounds(0, 0, pictureBoxWidth, pictureBoxHeight);
ButtonAddShip.setBounds(pictureBoxWidth, 0, 120, 20);
TextBoxNumber.setBounds(pictureBoxWidth, 50, 120, 20);
ButtonDeleteShip.setBounds(pictureBoxWidth, 80, 120, 20);
ButtonRefreshCollection.setBounds(pictureBoxWidth, 120, 120, 20);
forNewForm.setBounds(pictureBoxWidth, 150, 120, 20);
ButtonAddShip.setBounds(pictureBoxWidth, 0, 130, 20);
TextBoxNumber.setBounds(pictureBoxWidth, 50, 130, 20);
ButtonDeleteShip.setBounds(pictureBoxWidth, 80, 130, 20);
ButtonRefreshCollection.setBounds(pictureBoxWidth, 130, 120, 20);
forNewForm.setBounds(pictureBoxWidth, 150, 130, 20);
buttonAddSet.setBounds(pictureBoxWidth, 180, 120, 20);
textBoxSetName.setBounds(pictureBoxWidth, 210, 120, 20);
jListStorage.setBounds(pictureBoxWidth, 240, 120, 60);
buttonRemoveSet.setBounds(pictureBoxWidth, 310, 120, 20);
buttonGetRemoved.setBounds(pictureBoxWidth, 340, 120, 20);
buttonAddSet.setBounds(pictureBoxWidth, 180, 130, 20);
textBoxSetName.setBounds(pictureBoxWidth, 210, 130, 20);
jListStorage.setBounds(pictureBoxWidth, 240, 130, 60);
buttonRemoveSet.setBounds(pictureBoxWidth, 310, 130, 20);
buttonGetRemoved.setBounds(pictureBoxWidth, 340, 130, 20);
w.add(canv);
w.add(ButtonAddShip);
w.add(ButtonDeleteShip);