Фикс названий переменных.
This commit is contained in:
parent
ead0ac0602
commit
af8b91a1a4
@ -20,12 +20,12 @@ public class DrawingShip {
|
|||||||
private static final int _shipWidth = 135;
|
private static final int _shipWidth = 135;
|
||||||
private static final int _shipHeight = 40;
|
private static final int _shipHeight = 40;
|
||||||
|
|
||||||
public void Init(int speed, float weight, Color bodyColor, int numberOfDeks){
|
public void Init(int speed, float weight, Color bodyColor, int numberOfDecks){
|
||||||
Ship = new EntityShip();
|
Ship = new EntityShip();
|
||||||
// мметод прорисовки палуб
|
// мметод прорисовки палуб
|
||||||
drawingDecks = new DrawingDecks();
|
drawingDecks = new DrawingDecks();
|
||||||
Ship.Init(speed, weight, bodyColor);
|
Ship.Init(speed, weight, bodyColor);
|
||||||
drawingDecks.setNumberOfDecks(numberOfDeks);/////// палубы
|
drawingDecks.setNumberOfDecks(numberOfDecks);/////// палубы
|
||||||
}
|
}
|
||||||
|
|
||||||
public EntityShip getShip() {
|
public EntityShip getShip() {
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
<Component id="buttonLeft" min="-2" pref="35" max="-2" attributes="0"/>
|
<Component id="buttonLeft" min="-2" pref="35" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<Component id="labelAmountOfDeks" min="-2" max="-2" attributes="0"/>
|
<Component id="labelAmountOfDecks" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace max="-2" attributes="0"/>
|
<EmptySpace max="-2" attributes="0"/>
|
||||||
<Component id="comboBoxAmountOfDecks" min="-2" max="-2" attributes="0"/>
|
<Component id="comboBoxAmountOfDecks" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
@ -68,7 +68,7 @@
|
|||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="1" attributes="0">
|
<Group type="102" alignment="1" attributes="0">
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="labelAmountOfDeks" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="labelAmountOfDecks" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="comboBoxAmountOfDecks" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="comboBoxAmountOfDecks" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
@ -101,7 +101,7 @@
|
|||||||
<Property name="useNullLayout" type="boolean" value="true"/>
|
<Property name="useNullLayout" type="boolean" value="true"/>
|
||||||
</Layout>
|
</Layout>
|
||||||
</Container>
|
</Container>
|
||||||
<Component class="javax.swing.JLabel" name="labelAmountOfDeks">
|
<Component class="javax.swing.JLabel" name="labelAmountOfDecks">
|
||||||
<Properties>
|
<Properties>
|
||||||
<Property name="text" type="java.lang.String" value="Количество палуб"/>
|
<Property name="text" type="java.lang.String" value="Количество палуб"/>
|
||||||
</Properties>
|
</Properties>
|
||||||
@ -163,7 +163,6 @@
|
|||||||
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
|
<Property name="icon" type="javax.swing.Icon" editor="org.netbeans.modules.form.editors2.IconEditor">
|
||||||
<Image iconType="3" name="/containership/Rightarrow.png"/>
|
<Image iconType="3" name="/containership/Rightarrow.png"/>
|
||||||
</Property>
|
</Property>
|
||||||
<Property name="actionCommand" type="java.lang.String" value=""/>
|
|
||||||
<Property name="name" type="java.lang.String" value="buttonRight" noResource="true"/>
|
<Property name="name" type="java.lang.String" value="buttonRight" noResource="true"/>
|
||||||
</Properties>
|
</Properties>
|
||||||
<Events>
|
<Events>
|
||||||
|
@ -30,7 +30,7 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
private void initComponents() {
|
private void initComponents() {
|
||||||
|
|
||||||
ShipCanvas = new containership.MyCanvas();
|
ShipCanvas = new containership.MyCanvas();
|
||||||
labelAmountOfDeks = new javax.swing.JLabel();
|
labelAmountOfDecks = new javax.swing.JLabel();
|
||||||
comboBoxAmountOfDecks = new javax.swing.JComboBox<>();
|
comboBoxAmountOfDecks = new javax.swing.JComboBox<>();
|
||||||
buttonCreate = new javax.swing.JButton();
|
buttonCreate = new javax.swing.JButton();
|
||||||
statusLabel = new javax.swing.JLabel();
|
statusLabel = new javax.swing.JLabel();
|
||||||
@ -47,7 +47,7 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
labelAmountOfDeks.setText("Количество палуб");
|
labelAmountOfDecks.setText("Количество палуб");
|
||||||
|
|
||||||
comboBoxAmountOfDecks.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { "Одна", "Две", "Три" }));
|
comboBoxAmountOfDecks.setModel(new javax.swing.DefaultComboBoxModel<>(new String[] { "Одна", "Две", "Три" }));
|
||||||
|
|
||||||
@ -77,7 +77,6 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
});
|
});
|
||||||
|
|
||||||
buttonRight.setIcon(new javax.swing.ImageIcon(getClass().getResource("/containership/Rightarrow.png"))); // NOI18N
|
buttonRight.setIcon(new javax.swing.ImageIcon(getClass().getResource("/containership/Rightarrow.png"))); // NOI18N
|
||||||
buttonRight.setActionCommand("");
|
|
||||||
buttonRight.setName("buttonRight"); // NOI18N
|
buttonRight.setName("buttonRight"); // NOI18N
|
||||||
buttonRight.addActionListener(new java.awt.event.ActionListener() {
|
buttonRight.addActionListener(new java.awt.event.ActionListener() {
|
||||||
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
public void actionPerformed(java.awt.event.ActionEvent evt) {
|
||||||
@ -108,7 +107,7 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 381, Short.MAX_VALUE)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 381, Short.MAX_VALUE)
|
||||||
.addComponent(buttonLeft, javax.swing.GroupLayout.PREFERRED_SIZE, 35, javax.swing.GroupLayout.PREFERRED_SIZE))
|
.addComponent(buttonLeft, javax.swing.GroupLayout.PREFERRED_SIZE, 35, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||||
.addGroup(layout.createSequentialGroup()
|
.addGroup(layout.createSequentialGroup()
|
||||||
.addComponent(labelAmountOfDeks)
|
.addComponent(labelAmountOfDecks)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
.addComponent(comboBoxAmountOfDecks, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
.addComponent(comboBoxAmountOfDecks, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
|
||||||
@ -133,7 +132,7 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
|
.addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(labelAmountOfDeks)
|
.addComponent(labelAmountOfDecks)
|
||||||
.addComponent(comboBoxAmountOfDecks, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
.addComponent(comboBoxAmountOfDecks, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||||
.addComponent(buttonCreate))
|
.addComponent(buttonCreate))
|
||||||
@ -149,7 +148,7 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
.addContainerGap())
|
.addContainerGap())
|
||||||
);
|
);
|
||||||
|
|
||||||
labelAmountOfDeks.getAccessibleContext().setAccessibleName("");
|
labelAmountOfDecks.getAccessibleContext().setAccessibleName("");
|
||||||
|
|
||||||
pack();
|
pack();
|
||||||
}// </editor-fold>//GEN-END:initComponents
|
}// </editor-fold>//GEN-END:initComponents
|
||||||
@ -236,7 +235,7 @@ public class JFrame_Ship extends javax.swing.JFrame {
|
|||||||
private javax.swing.JButton buttonRight;
|
private javax.swing.JButton buttonRight;
|
||||||
private javax.swing.JButton buttonUp;
|
private javax.swing.JButton buttonUp;
|
||||||
private javax.swing.JComboBox<String> comboBoxAmountOfDecks;
|
private javax.swing.JComboBox<String> comboBoxAmountOfDecks;
|
||||||
private javax.swing.JLabel labelAmountOfDeks;
|
private javax.swing.JLabel labelAmountOfDecks;
|
||||||
private javax.swing.JLabel statusLabel;
|
private javax.swing.JLabel statusLabel;
|
||||||
// End of variables declaration//GEN-END:variables
|
// End of variables declaration//GEN-END:variables
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user