Changeset 27387 in osm for applications/editors/josm/plugins/alignways/src/com/tilusnet
- Timestamp:
- 2012-01-02T02:18:12+01:00 (13 years ago)
- Location:
- applications/editors/josm/plugins/alignways/src/com/tilusnet/josm/plugins/alignways
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/alignways/src/com/tilusnet/josm/plugins/alignways/AlignWaysDialog.java
r27348 r27387 17 17 import javax.swing.BoxLayout; 18 18 import javax.swing.ButtonGroup; 19 import javax.swing.JCheckBoxMenuItem; 19 20 import javax.swing.JLabel; 20 21 import javax.swing.JPanel; … … 147 148 148 149 if (activeMode == true) { 149 // we're in alignways mode150 // we're in alignways mode 150 151 activateInfoPanel.setVisible(false); 151 152 modesPanel.setVisible(true); … … 156 157 dlgPane.validate(); 157 158 } else { 158 // we're not in alignways mode159 // we're not in alignways mode 159 160 activateInfoPanel.setVisible(true); 160 161 modesPanel.setVisible(false); … … 168 169 } 169 170 171 public JCheckBoxMenuItem getWindowMenuItem() { 172 return windowMenuItem; 173 } 174 170 175 171 176 } -
applications/editors/josm/plugins/alignways/src/com/tilusnet/josm/plugins/alignways/AlignWaysMode.java
r27348 r27387 7 7 8 8 import java.awt.Cursor; 9 import java.awt.Dimension;10 import java.awt.Image;11 9 import java.awt.Point; 12 10 import java.awt.event.ActionEvent; … … 17 15 import javax.swing.BorderFactory; 18 16 import javax.swing.ImageIcon; 19 import javax.swing.JButton;20 17 import javax.swing.JDialog; 21 18 import javax.swing.JOptionPane; … … 91 88 IconToggleButton optBtn = AlignWaysPlugin.getOptBtn(); 92 89 if (optBtn.isSelected()) { 93 // The option panel isswitched off90 // The option panel will be switched off 94 91 optBtn.doClick(); 95 92 } … … 197 194 AlignWaysTipsPanel atp = new AlignWaysTipsPanel(); 198 195 Object[] okButton = {tr("I''m ready!")}; 199 JOptionPane tipPane = new JOptionPane(atp, JOptionPane.PLAIN_MESSAGE, JOptionPane.DEFAULT_OPTION, 200 196 JOptionPane tipPane = new JOptionPane(atp, JOptionPane.PLAIN_MESSAGE, JOptionPane.DEFAULT_OPTION, 197 null, okButton, okButton[0]); 201 198 tipPane.setBorder(BorderFactory.createEmptyBorder(10, 10, 30, 10)); 202 199 JDialog tipDialog = tipPane.createDialog(Main.parent, tr("AlignWays Tips")); -
applications/editors/josm/plugins/alignways/src/com/tilusnet/josm/plugins/alignways/AlignWaysPlugin.java
r27348 r27387 39 39 alignWaysMenuItem = MainMenu.add(Main.main.menu.toolsMenu, awAction); 40 40 awDialog = new AlignWaysDialog(awMode); 41 // Prevent user clicking on the Windows menu entry while panel is meaningless 42 awDialog.getWindowMenuItem().setEnabled(false); 41 43 } 42 44 … … 48 50 if (Main.map != null) { 49 51 Main.map.addMapMode(btn); 52 // Re-enable menu item in Windows menu 53 awDialog.getWindowMenuItem().setEnabled(true); 50 54 } 51 55 }
Note:
See TracChangeset
for help on using the changeset viewer.