Changeset 12605 in josm


Ignore:
Timestamp:
2017-08-15T00:41:24+02:00 (2 months ago)
Author:
Don-vip
Message:

fix a major performance problem when purging a large number of selected primitives, where a selection event was trigerred for each primitive

File:
1 edited

Legend:

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

    r11240 r12605  
    101101        try {
    102102            purgedConflicts.get().clear();
    103             /**
    104              * Loop from back to front to keep referential integrity.
    105              */
     103            // unselect primitives in advance to not fire a selection change for every one of them
     104            getAffectedDataSet().clearSelection(toPurge);
     105            // Loop from back to front to keep referential integrity.
    106106            for (int i = toPurge.size()-1; i >= 0; --i) {
    107107                OsmPrimitive osm = toPurge.get(i);
Note: See TracChangeset for help on using the changeset viewer.