Ignore:
Timestamp:
2009-02-14T12:25:54+01:00 (17 years ago)
Author:
stoecker
Message:

apply patches from xeen for #1977.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/actions/SaveActionBase.java

    r1373 r1397  
    1717import org.openstreetmap.josm.Main;
    1818import org.openstreetmap.josm.data.osm.OsmPrimitive;
     19import org.openstreetmap.josm.gui.ExtendedDialog;
    1920import org.openstreetmap.josm.gui.layer.OsmDataLayer;
    2021import org.openstreetmap.josm.gui.layer.Layer;
     
    7879        }
    7980
    80         if (layer instanceof OsmDataLayer && isDataSetEmpty((OsmDataLayer)layer) && JOptionPane.NO_OPTION == JOptionPane.showConfirmDialog(Main.parent,tr("The document contains no data. Save anyway?"), tr("Empty document"), JOptionPane.YES_NO_OPTION)) {
     81        if (layer instanceof OsmDataLayer && isDataSetEmpty((OsmDataLayer)layer) && 1 != new ExtendedDialog(Main.parent, tr("Empty document"), tr("The document contains no data."), new String[] {tr("Save anyway"), tr("Cancel")}, new String[] {"save.png", "cancel.png"}).getValue()) {
    8182            return false;
    8283        }
     
    8586        }
    8687        if (!Main.map.conflictDialog.conflicts.isEmpty()) {
    87             int answer = JOptionPane.showConfirmDialog(Main.parent,
    88                     tr("There are unresolved conflicts. Conflicts will not be saved and handled as if you rejected all. Continue?"),tr("Conflicts"), JOptionPane.YES_NO_OPTION);
    89             if (answer != JOptionPane.YES_OPTION)
    90                 return false;
     88            int answer = new ExtendedDialog(Main.parent,
     89                tr("Conflicts"),
     90                tr("There are unresolved conflicts. Conflicts will not be saved and handled as if you rejected all. Continue?"),
     91                new String[] {tr("Reject Conflicts and Save"), tr("Cancel")},
     92                new String[] {"save.png", "cancel.png"}).getValue();
     93
     94            if (answer != 1) return false;
    9195        }
    9296        return true;
Note: See TracChangeset for help on using the changeset viewer.