]> gitweb.fperrin.net Git - GpsPrune.git/blobdiff - tim/prune/undo/UndoCorrelatePhotos.java
Version 11, August 2010
[GpsPrune.git] / tim / prune / undo / UndoCorrelatePhotos.java
index 3c25837c81e107695035455930b2a5bfe5c39cb6..39c7a86468fcaffde516767591def878307b6c60 100644 (file)
@@ -60,10 +60,14 @@ public class UndoCorrelatePhotos implements UndoOperation
                for (int i=0; i<_photoPoints.length; i++)\r
                {\r
                        Photo photo = inTrackInfo.getPhotoList().getPhoto(i);\r
-                       DataPoint point = _photoPoints[i];\r
-                       photo.setDataPoint(point);\r
-                       if (point != null) {\r
-                               point.setPhoto(photo);\r
+                       // Only need to look at connected photos, if they're still tagged then leave them\r
+                       if (photo.getCurrentStatus() == Photo.Status.CONNECTED)\r
+                       {\r
+                               DataPoint point = _photoPoints[i];\r
+                               photo.setDataPoint(point);\r
+                               if (point != null) {\r
+                                       point.setPhoto(photo);\r
+                               }\r
                        }\r
                }\r
                // clear selection\r