Changeset 22842 in osm for applications/editors/josm/plugins/alignways/src
- Timestamp:
- 2010-08-28T22:44:50+02:00 (14 years ago)
- Location:
- applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysAction.java
r22758 r22842 78 78 if (!c.areSegsAlignable()) { 79 79 JOptionPane.showMessageDialog(Main.parent, 80 tr("Please select two segments that don''t share any nodes or put the pivot on their common node.\n" +81 "Your action is being igonred."),82 tr("AlignWayS: Alignment not possible"), JOptionPane.WARNING_MESSAGE);80 tr("Please select two segments that don''t share any nodes\n" 81 + " or put the pivot on their common node.\n"), 82 tr("AlignWayS: Alignment not possible"), JOptionPane.WARNING_MESSAGE); 83 83 return false; 84 84 } … … 90 90 (c).undoCommand(); 91 91 JOptionPane.showMessageDialog(Main.parent, 92 tr("Aligning would result nodes outside the world.\n" + 93 "Your action is being ignored."), 94 tr("AlignWayS: Alignment denied"), JOptionPane.WARNING_MESSAGE); 92 tr("Aligning would result nodes outside the world.\n"), 93 tr("AlignWayS: Alignment not possible"), JOptionPane.WARNING_MESSAGE); 95 94 return false; 96 95 } -
applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysMode.java
r21613 r22842 62 62 public void exitMode() { 63 63 super.exitMode(); 64 setCurrentState(noneSelected); 64 65 Main.map.mapView.removeMouseListener(this); 65 setCurrentState(noneSelected);66 66 AlignWaysPlugin.getAwAction().setEnabled(false); 67 67 } … … 119 119 if (currentState == noneSelected) { 120 120 awSegs.cleanupWays(); 121 getCurrentDataSet().clearSelection(); 121 // FIX: getCurrentDataSet may return null when the editable layer had 122 // already been removed by JOSM. This happens e.g. when the user closes 123 // JOSM while AlignWays mode is still active. 124 if (getCurrentDataSet() != null) { 125 getCurrentDataSet().clearSelection(); 126 } 122 127 } 123 128 } -
applications/editors/josm/plugins/alignways/src/org/openstreetmap/josm/plugins/alignways/AlignWaysTipsPanel.java
r21613 r22842 96 96 97 97 step04.setIcon(new ImageIcon(getClass().getResource("/images/tipsdialog/hlpAlgCmd.png"))); // NOI18N 98 step04.setText(tr("<html>\n<div style=\"font-family:sans-serif\">\n<ul>\n <li><b>Align the segments.</b> Press <b><i><span style=\"color:green\">Shift-A</span></i></b>. Alternatively you''ll find the command in the <b>Tools</b>\n menu or may want to place the action on the <b>toolbar</b>.\n </li>\n</ul>\n</div>\n</html>\n\n")); 98 step04.setText(tr("<html>\n<div style=\"font-family:sans-serif\">\n<ul>\n <li><b>Align the segments.</b> Press <b><i><span style=\"color:green\">" 99 + AlignWaysPlugin.awAction.getShortcut().getKeyText() 100 + "</span></i></b>. Alternatively you''ll find the command in the <b>Tools</b>\n menu or may want to place the action on the <b>toolbar</b>.\n </li>\n</ul>\n</div>\n</html>\n\n")); 99 101 step04.setVerticalAlignment(SwingConstants.TOP); 100 102
Note:
See TracChangeset
for help on using the changeset viewer.