[f-spot/icon-view-cleanup: 3/24] Rename Photo.Loaded for clarity.



commit 9591a0cfce48be318478bde7dad27bc14cc5c862
Author: Ruben Vermeersch <ruben savanne be>
Date:   Fri Aug 13 13:11:35 2010 +0200

    Rename Photo.Loaded for clarity.

 src/Clients/MainApp/FSpot/Photo.cs      |    8 ++++----
 src/Clients/MainApp/FSpot/PhotoStore.cs |   10 +++++-----
 2 files changed, 9 insertions(+), 9 deletions(-)
---
diff --git a/src/Clients/MainApp/FSpot/Photo.cs b/src/Clients/MainApp/FSpot/Photo.cs
index 37602d2..489d166 100644
--- a/src/Clients/MainApp/FSpot/Photo.cs
+++ b/src/Clients/MainApp/FSpot/Photo.cs
@@ -64,15 +64,15 @@ namespace FSpot
 			}
 		}
 
-		private bool loaded = false;
-		public bool Loaded {
-			get { return loaded; }
+		private bool all_versions_loaded = false;
+		internal bool AllVersionsLoaded {
+			get { return all_versions_loaded; }
 			set {
 				if (value) {
 					if (DefaultVersionId != OriginalVersionId && !versions.ContainsKey (DefaultVersionId))
 						DefaultVersionId = OriginalVersionId;
 				}
-				loaded = value;
+				all_versions_loaded = value;
 			}
 		}
 
diff --git a/src/Clients/MainApp/FSpot/PhotoStore.cs b/src/Clients/MainApp/FSpot/PhotoStore.cs
index ad88899..29539c3 100644
--- a/src/Clients/MainApp/FSpot/PhotoStore.cs
+++ b/src/Clients/MainApp/FSpot/PhotoStore.cs
@@ -178,7 +178,7 @@ public class PhotoStore : DbStore<Photo> {
 
 		photo = new Photo (id, unix_time);
 		photo.AddVersionUnsafely (Photo.OriginalVersionId, item.DefaultVersion.BaseUri, item.DefaultVersion.Filename, item.DefaultVersion.ImportMD5, Catalog.GetString ("Original"), true);
-		photo.Loaded = true;
+		photo.AllVersionsLoaded = true;
 
 		InsertVersion (photo, photo.DefaultVersion as PhotoVersion);
 		EmitAdded (photo);
@@ -247,7 +247,7 @@ public class PhotoStore : DbStore<Photo> {
 				continue;
 			}
 
-			if (photo.Loaded) {
+			if (photo.AllVersionsLoaded) {
 				//Console.WriteLine ("Photo {0} already Loaded", photo);
 				continue;
 			}
@@ -285,7 +285,7 @@ public class PhotoStore : DbStore<Photo> {
 				continue;
 			}
 
-			if (photo.Loaded) {
+			if (photo.AllVersionsLoaded) {
 				//Console.WriteLine ("Photo {0} already Loaded", photo.Id);
 				continue;
 			}
@@ -782,7 +782,7 @@ public class PhotoStore : DbStore<Photo> {
 		foreach (Photo photo in new_photos) {
 			AddToCache (photo);
 			photo_ids = photo_ids + Convert.ToString(photo.Id) + ",";
-			need_load |= !photo.Loaded;
+			need_load |= !photo.AllVersionsLoaded;
 		}
 
 		photo_ids = photo_ids + "-1)";
@@ -791,7 +791,7 @@ public class PhotoStore : DbStore<Photo> {
 			GetAllTags (photo_ids);
 			GetAllVersions (photo_ids);
 			foreach (Photo photo in new_photos)
-				photo.Loaded = true;
+				photo.AllVersionsLoaded = true;
 		} else {
 			//Console.WriteLine ("Skipped Loading Data");
 		}



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]