From 85cff1d192f6e066bd912f9a82d348d1f029e0af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alberts=20Muktup=C4=81vels?= Date: Sun, 9 Oct 2022 16:35:59 +0300 Subject: display: put windows from same client in tab list group Reuse existing meta_window_same_client function to check if windows are from same client/application. https://gitlab.gnome.org/GNOME/metacity/-/issues/26 --- src/core/display.c | 3 +++ src/core/window-private.h | 3 +++ src/core/window.c | 5 +---- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/core/display.c b/src/core/display.c index 48692357..eeccf325 100644 --- a/src/core/display.c +++ b/src/core/display.c @@ -4594,6 +4594,9 @@ in_tab_chain (MetaWindow *window, if (meta_window_same_application (window, focus_window)) return TRUE; + + if (meta_window_same_client (window, focus_window)) + return TRUE; } return FALSE; diff --git a/src/core/window-private.h b/src/core/window-private.h index 61d7e511..6a5fb649 100644 --- a/src/core/window-private.h +++ b/src/core/window-private.h @@ -633,6 +633,9 @@ void meta_window_get_current_tile_area (MetaWindow *window, gboolean meta_window_same_application (MetaWindow *window, MetaWindow *other_window); +gboolean meta_window_same_client (MetaWindow *window, + MetaWindow *other_window); + void meta_window_refresh_resize_popup (MetaWindow *window); void meta_window_free_delete_dialog (MetaWindow *window); diff --git a/src/core/window.c b/src/core/window.c index 80e56c37..cae796cb 100644 --- a/src/core/window.c +++ b/src/core/window.c @@ -77,9 +77,6 @@ static gboolean process_property_notify (MetaWindow *window, static void meta_window_show (MetaWindow *window); static void meta_window_hide (MetaWindow *window); -static gboolean meta_window_same_client (MetaWindow *window, - MetaWindow *other_window); - static void meta_window_save_rect (MetaWindow *window); static void save_user_window_placement (MetaWindow *window); static void force_save_user_window_placement (MetaWindow *window); @@ -8254,7 +8251,7 @@ meta_window_same_application (MetaWindow *window, * applications (which likely aren't setting the group properly * anyways), it may be desirable to check this as well. */ -static gboolean +gboolean meta_window_same_client (MetaWindow *window, MetaWindow *other_window) { -- cgit v1.2.1