gthumb r2207 - in trunk: . src



Author: mjc
Date: Mon Jan 21 00:01:40 2008
New Revision: 2207
URL: http://svn.gnome.org/viewvc/gthumb?rev=2207&view=rev

Log:
2008-01-20  Michael J. Chudobiak  <mjc svn gnome org>

        * src/catalog-png-exporter.c: (image_loader_done):
        * src/catalog-web-exporter.c: (gth_parsed_doc_print):
        * src/dlg-change-date.c: (exif_time_available), (ok_clicked):
        * src/dlg-rename-series.c: (get_image_date):
        * src/gth-browser.c: (window_update_statusbar_image_info):
        * src/gth-fullscreen.c: (get_file_info):
        * src/gth-viewer.c: (viewer_update_statusbar_image_info):
        Read exif_time from FileData, instead of from the file again.



Modified:
   trunk/ChangeLog
   trunk/src/catalog-png-exporter.c
   trunk/src/catalog-web-exporter.c
   trunk/src/dlg-change-date.c
   trunk/src/dlg-rename-series.c
   trunk/src/gth-browser.c
   trunk/src/gth-fullscreen.c
   trunk/src/gth-viewer.c

Modified: trunk/src/catalog-png-exporter.c
==============================================================================
--- trunk/src/catalog-png-exporter.c	(original)
+++ trunk/src/catalog-png-exporter.c	Mon Jan 21 00:01:40 2008
@@ -1451,7 +1451,8 @@
 
 	/* time in exif tag, if present */
 
-	idata->exif_time = get_metadata_time_from_fd (idata->file);
+	file_data_insert_metadata (idata->file);
+	idata->exif_time = idata->file->exif_time;
 
 	/* thumbnail. */
 	idata->thumb = pixbuf = image_loader_get_pixbuf (iloader);

Modified: trunk/src/catalog-web-exporter.c
==============================================================================
--- trunk/src/catalog-web-exporter.c	(original)
+++ trunk/src/catalog-web-exporter.c	Mon Jan 21 00:01:40 2008
@@ -1803,7 +1803,8 @@
 				struct tm *tp;
 				char s[100];
 
-				t = get_metadata_time_from_fd (idata->src_file);
+				file_data_insert_metadata (idata->src_file);
+				t = idata->src_file->exif_time;
 				if (t != 0) {
 					tp = localtime (&t);
 					strftime (s, 99, DATE_FORMAT, tp);

Modified: trunk/src/dlg-change-date.c
==============================================================================
--- trunk/src/dlg-change-date.c	(original)
+++ trunk/src/dlg-change-date.c	Mon Jan 21 00:01:40 2008
@@ -90,7 +90,9 @@
 
 	fd = data->file_list->data;
 
-	return get_metadata_time_from_fd (fd) != 0;
+	file_data_insert_metadata (fd);
+
+	return (fd->exif_time != 0);
 }
 
 
@@ -122,7 +124,8 @@
 			mtime = get_file_ctime (fdata->path);
 			comment_time = mtime;
 		} else if (is_active (data->cd_exif_radiobutton)) {
-			mtime = get_metadata_time_from_fd (fdata);
+			file_data_insert_metadata (fdata);
+			mtime = fdata->exif_time;
 			comment_time = mtime;
 		} else if (is_active (data->cd_adjust_timezone_radiobutton)) {
 			time_t tz;

Modified: trunk/src/dlg-rename-series.c
==============================================================================
--- trunk/src/dlg-rename-series.c	(original)
+++ trunk/src/dlg-rename-series.c	Mon Jan 21 00:01:40 2008
@@ -268,7 +268,8 @@
 	struct tm *ltime;
 	char      *stime;
 
-	mtime = get_metadata_time_from_fd (fd);
+	file_data_insert_metadata (fd);
+	mtime = fd->exif_time;
 
 	if (mtime == 0)
 		mtime = get_file_mtime (fd->path);

Modified: trunk/src/gth-browser.c
==============================================================================
--- trunk/src/gth-browser.c	(original)
+++ trunk/src/gth-browser.c	Mon Jan 21 00:01:40 2008
@@ -476,7 +476,9 @@
 		height = 0;
 	}
 
-	timer = get_metadata_time_from_fd (priv->image);
+	file_data_insert_metadata (priv->image);
+	timer = priv->image->exif_time;
+
 	if (timer == 0)
 		timer = priv->image->mtime;
 	tm = localtime (&timer);

Modified: trunk/src/gth-fullscreen.c
==============================================================================
--- trunk/src/gth-fullscreen.c	(original)
+++ trunk/src/gth-fullscreen.c	Mon Jan 21 00:01:40 2008
@@ -876,7 +876,10 @@
 
 	zoom = (int) (image_viewer->zoom_level * 100.0);
 
-	timer = get_metadata_time_from_fd (priv->current->data);
+	FileData *current_file = fullscreen->priv->current->data;
+	file_data_insert_metadata (current_file);
+	timer = current_file->exif_time;
+
 	if (timer == 0)
 		timer = get_file_mtime (image_filename);
 	tm = localtime (&timer);

Modified: trunk/src/gth-viewer.c
==============================================================================
--- trunk/src/gth-viewer.c	(original)
+++ trunk/src/gth-viewer.c	Mon Jan 21 00:01:40 2008
@@ -606,7 +606,9 @@
 		height = 0;
 	}
 
-	timer = get_metadata_time_from_fd (priv->image);
+	file_data_insert_metadata (priv->image);
+	timer = priv->image->exif_time;
+
 	if (timer == 0)
 		timer = priv->image->mtime;
 	tm = localtime (&timer);



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