Ignore:
Timestamp:
2010-07-03T22:08:57+02:00 (11 years ago)
Author:
stoecker
Message:

fix #5182 - Conflict system simplification - patch by Upliner

Location:
trunk/src/org/openstreetmap/josm/command
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/command/PurgePrimitivesCommand.java

    r3335 r3362  
    4040 *
    4141 */
     42@Deprecated
    4243public class PurgePrimitivesCommand extends ConflictResolveCommand{
    4344
  • trunk/src/org/openstreetmap/josm/command/UndeletePrimitivesCommand.java

    r3262 r3362  
    2626 *
    2727 */
     28@Deprecated
    2829public class UndeletePrimitivesCommand extends ConflictResolveCommand {
    2930    //static private final Logger logger = Logger.getLogger(UndeletePrimitivesCommand.class.getName());
  • trunk/src/org/openstreetmap/josm/command/VersionConflictResolveCommand.java

    r3262 r3362  
    5151        super.executeCommand();
    5252        if (!conflict.getMy().isNew()) {
     53            long myVersion = conflict.getMy().getVersion();
     54            long theirVersion = conflict.getTheir().getVersion();
    5355            conflict.getMy().setOsmId(
    5456                    conflict.getMy().getId(),
    55                     (int)Math.max(conflict.getMy().getVersion(), conflict.getTheir().getVersion())
     57                    (int)Math.max(myVersion, theirVersion)
    5658            );
     59            // update visiblity state
     60            if (theirVersion >= myVersion) {
     61                conflict.getMy().setVisible(conflict.getTheir().isVisible());
     62            }
    5763        }
    5864        getLayer().getConflicts().remove(conflict);
Note: See TracChangeset for help on using the changeset viewer.