rpms/eel2/devel eel-2.15.90-background-mtime.patch, NONE, 1.1 eel2.spec, 1.52, 1.53

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Fri Aug 4 17:07:03 UTC 2006


Author: mclasen

Update of /cvs/dist/rpms/eel2/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv5300

Modified Files:
	eel2.spec 
Added Files:
	eel-2.15.90-background-mtime.patch 
Log Message:
fix background setting from firefox


eel-2.15.90-background-mtime.patch:
 eel-background.c |   17 +++++++++++++++--
 1 files changed, 15 insertions(+), 2 deletions(-)

--- NEW FILE eel-2.15.90-background-mtime.patch ---
--- eel-2.15.90/eel/eel-background.c.mtime	2006-01-12 05:43:45.000000000 -0500
+++ eel-2.15.90/eel/eel-background.c	2006-08-04 12:49:39.000000000 -0400
@@ -125,6 +125,7 @@
 	gboolean constant_size;
 	
 	char *image_uri;
+	time_t image_mtime;
 	GdkPixbuf *image;
 	int image_width_unscaled;
 	int image_height_unscaled;
@@ -1545,10 +1546,21 @@
 				     gboolean emit_appearance_change,
 				     gboolean load_async)
 {
+        time_t mtime;
+        GnomeVFSFileInfo *info;
+
 	g_return_val_if_fail (EEL_IS_BACKGROUND (background), FALSE);
 
-	if (eel_strcmp (background->details->image_uri, image_uri) == 0) {
-		background->details->emit_after_load = emit_appearance_change;
+        mtime = background->details->image_mtime;
+        info = gnome_vfs_file_info_new ();
+        if (gnome_vfs_get_file_info (image_uri, info,
+                                     GNOME_VFS_FILE_INFO_FOLLOW_LINKS) == GNOME_VFS_OK) {
+                 mtime = info->mtime;
+        }
+        gnome_vfs_file_info_unref (info);
+	if (eel_strcmp (background->details->image_uri, image_uri) == 0 &&
+            mtime == background->details->image_mtime) {
+	   	background->details->emit_after_load = emit_appearance_change;
 		return FALSE;
 	}
 
@@ -1556,6 +1568,7 @@
 	
 	g_free (background->details->image_uri);
 	background->details->image_uri = g_strdup (image_uri);
+        background->details->image_mtime = mtime;
 
 	/* We do not get rid of the current image here. This gets done after the new
 	 * image loads - in eel_background_load_image_callback. This way the


Index: eel2.spec
===================================================================
RCS file: /cvs/dist/rpms/eel2/devel/eel2.spec,v
retrieving revision 1.52
retrieving revision 1.53
diff -u -r1.52 -r1.53
--- eel2.spec	3 Aug 2006 18:23:44 -0000	1.52
+++ eel2.spec	4 Aug 2006 17:07:01 -0000	1.53
@@ -16,10 +16,11 @@
 Name:		eel2
 Summary:        Eazel Extensions Library
 Version: 	2.15.90
-Release: 	1%{?dist}
+Release: 	2%{?dist}
 License: 	LGPL
 Group: System Environment/Libraries
 Source: 	eel-%{version}.tar.bz2
+Patch0:		eel-2.15.90-background-mtime.patch
 URL: 		http://www.gnome.org/projects/nautilus/
 BuildRoot:	/var/tmp/%{name}-%{version}-root
 
@@ -74,6 +75,7 @@
 
 %prep
 %setup -q -n eel-%{version}
+%patch0 -p1 -b .background-mtime
 
 %build
 %configure
@@ -109,6 +111,9 @@
 %{_includedir}/eel-2
 
 %changelog
+* Fri Aug  4 2006 Matthias Clasen <mclasen at redhat.com> - 2.15.90-2.fc6
+- Compare mtimes of images when the uri has not changed
+
 * Thu Aug  3 2006 Matthias Clasen <mclasen at redhat.com> - 2.15.90-1.fc6
 - Update to 2.15.90
 




More information about the fedora-cvs-commits mailing list