summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatt Turner <mattst88@gentoo.org>2022-10-01 15:56:51 -0400
committerMatt Turner <mattst88@gentoo.org>2022-10-01 15:56:51 -0400
commit3daaead19dfe8d4f7c70d7c127c680087cc2ea5a (patch)
treeb2c6df00af2210993f18db81c7e8aec33f9bc644 /media-video/cheese/files
parentdev-python/nautilus-python: Version bump to 4.0 (diff)
downloadgentoo-3daaead19dfe8d4f7c70d7c127c680087cc2ea5a.tar.gz
gentoo-3daaead19dfe8d4f7c70d7c127c680087cc2ea5a.tar.bz2
gentoo-3daaead19dfe8d4f7c70d7c127c680087cc2ea5a.zip
media-video/cheese: Add patch to build against gnome-desktop-43
Closes: https://bugs.gentoo.org/873688 Signed-off-by: Matt Turner <mattst88@gentoo.org>
Diffstat (limited to 'media-video/cheese/files')
-rw-r--r--media-video/cheese/files/41.1-thumb-view-update-for-new-gnome-desktop-API.patch49
1 files changed, 49 insertions, 0 deletions
diff --git a/media-video/cheese/files/41.1-thumb-view-update-for-new-gnome-desktop-API.patch b/media-video/cheese/files/41.1-thumb-view-update-for-new-gnome-desktop-API.patch
new file mode 100644
index 000000000000..3796c721f892
--- /dev/null
+++ b/media-video/cheese/files/41.1-thumb-view-update-for-new-gnome-desktop-API.patch
@@ -0,0 +1,49 @@
+From d58071c56dc46299357c46da5ef9682d8d0abfa4 Mon Sep 17 00:00:00 2001
+From: Michael Catanzaro <mcatanzaro@redhat.com>
+Date: Mon, 11 Apr 2022 17:07:21 -0500
+Subject: [PATCH] thumb-view: update for new gnome-desktop API
+
+See gnome-desktop!132
+---
+ src/thumbview/cheese-thumb-view.c | 18 ++++++++++++++++++
+ 1 file changed, 18 insertions(+)
+
+diff --git a/src/thumbview/cheese-thumb-view.c b/src/thumbview/cheese-thumb-view.c
+index f01b33df..fce8687d 100644
+--- a/src/thumbview/cheese-thumb-view.c
++++ b/src/thumbview/cheese-thumb-view.c
+@@ -134,6 +134,23 @@ cheese_thumb_view_idle_append_item (gpointer data)
+
+ if (!thumb_loc)
+ {
++#if defined(GNOME_DESKTOP_PLATFORM_VERSION) && GNOME_DESKTOP_PLATFORM_VERSION >= 43
++ pixbuf = gnome_desktop_thumbnail_factory_generate_thumbnail (factory, uri, mime_type, NULL, &error);
++ if (!pixbuf)
++ {
++ g_warning ("could not generate thumbnail for %s (%s): %s\n", filename, mime_type, error->message);
++ g_clear_error (&error);
++ }
++ else
++ {
++ gnome_desktop_thumbnail_factory_save_thumbnail (factory, pixbuf, uri, mtime.tv_sec, NULL, &error);
++ if (error)
++ {
++ g_warning ("could not save thumbnail for %s (%s): %s\n", filename, mime_type, error->message);
++ g_clear_error (&error);
++ }
++ }
++#else
+ pixbuf = gnome_desktop_thumbnail_factory_generate_thumbnail (factory, uri, mime_type);
+ if (!pixbuf)
+ {
+@@ -143,6 +160,7 @@ cheese_thumb_view_idle_append_item (gpointer data)
+ {
+ gnome_desktop_thumbnail_factory_save_thumbnail (factory, pixbuf, uri, mtime.tv_sec);
+ }
++#endif
+ }
+ else
+ {
+--
+2.35.1
+