Changeset 8984 in josm for trunk/src/org
- Timestamp:
- 2015-11-03T00:39:05+01:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/PurgeAction.java
r8981 r8984 6 6 import java.awt.Component; 7 7 import java.awt.Dimension; 8 import java.awt.GraphicsEnvironment; 8 9 import java.awt.GridBagLayout; 9 10 import java.awt.Insets; … … 202 203 } 203 204 204 ExtendedDialog confirmDlg = new ExtendedDialog(Main.parent, tr("Confirm Purging"), new String[] {tr("Purge"), tr("Cancel")}); 205 confirmDlg.setContent(buildPanel(modified), false); 206 confirmDlg.setButtonIcons(new String[] {"ok", "cancel"}); 207 208 int answer = confirmDlg.showDialog().getValue(); 209 if (answer != 1) 210 return; 211 212 Main.pref.put("purge.clear_undo_redo", cbClearUndoRedo.isSelected()); 205 boolean clearUndoRedo = false; 206 207 if (!GraphicsEnvironment.isHeadless()) { 208 ExtendedDialog confirmDlg = new ExtendedDialog(Main.parent, tr("Confirm Purging"), 209 new String[] {tr("Purge"), tr("Cancel")}); 210 confirmDlg.setContent(buildPanel(modified), false); 211 confirmDlg.setButtonIcons(new String[] {"ok", "cancel"}); 212 213 int answer = confirmDlg.showDialog().getValue(); 214 if (answer != 1) 215 return; 216 217 clearUndoRedo = cbClearUndoRedo.isSelected(); 218 Main.pref.put("purge.clear_undo_redo", clearUndoRedo); 219 } 213 220 214 221 Main.main.undoRedo.add(new PurgeCommand(Main.main.getEditLayer(), toPurgeChecked, makeIncomplete)); 215 222 216 if (c bClearUndoRedo.isSelected()) {223 if (clearUndoRedo) { 217 224 Main.main.undoRedo.clean(); 218 225 getCurrentDataSet().clearSelectionHistory();
Note:
See TracChangeset
for help on using the changeset viewer.