From ac051dbaaef911fccb004b21ed7a033043c4b6ae Mon Sep 17 00:00:00 2001
From: Matthew W. S. Bell <matthew@bells23.org.uk>
Date: Sat, 7 Aug 2010 00:33:06 +0100
Subject: [PATCH 3/4] Iterate over target collection, instead of larger collection and then
checking to see if each item is in the target collection.
---
.../openstreetmap/josm/gui/layer/OsmDataLayer.java | 6 ++----
1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/org/openstreetmap/josm/gui/layer/OsmDataLayer.java b/src/org/openstreetmap/josm/gui/layer/OsmDataLayer.java
index 0eef27b..e3465d2 100644
a
|
b
|
public class OsmDataLayer extends Layer implements Listener, SelectionChangedLis
|
397 | 397 | Main.main.undoRedo.clean(this); |
398 | 398 | |
399 | 399 | // if uploaded, clean the modified flags as well |
400 | | for (OsmPrimitive p: data.allPrimitives()) { |
401 | | if (processed.contains(p)) { |
402 | | p.setModified(false); |
403 | | } |
| 400 | for (OsmPrimitive p: processed) { |
| 401 | p.setModified(false); |
404 | 402 | } |
405 | 403 | data.cleanupDeletedPrimitives(); |
406 | 404 | } |