Удалены лишние пробелы и комментарии. Сданная сложная Лаб 3
This commit is contained in:
parent
55e0a35928
commit
d66ca977a5
@ -20,8 +20,6 @@ public class FormEntityWithExtraGallery extends JComponent {
|
||||
setLayout(new BorderLayout());
|
||||
add(statusPanel, BorderLayout.SOUTH);
|
||||
|
||||
|
||||
|
||||
JButton showRandomEntity = new JButton("Create entity from parts");
|
||||
showRandomEntity.addActionListener(e -> {
|
||||
|
||||
|
@ -56,7 +56,6 @@ public class FormLocomotive extends JComponent{
|
||||
JButton selectLocomotiveButton = new JButton("Select");
|
||||
selectLocomotiveButton.addActionListener(e -> {
|
||||
SelectedLocomotive = _locomotive;
|
||||
//TODO
|
||||
caller.dispose();
|
||||
});
|
||||
|
||||
|
@ -16,7 +16,6 @@ public class FormMapWithSetLocomotives extends JComponent {
|
||||
formFrame.setSize(750, 500);
|
||||
formFrame.setLocationRelativeTo(null);
|
||||
|
||||
|
||||
Panel statusPanel = new Panel();
|
||||
statusPanel.setBackground(Color.WHITE);
|
||||
statusPanel.setLayout(new GridLayout(0, 1, 20, 20));
|
||||
@ -65,18 +64,13 @@ public class FormMapWithSetLocomotives extends JComponent {
|
||||
{
|
||||
return;
|
||||
}
|
||||
// TODO
|
||||
|
||||
JDialog dialog = new JDialog(formFrame, "Dialog", true);
|
||||
FormLocomotive formLocomotive = new FormLocomotive(dialog);
|
||||
dialog.setSize(800, 500);
|
||||
dialog.setContentPane(formLocomotive);
|
||||
dialog.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
|
||||
dialog.setVisible(true);
|
||||
|
||||
|
||||
DrawningObjectLocomotive locomotive = new DrawningObjectLocomotive(formLocomotive.getSelectedLocomotive());
|
||||
//TODO
|
||||
if (_mapLocomotivesCollectionGeneric.Plus(locomotive) != -1) {
|
||||
JOptionPane.showMessageDialog(formFrame, "Object added", "Success", JOptionPane.OK_CANCEL_OPTION);
|
||||
bufferImg = _mapLocomotivesCollectionGeneric.ShowSet();
|
||||
@ -98,7 +92,6 @@ public class FormMapWithSetLocomotives extends JComponent {
|
||||
catch (ParseException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
//Кнопка удаления локомотива
|
||||
JButton deleteLocomotiveButton = new JButton("Delete Locomotive");
|
||||
JFormattedTextField finalMaskedTextFieldPosition = maskedTextFieldPosition;
|
||||
@ -122,7 +115,6 @@ public class FormMapWithSetLocomotives extends JComponent {
|
||||
}
|
||||
});
|
||||
statusPanel.add(deleteLocomotiveButton);
|
||||
|
||||
//Кнопка просмотра хранилища
|
||||
JButton showStorageButton = new JButton("Show Storage");
|
||||
showStorageButton.addActionListener(e -> {
|
||||
@ -135,7 +127,6 @@ public class FormMapWithSetLocomotives extends JComponent {
|
||||
repaint();
|
||||
});
|
||||
statusPanel.add(showStorageButton);
|
||||
|
||||
//Кнопка просмотра карты
|
||||
JButton showOnMapButton = new JButton("Show On Map");
|
||||
showOnMapButton.addActionListener(e -> {
|
||||
@ -202,7 +193,6 @@ public class FormMapWithSetLocomotives extends JComponent {
|
||||
|
||||
formFrame.getContentPane().add(this);
|
||||
formFrame.setVisible(true);
|
||||
//super.repaint();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -29,7 +29,6 @@ public class MapWithSetLocomotivesGeneric
|
||||
}
|
||||
|
||||
/// Добавление
|
||||
//TODO
|
||||
public int Plus(T locomotive)
|
||||
{
|
||||
return this._setLocomotives.Insert(locomotive);
|
||||
@ -39,7 +38,6 @@ public class MapWithSetLocomotivesGeneric
|
||||
{
|
||||
return this._setLocomotives.Remove(position);
|
||||
}
|
||||
|
||||
/// Вывод всего набора объектов
|
||||
public BufferedImage ShowSet()
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user