From e292e83f942de32a67cff9fcee8fca8a98060826 Mon Sep 17 00:00:00 2001 From: yangchenguang Date: Tue, 16 Jan 2024 17:34:35 +0800 Subject: [PATCH] revert last commit not issue patch file Signed-off-by: yangchenguang (cherry picked from commit 90e50b7ada1edcb8363b0ce5bca25e58adb04e86) --- ...-definition-of-gtk-image-set-from-pi.patch | 67 ------------------- ...ays-send-the-monitors-changed-signal.patch | 30 --------- ...that-the-prompt-information-of-netwo.patch | 26 ------- ...screen-size-when-x11-screen-change-s.patch | 54 --------------- gtk3.spec | 9 ++- 5 files changed, 4 insertions(+), 182 deletions(-) delete mode 100644 fix-add-function-definition-of-gtk-image-set-from-pi.patch delete mode 100644 fix-gtk3-always-send-the-monitors-changed-signal.patch delete mode 100644 fix-the-problem-that-the-prompt-information-of-netwo.patch delete mode 100644 fix-update-the-xscreen-size-when-x11-screen-change-s.patch diff --git a/fix-add-function-definition-of-gtk-image-set-from-pi.patch b/fix-add-function-definition-of-gtk-image-set-from-pi.patch deleted file mode 100644 index 6596837..0000000 --- a/fix-add-function-definition-of-gtk-image-set-from-pi.patch +++ /dev/null @@ -1,67 +0,0 @@ -From 5bd8c8cfca3b435c0bf5eefb771f332fe6804c14 Mon Sep 17 00:00:00 2001 -From: yangchenguang -Date: Thu, 13 Apr 2023 11:13:03 +0800 -Subject: [PATCH 1/4] fix(*): add function definition of gtk image set from - pixbuf - -Signed-off-by: yangchenguang ---- - gtk/gtkimage.c | 26 ++++++++++++++++++++++++++ - gtk/gtkimage.h | 4 ++++ - 2 files changed, 30 insertions(+) - -diff --git a/gtk/gtkimage.c b/gtk/gtkimage.c -index 5d6e715..e84b821 100644 ---- a/gtk/gtkimage.c -+++ b/gtk/gtkimage.c -@@ -1120,6 +1120,32 @@ gtk_image_set_from_pixbuf (GtkImage *image, - g_object_thaw_notify (G_OBJECT (image)); - } - -+extern void -+gtk_image_set_from_pixbuf_with_scale (GtkImage *image, -+ GdkPixbuf *pixbuf, -+ int scale) -+{ -+ GtkImagePrivate *priv; -+ -+ g_return_if_fail (GTK_IS_IMAGE (image)); -+ g_return_if_fail (pixbuf == NULL || -+ GDK_IS_PIXBUF (pixbuf)); -+ -+ priv = image->priv; -+ -+ g_object_freeze_notify (G_OBJECT (image)); -+ -+ gtk_image_clear (image); -+ -+ if (pixbuf != NULL) -+ _gtk_icon_helper_set_pixbuf (priv->icon_helper, pixbuf); -+ -+ _gtk_icon_helper_set_pixbuf_scale (priv->icon_helper, scale); -+ g_object_notify_by_pspec (G_OBJECT (image), image_props[PROP_PIXBUF]); -+ -+ g_object_thaw_notify (G_OBJECT (image)); -+} -+ - /** - * gtk_image_set_from_stock: - * @image: a #GtkImage -diff --git a/gtk/gtkimage.h b/gtk/gtkimage.h -index 68b9a6d..b679bce 100644 ---- a/gtk/gtkimage.h -+++ b/gtk/gtkimage.h -@@ -144,6 +144,10 @@ GDK_AVAILABLE_IN_ALL - void gtk_image_set_from_resource (GtkImage *image, - const gchar *resource_path); - GDK_AVAILABLE_IN_ALL -+void gtk_image_set_from_pixbuf_with_scale (GtkImage *image, -+ GdkPixbuf *pixbuf, -+ int scale_factor); -+GDK_AVAILABLE_IN_ALL - void gtk_image_set_from_pixbuf (GtkImage *image, - GdkPixbuf *pixbuf); - GDK_DEPRECATED_IN_3_10_FOR(gtk_image_set_from_icon_name) --- -2.33.0 - diff --git a/fix-gtk3-always-send-the-monitors-changed-signal.patch b/fix-gtk3-always-send-the-monitors-changed-signal.patch deleted file mode 100644 index 7ad4ab7..0000000 --- a/fix-gtk3-always-send-the-monitors-changed-signal.patch +++ /dev/null @@ -1,30 +0,0 @@ -From 775ba324d5f0e5272d44bff55a585c5583e0e3ee Mon Sep 17 00:00:00 2001 -From: yangchenguang -Date: Thu, 13 Apr 2023 11:22:12 +0800 -Subject: [PATCH 3/4] fix(*): gtk3 always send the monitors changed signal - -Signed-off-by: yangchenguang ---- - gdk/x11/gdkscreen-x11.c | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) - -diff --git a/gdk/x11/gdkscreen-x11.c b/gdk/x11/gdkscreen-x11.c -index 6646ee4..72ee247 100644 ---- a/gdk/x11/gdkscreen-x11.c -+++ b/gdk/x11/gdkscreen-x11.c -@@ -1215,9 +1215,11 @@ _gdk_x11_screen_size_changed (GdkScreen *screen, - if (width != xscreen->width || - height != xscreen->height) - { -- process_monitors_change (screen); - g_signal_emit_by_name (screen, "size-changed"); - } -+ -+ //process monitors change at here, because monitors change and screen size change is not same -+ process_monitors_change (screen); - } - - void --- -2.33.0 - diff --git a/fix-the-problem-that-the-prompt-information-of-netwo.patch b/fix-the-problem-that-the-prompt-information-of-netwo.patch deleted file mode 100644 index 632ac83..0000000 --- a/fix-the-problem-that-the-prompt-information-of-netwo.patch +++ /dev/null @@ -1,26 +0,0 @@ -From d6c5b1e9965768ad009addebbf2e5e05de2b5a7d Mon Sep 17 00:00:00 2001 -From: yangchenguang -Date: Thu, 13 Apr 2023 11:23:25 +0800 -Subject: [PATCH 4/4] fix(*): the problem that the prompt information of netwo - -Signed-off-by: yangchenguang ---- - gtk/gtktooltip.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/gtk/gtktooltip.c b/gtk/gtktooltip.c -index 9917d93..6592dd1 100644 ---- a/gtk/gtktooltip.c -+++ b/gtk/gtktooltip.c -@@ -962,7 +962,7 @@ gtk_tooltip_position (GtkTooltip *tooltip, - &anchor_rect, - GDK_GRAVITY_SOUTH, - GDK_GRAVITY_NORTH, -- GDK_ANCHOR_FLIP_Y | GDK_ANCHOR_SLIDE_X, -+ GDK_ANCHOR_FLIP_Y | GDK_ANCHOR_SLIDE, - rect_anchor_dx, 0); - gtk_widget_show (GTK_WIDGET (tooltip->current_window)); - } --- -2.33.0 - diff --git a/fix-update-the-xscreen-size-when-x11-screen-change-s.patch b/fix-update-the-xscreen-size-when-x11-screen-change-s.patch deleted file mode 100644 index 5501594..0000000 --- a/fix-update-the-xscreen-size-when-x11-screen-change-s.patch +++ /dev/null @@ -1,54 +0,0 @@ -From 6c2165171ecef153db63b17bcd8ec4a20e866c91 Mon Sep 17 00:00:00 2001 -From: yangchenguang -Date: Thu, 13 Apr 2023 11:19:01 +0800 -Subject: [PATCH 2/4] fix(*): update the xscreen size when x11 screen change - size - -Signed-off-by: yangchenguang ---- - gdk/x11/gdkscreen-x11.c | 13 ++++++++----- - 1 file changed, 8 insertions(+), 5 deletions(-) - -diff --git a/gdk/x11/gdkscreen-x11.c b/gdk/x11/gdkscreen-x11.c -index bb4df05..6646ee4 100644 ---- a/gdk/x11/gdkscreen-x11.c -+++ b/gdk/x11/gdkscreen-x11.c -@@ -1186,9 +1186,10 @@ _gdk_x11_screen_size_changed (GdkScreen *screen, - #ifdef HAVE_RANDR - GdkX11Display *display_x11; - #endif -+ Screen *xscreen = gdk_x11_screen_get_xscreen (screen); - -- width = gdk_x11_screen_get_width (screen); -- height = gdk_x11_screen_get_height (screen); -+ width = xscreen->width; -+ height = xscreen->height; - - #ifdef HAVE_RANDR - display_x11 = GDK_X11_DISPLAY (gdk_screen_get_display (screen)); -@@ -1201,7 +1202,6 @@ _gdk_x11_screen_size_changed (GdkScreen *screen, - if (event->type == ConfigureNotify) - { - XConfigureEvent *rcevent = (XConfigureEvent *) event; -- Screen *xscreen = gdk_x11_screen_get_xscreen (screen); - - xscreen->width = rcevent->width; - xscreen->height = rcevent->height; -@@ -1212,9 +1212,12 @@ _gdk_x11_screen_size_changed (GdkScreen *screen, - - process_monitors_change (screen); - -- if (width != gdk_x11_screen_get_width (screen) || -- height != gdk_x11_screen_get_height (screen)) -+ if (width != xscreen->width || -+ height != xscreen->height) -+ { -+ process_monitors_change (screen); - g_signal_emit_by_name (screen, "size-changed"); -+ } - } - - void --- -2.33.0 - diff --git a/gtk3.spec b/gtk3.spec index 58d257b..65f3629 100644 --- a/gtk3.spec +++ b/gtk3.spec @@ -14,7 +14,7 @@ #Basic Information Name: gtk3 Version: 3.24.30 -Release: 8 +Release: 9 Summary: GTK+ graphical user interface library License: LGPLv2+ URL: http://www.gtk.org @@ -23,10 +23,6 @@ Source0: http://download.gnome.org/sources/gtk+/3.24/gtk+-%{version}.tar.xz Patch6000: remove-missing-reftests-when-use-meson-build-system.patch Patch6001: do-not-install-reftests-when-use-meson-build-system.patch Patch9000: delete-taboo-words.patch -Patch6002: fix-add-function-definition-of-gtk-image-set-from-pi.patch -Patch6003: fix-update-the-xscreen-size-when-x11-screen-change-s.patch -Patch6004: fix-gtk3-always-send-the-monitors-changed-signal.patch -Patch6005: fix-the-problem-that-the-prompt-information-of-netwo.patch #Dependency BuildRequires: pkgconfig(atk) >= %{atk_version} pkgconfig(atk-bridge-2.0) @@ -271,6 +267,9 @@ gtk-query-immodules-3.0-64 --update-cache &>/dev/null || : %{_mandir}/man1/gtk3-widget-factory.1* %changelog +* Tue Jan 16 2024 yangchenguang - 3.24.30-9 +- revert last commit not issue patch file + * Mon Aug 21 2023 yangchenguang - 3.24.30-8 - Fix the problem that the prompt information of network icon volume icon is not displayed - update xscreen size when x11 screen size change -- Gitee