parent
4535d0a060
commit
a532391177
56
977.patch
Normal file
56
977.patch
Normal file
@ -0,0 +1,56 @@
|
|||||||
|
From 57b1d9b523c57a9ebf662f6da08cd26a3a22401a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Qiu Wenbo <qiuwenbo@kylinos.com.cn>
|
||||||
|
Date: Tue, 13 Sep 2022 17:03:37 +0800
|
||||||
|
Subject: [PATCH] Revert "thumbnails: Create larger thumbnails for higher
|
||||||
|
density displays"
|
||||||
|
|
||||||
|
This reverts commit 278435e3c20244b48986c6cd8b72c5317668c72d.
|
||||||
|
|
||||||
|
glib2 do not handle x-large and xx-large case so G_FILE_ATTRIBUTE_THUMBNAIL_PATH
|
||||||
|
simply return nothing. That makes nautilus think the thumbnail should be
|
||||||
|
generated again which is a dead loop.
|
||||||
|
---
|
||||||
|
src/nautilus-thumbnails.c | 27 +--------------------------
|
||||||
|
1 file changed, 1 insertion(+), 26 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/nautilus-thumbnails.c b/src/nautilus-thumbnails.c
|
||||||
|
index 790b4e36f..1bad311e1 100644
|
||||||
|
--- a/src/nautilus-thumbnails.c
|
||||||
|
+++ b/src/nautilus-thumbnails.c
|
||||||
|
@@ -137,32 +137,7 @@ get_thumbnail_factory (void)
|
||||||
|
|
||||||
|
if (thumbnail_factory == NULL)
|
||||||
|
{
|
||||||
|
- GdkDisplay *display = gdk_display_get_default ();
|
||||||
|
- GListModel *monitors = gdk_display_get_monitors (display);
|
||||||
|
- gint max_scale = 1;
|
||||||
|
- GnomeDesktopThumbnailSize size;
|
||||||
|
-
|
||||||
|
- for (guint i = 0; i < g_list_model_get_n_items (monitors); i++)
|
||||||
|
- {
|
||||||
|
- g_autoptr (GdkMonitor) monitor = g_list_model_get_item (monitors, i);
|
||||||
|
-
|
||||||
|
- max_scale = MAX (max_scale, gdk_monitor_get_scale_factor (monitor));
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
- if (max_scale <= 1)
|
||||||
|
- {
|
||||||
|
- size = GNOME_DESKTOP_THUMBNAIL_SIZE_LARGE;
|
||||||
|
- }
|
||||||
|
- else if (max_scale <= 2)
|
||||||
|
- {
|
||||||
|
- size = GNOME_DESKTOP_THUMBNAIL_SIZE_XLARGE;
|
||||||
|
- }
|
||||||
|
- else
|
||||||
|
- {
|
||||||
|
- size = GNOME_DESKTOP_THUMBNAIL_SIZE_XXLARGE;
|
||||||
|
- }
|
||||||
|
-
|
||||||
|
- thumbnail_factory = gnome_desktop_thumbnail_factory_new (size);
|
||||||
|
+ thumbnail_factory = gnome_desktop_thumbnail_factory_new (GNOME_DESKTOP_THUMBNAIL_SIZE_LARGE);
|
||||||
|
}
|
||||||
|
|
||||||
|
return thumbnail_factory;
|
||||||
|
--
|
||||||
|
GitLab
|
||||||
|
|
@ -7,12 +7,18 @@
|
|||||||
|
|
||||||
Name: nautilus
|
Name: nautilus
|
||||||
Version: 43.0
|
Version: 43.0
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
Summary: File manager for GNOME
|
Summary: File manager for GNOME
|
||||||
|
|
||||||
License: GPLv3+
|
License: GPLv3+
|
||||||
URL: https://wiki.gnome.org/Apps/Nautilus
|
URL: https://wiki.gnome.org/Apps/Nautilus
|
||||||
Source0: https://download.gnome.org/sources/%{name}/43/%{name}-%{tarball_version}.tar.xz
|
Source0: https://download.gnome.org/sources/%{name}/43/%{name}-%{tarball_version}.tar.xz
|
||||||
|
# https://gitlab.gnome.org/GNOME/nautilus/-/merge_requests/977
|
||||||
|
# https://bugzilla.redhat.com/show_bug.cgi?id=2127618
|
||||||
|
# https://gitlab.gnome.org/GNOME/nautilus/-/issues/2487
|
||||||
|
# Revert high-resolution thumbnail generation as it cannot work
|
||||||
|
# without fixes in glib
|
||||||
|
Patch0: 977.patch
|
||||||
|
|
||||||
BuildRequires: desktop-file-utils
|
BuildRequires: desktop-file-utils
|
||||||
BuildRequires: gcc
|
BuildRequires: gcc
|
||||||
@ -138,6 +144,9 @@ desktop-file-validate $RPM_BUILD_ROOT%{_datadir}/applications/*.desktop
|
|||||||
%doc %{_datadir}/doc/nautilus/
|
%doc %{_datadir}/doc/nautilus/
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Sep 30 2022 Adam Williamson <awilliam@redhat.com> - 43.0-2
|
||||||
|
- Backport MR #977 to revert broken high-res thumbnails (#2127618)
|
||||||
|
|
||||||
* Tue Sep 20 2022 Kalev Lember <klember@redhat.com> - 43.0-1
|
* Tue Sep 20 2022 Kalev Lember <klember@redhat.com> - 43.0-1
|
||||||
- Update to 43.0
|
- Update to 43.0
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user