Rebase to 47.alpha
Resolves: https://issues.redhat.com/browse/RHEL-49582
This commit is contained in:
parent
3beab53de1
commit
ba92f2566b
1
.gitignore
vendored
1
.gitignore
vendored
@ -221,3 +221,4 @@ mutter-2.31.5.tar.bz2
|
||||
/mutter-46.0.tar.xz
|
||||
/mutter-46.1.tar.xz
|
||||
/mutter-46.3.tar.xz
|
||||
/mutter-47.alpha.tar.xz
|
||||
|
@ -1,230 +0,0 @@
|
||||
From caca4ecbc4657998b4f9f3192afbd234f336402c Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Sun, 26 May 2024 00:43:37 +0200
|
||||
Subject: [PATCH 1/3] Revert "x11/window: Compare input shape to client rect
|
||||
when undecorating"
|
||||
|
||||
This reverts commit d8af06fe4993227c5059971effbe28527cd75412.
|
||||
---
|
||||
src/x11/window-x11.c | 16 +++++++++-------
|
||||
1 file changed, 9 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index df5f955877..925c7549b7 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2400,7 +2400,6 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
g_autoptr (MtkRegion) region = NULL;
|
||||
MetaWindowX11 *window_x11 = META_WINDOW_X11 (window);
|
||||
MetaWindowX11Private *priv = meta_window_x11_get_instance_private (window_x11);
|
||||
- MtkRectangle bounding_rect = { 0 };
|
||||
Window xwindow;
|
||||
|
||||
if (window->decorated)
|
||||
@@ -2412,14 +2411,10 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
return;
|
||||
}
|
||||
xwindow = window->frame->xwindow;
|
||||
- bounding_rect.width = window->buffer_rect.width;
|
||||
- bounding_rect.height = window->buffer_rect.height;
|
||||
}
|
||||
else
|
||||
{
|
||||
xwindow = priv->xwindow;
|
||||
- bounding_rect.width = priv->client_rect.width;
|
||||
- bounding_rect.height = priv->client_rect.height;
|
||||
}
|
||||
|
||||
if (META_X11_DISPLAY_HAS_SHAPE (x11_display))
|
||||
@@ -2463,8 +2458,8 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
else if (n_rects == 1 &&
|
||||
(rects[0].x == 0 &&
|
||||
rects[0].y == 0 &&
|
||||
- rects[0].width == bounding_rect.width &&
|
||||
- rects[0].height == bounding_rect.height))
|
||||
+ rects[0].width == window->buffer_rect.width &&
|
||||
+ rects[0].height == window->buffer_rect.height))
|
||||
{
|
||||
/* This is the bounding region case. Keep the
|
||||
* region as NULL. */
|
||||
@@ -2481,6 +2476,13 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
|
||||
if (region != NULL)
|
||||
{
|
||||
+ MtkRectangle bounding_rect;
|
||||
+
|
||||
+ bounding_rect.x = 0;
|
||||
+ bounding_rect.y = 0;
|
||||
+ bounding_rect.width = window->buffer_rect.width;
|
||||
+ bounding_rect.height = window->buffer_rect.height;
|
||||
+
|
||||
/* The shape we get back from the client may have coordinates
|
||||
* outside of the frame. The X SHAPE Extension requires that
|
||||
* the overall shape the client provides never exceeds the
|
||||
--
|
||||
2.45.2
|
||||
|
||||
|
||||
From 2b7161220cb95a1d531ef0cf8a8af911039cf194 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Sun, 21 Apr 2024 16:54:52 +0200
|
||||
Subject: [PATCH 2/3] Revert "x11/window: Update comment and variable name to
|
||||
reflect current behavior"
|
||||
|
||||
This reverts commit e4763d00e8512aeb408ae118597d753f12217487.
|
||||
---
|
||||
src/x11/window-x11.c | 15 ++++++++-------
|
||||
1 file changed, 8 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index 925c7549b7..7f2c0a3fd2 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2476,20 +2476,21 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
|
||||
if (region != NULL)
|
||||
{
|
||||
- MtkRectangle bounding_rect;
|
||||
+ MtkRectangle client_area;
|
||||
|
||||
- bounding_rect.x = 0;
|
||||
- bounding_rect.y = 0;
|
||||
- bounding_rect.width = window->buffer_rect.width;
|
||||
- bounding_rect.height = window->buffer_rect.height;
|
||||
+ client_area.x = 0;
|
||||
+ client_area.y = 0;
|
||||
+ client_area.width = window->buffer_rect.width;
|
||||
+ client_area.height = window->buffer_rect.height;
|
||||
|
||||
/* The shape we get back from the client may have coordinates
|
||||
* outside of the frame. The X SHAPE Extension requires that
|
||||
* the overall shape the client provides never exceeds the
|
||||
* "bounding rectangle" of the window -- the shape that the
|
||||
- * window would have gotten if it was unshaped.
|
||||
+ * window would have gotten if it was unshaped. In our case,
|
||||
+ * this is simply the client area.
|
||||
*/
|
||||
- mtk_region_intersect_rectangle (region, &bounding_rect);
|
||||
+ mtk_region_intersect_rectangle (region, &client_area);
|
||||
}
|
||||
|
||||
meta_window_set_input_region (window, region);
|
||||
--
|
||||
2.45.2
|
||||
|
||||
|
||||
From 256a879b7e230e8e9826be6e0df69feb31cbdd52 Mon Sep 17 00:00:00 2001
|
||||
From: Adam Williamson <awilliam@redhat.com>
|
||||
Date: Thu, 5 Oct 2023 13:09:46 -0700
|
||||
Subject: [PATCH 3/3] Revert "x11: Use input region from frame window for
|
||||
decorated windows"
|
||||
|
||||
This reverts commit d991961ae2a5c8cf2e58ff1072239f4902b0f767. It
|
||||
seems to cause the broken mouse interaction bug reported in
|
||||
https://bugzilla.redhat.com/show_bug.cgi?id=2239128 .
|
||||
|
||||
Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/3068
|
||||
---
|
||||
src/core/frame.c | 7 -------
|
||||
src/x11/window-x11.c | 29 ++++++++++-------------------
|
||||
2 files changed, 10 insertions(+), 26 deletions(-)
|
||||
|
||||
diff --git a/src/core/frame.c b/src/core/frame.c
|
||||
index 7a09f89f14..df489e441c 100644
|
||||
--- a/src/core/frame.c
|
||||
+++ b/src/core/frame.c
|
||||
@@ -36,7 +36,6 @@
|
||||
|
||||
#include <X11/Xatom.h>
|
||||
#include <X11/Xlib.h>
|
||||
-#include <X11/extensions/shape.h>
|
||||
|
||||
#define EVENT_MASK (SubstructureRedirectMask | \
|
||||
StructureNotifyMask | SubstructureNotifyMask | \
|
||||
@@ -118,9 +117,6 @@ meta_window_x11_set_frame_xwindow (MetaWindow *window,
|
||||
XChangeWindowAttributes (x11_display->xdisplay,
|
||||
frame->xwindow, CWEventMask, &attrs);
|
||||
|
||||
- if (META_X11_DISPLAY_HAS_SHAPE (x11_display))
|
||||
- XShapeSelectInput (x11_display->xdisplay, frame->xwindow, ShapeNotifyMask);
|
||||
-
|
||||
if (mtk_x11_error_trap_pop_with_return (x11_display->xdisplay))
|
||||
{
|
||||
meta_topic (META_DEBUG_WINDOW_STATE,
|
||||
@@ -254,9 +250,6 @@ meta_window_destroy_frame (MetaWindow *window)
|
||||
window->reparents_pending += 1;
|
||||
}
|
||||
|
||||
- if (META_X11_DISPLAY_HAS_SHAPE (x11_display))
|
||||
- XShapeSelectInput (x11_display->xdisplay, frame->xwindow, NoEventMask);
|
||||
-
|
||||
XDeleteProperty (x11_display->xdisplay,
|
||||
meta_window_x11_get_xwindow (window),
|
||||
x11_display->atom__MUTTER_NEEDS_FRAME);
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index 7f2c0a3fd2..ace1f8f5bc 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2082,10 +2082,6 @@ meta_window_x11_constructed (GObject *object)
|
||||
priv->keys_grabbed = FALSE;
|
||||
priv->grab_on_frame = FALSE;
|
||||
|
||||
- g_signal_connect (window, "notify::decorated",
|
||||
- G_CALLBACK (meta_window_x11_update_input_region),
|
||||
- window);
|
||||
-
|
||||
G_OBJECT_CLASS (meta_window_x11_parent_class)->constructed (object);
|
||||
}
|
||||
|
||||
@@ -2400,21 +2396,16 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
g_autoptr (MtkRegion) region = NULL;
|
||||
MetaWindowX11 *window_x11 = META_WINDOW_X11 (window);
|
||||
MetaWindowX11Private *priv = meta_window_x11_get_instance_private (window_x11);
|
||||
- Window xwindow;
|
||||
|
||||
+ /* Decorated windows don't have an input region, because
|
||||
+ we don't shape the frame to match the client windows
|
||||
+ (so the events are blocked by the frame anyway)
|
||||
+ */
|
||||
if (window->decorated)
|
||||
{
|
||||
- if (!window->frame)
|
||||
- {
|
||||
- if (priv->input_region)
|
||||
- meta_window_set_input_region (window, NULL);
|
||||
- return;
|
||||
- }
|
||||
- xwindow = window->frame->xwindow;
|
||||
- }
|
||||
- else
|
||||
- {
|
||||
- xwindow = priv->xwindow;
|
||||
+ if (priv->input_region)
|
||||
+ meta_window_set_input_region (window, NULL);
|
||||
+ return;
|
||||
}
|
||||
|
||||
if (META_X11_DISPLAY_HAS_SHAPE (x11_display))
|
||||
@@ -2426,7 +2417,7 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
|
||||
mtk_x11_error_trap_push (x11_display->xdisplay);
|
||||
rects = XShapeGetRectangles (x11_display->xdisplay,
|
||||
- xwindow,
|
||||
+ priv->xwindow,
|
||||
ShapeInput,
|
||||
&n_rects,
|
||||
&ordering);
|
||||
@@ -2480,8 +2471,8 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
|
||||
client_area.x = 0;
|
||||
client_area.y = 0;
|
||||
- client_area.width = window->buffer_rect.width;
|
||||
- client_area.height = window->buffer_rect.height;
|
||||
+ client_area.width = priv->client_rect.width;
|
||||
+ client_area.height = priv->client_rect.height;
|
||||
|
||||
/* The shape we get back from the client may have coordinates
|
||||
* outside of the frame. The X SHAPE Extension requires that
|
||||
--
|
||||
2.45.2
|
||||
|
@ -0,0 +1,66 @@
|
||||
From beff8f13ed0cf16fa0b22f69de75f83e0378fdf1 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Mon, 22 Jul 2024 12:37:01 +0200
|
||||
Subject: [PATCH 1/3] Revert "x11/window: Compare input shape to client rect
|
||||
when undecorating"
|
||||
|
||||
This reverts commit 1f1538be764ec5018b29d31c4486c0649a4e5068.
|
||||
---
|
||||
src/x11/window-x11.c | 16 +++++++++-------
|
||||
1 file changed, 9 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index adf5075a9b..e7c76dd674 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2415,7 +2415,6 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
g_autoptr (MtkRegion) region = NULL;
|
||||
MetaWindowX11 *window_x11 = META_WINDOW_X11 (window);
|
||||
MetaWindowX11Private *priv = meta_window_x11_get_instance_private (window_x11);
|
||||
- MtkRectangle bounding_rect = { 0 };
|
||||
Window xwindow;
|
||||
|
||||
if (window->decorated)
|
||||
@@ -2427,14 +2426,10 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
return;
|
||||
}
|
||||
xwindow = priv->frame->xwindow;
|
||||
- bounding_rect.width = window->buffer_rect.width;
|
||||
- bounding_rect.height = window->buffer_rect.height;
|
||||
}
|
||||
else
|
||||
{
|
||||
xwindow = priv->xwindow;
|
||||
- bounding_rect.width = priv->client_rect.width;
|
||||
- bounding_rect.height = priv->client_rect.height;
|
||||
}
|
||||
|
||||
if (META_X11_DISPLAY_HAS_SHAPE (x11_display))
|
||||
@@ -2478,8 +2473,8 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
else if (n_rects == 1 &&
|
||||
(rects[0].x == 0 &&
|
||||
rects[0].y == 0 &&
|
||||
- rects[0].width == bounding_rect.width &&
|
||||
- rects[0].height == bounding_rect.height))
|
||||
+ rects[0].width == window->buffer_rect.width &&
|
||||
+ rects[0].height == window->buffer_rect.height))
|
||||
{
|
||||
/* This is the bounding region case. Keep the
|
||||
* region as NULL. */
|
||||
@@ -2496,6 +2491,13 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
|
||||
if (region != NULL)
|
||||
{
|
||||
+ MtkRectangle bounding_rect;
|
||||
+
|
||||
+ bounding_rect.x = 0;
|
||||
+ bounding_rect.y = 0;
|
||||
+ bounding_rect.width = window->buffer_rect.width;
|
||||
+ bounding_rect.height = window->buffer_rect.height;
|
||||
+
|
||||
/* The shape we get back from the client may have coordinates
|
||||
* outside of the frame. The X SHAPE Extension requires that
|
||||
* the overall shape the client provides never exceeds the
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
35
0001-Test-deny-atomic-KMS-for-tegra-RHBZ-1936991.patch
Normal file
35
0001-Test-deny-atomic-KMS-for-tegra-RHBZ-1936991.patch
Normal file
@ -0,0 +1,35 @@
|
||||
From c0fda823b3f0c6802afe549379135719f86c6bfc Mon Sep 17 00:00:00 2001
|
||||
From: Adam Williamson <awilliam@redhat.com>
|
||||
Date: Tue, 9 Mar 2021 17:21:59 -0800
|
||||
Subject: [PATCH] Test: deny atomic KMS for "tegra" (RHBZ #1936991)
|
||||
|
||||
Signed-off-by: Adam Williamson <awilliam@redhat.com>
|
||||
---
|
||||
data/61-mutter.rules | 1 +
|
||||
src/backends/native/meta-kms-impl-device-atomic.c | 1 +
|
||||
2 files changed, 2 insertions(+)
|
||||
|
||||
diff --git a/data/61-mutter.rules b/data/61-mutter.rules
|
||||
index 9262b152b9..24f9655b69 100644
|
||||
--- a/data/61-mutter.rules
|
||||
+++ b/data/61-mutter.rules
|
||||
@@ -114,3 +114,4 @@ DRIVERS=="i915", SUBSYSTEM=="drm", ATTRS{vendor}=="0x8086", ATTRS{device}=="0x9b
|
||||
DRIVERS=="i915", SUBSYSTEM=="drm", ATTRS{vendor}=="0x8086", ATTRS{device}=="0x9be6", TAG+="mutter-device-disable-kms-modifiers"
|
||||
DRIVERS=="i915", SUBSYSTEM=="drm", ATTRS{vendor}=="0x8086", ATTRS{device}=="0x9bf6", TAG+="mutter-device-disable-kms-modifiers"
|
||||
ENV{ID_PATH}=="platform-vkms", TAG+="mutter-device-ignore"
|
||||
+DRIVER=="tegra", SUBSYSTEM=="platform", TAG+="mutter-device-disable-atomic-kms"
|
||||
diff --git a/src/backends/native/meta-kms-impl-device-atomic.c b/src/backends/native/meta-kms-impl-device-atomic.c
|
||||
index a4ffd70b6a..9fac299e14 100644
|
||||
--- a/src/backends/native/meta-kms-impl-device-atomic.c
|
||||
+++ b/src/backends/native/meta-kms-impl-device-atomic.c
|
||||
@@ -1306,6 +1306,7 @@ requires_hotspots (const char *driver_name)
|
||||
"vboxvideo",
|
||||
"virtio_gpu",
|
||||
"vmwgfx",
|
||||
+ "tegra",
|
||||
NULL,
|
||||
};
|
||||
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 692546a9701a7b363e6190af441a95385c244907 Mon Sep 17 00:00:00 2001
|
||||
From cbe6fb86ce1e71c7360974a960db6bf79eb1ebde Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 2 Dec 2022 22:49:41 +0100
|
||||
Subject: [PATCH] place: Always center initial-setup/fedora-welcome
|
||||
@ -8,10 +8,10 @@ Subject: [PATCH] place: Always center initial-setup/fedora-welcome
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/src/core/place.c b/src/core/place.c
|
||||
index f9877dfc7..a69a3ebd1 100644
|
||||
index 8a06ccb667..f34ae7f43d 100644
|
||||
--- a/src/core/place.c
|
||||
+++ b/src/core/place.c
|
||||
@@ -321,6 +321,11 @@ window_place_centered (MetaWindow *window)
|
||||
@@ -377,6 +377,11 @@ window_place_centered (MetaWindow *window)
|
||||
|
||||
type = window->type;
|
||||
|
||||
@ -24,5 +24,5 @@ index f9877dfc7..a69a3ebd1 100644
|
||||
type == META_WINDOW_MODAL_DIALOG ||
|
||||
type == META_WINDOW_SPLASHSCREEN ||
|
||||
--
|
||||
2.39.2
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
From b3b5aa01c63aee1df079e0394b0e6372df1838d0 Mon Sep 17 00:00:00 2001
|
||||
From 51e378c8f28b96b94c8da338b1b0f26cbc32c7f0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 12 May 2017 13:40:31 +0200
|
||||
Subject: [PATCH] window-actor: Special-case shaped Java windows
|
||||
@ -9,62 +9,27 @@ but now their compliance tests are broken. Make them happy again
|
||||
by special-casing shaped Java windows.
|
||||
---
|
||||
src/compositor/meta-window-actor-x11.c | 8 ++++++++
|
||||
src/x11/window-x11-private.h | 2 ++
|
||||
src/x11/window-x11.c | 9 +++++++++
|
||||
3 files changed, 19 insertions(+)
|
||||
1 file changed, 8 insertions(+)
|
||||
|
||||
diff --git a/src/compositor/meta-window-actor-x11.c b/src/compositor/meta-window-actor-x11.c
|
||||
index 19827af331..7d5e46ac75 100644
|
||||
index 2781df09cc..8748f3aa3a 100644
|
||||
--- a/src/compositor/meta-window-actor-x11.c
|
||||
+++ b/src/compositor/meta-window-actor-x11.c
|
||||
@@ -424,6 +424,14 @@ has_shadow (MetaWindowActorX11 *actor_x11)
|
||||
*/
|
||||
if (window->has_custom_frame_extents)
|
||||
@@ -431,6 +431,14 @@ has_shadow (MetaWindowActorX11 *actor_x11)
|
||||
if (priv->has_custom_frame_extents)
|
||||
return FALSE;
|
||||
+
|
||||
|
||||
+ /*
|
||||
+ * OpenJDK wrongly assumes that shaping a window implies no compositor
|
||||
+ * shadows; make its compliance tests happy to give it what it wants ...
|
||||
+ */
|
||||
+ if (g_strcmp0 (window->res_name, "sun-awt-X11-XWindowPeer") == 0 &&
|
||||
+ meta_window_x11_is_shaped (window))
|
||||
+ priv->shape_region != NULL)
|
||||
+ return FALSE;
|
||||
|
||||
+
|
||||
/*
|
||||
* Generate shadows for all other windows.
|
||||
diff --git a/src/x11/window-x11-private.h b/src/x11/window-x11-private.h
|
||||
index c947744ee5..cb862f0d72 100644
|
||||
--- a/src/x11/window-x11-private.h
|
||||
+++ b/src/x11/window-x11-private.h
|
||||
@@ -125,6 +125,8 @@ gboolean meta_window_x11_has_pointer (MetaWindow *window);
|
||||
gboolean meta_window_x11_same_application (MetaWindow *window,
|
||||
MetaWindow *other_window);
|
||||
|
||||
+gboolean meta_window_x11_is_shaped (MetaWindow *window);
|
||||
+
|
||||
void meta_window_x11_shutdown_group (MetaWindow *window);
|
||||
|
||||
META_EXPORT
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index 745c45db18..83cdd2e420 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2585,6 +2585,15 @@ meta_window_x11_update_shape_region (MetaWindow *window)
|
||||
meta_window_set_shape_region (window, region);
|
||||
}
|
||||
|
||||
+gboolean
|
||||
+meta_window_x11_is_shaped (MetaWindow *window)
|
||||
+{
|
||||
+ MetaWindowX11 *window_x11 = META_WINDOW_X11 (window);
|
||||
+ MetaWindowX11Private *priv = meta_window_x11_get_instance_private (window_x11);
|
||||
+
|
||||
+ return priv->shape_region != NULL;
|
||||
+}
|
||||
+
|
||||
/* Generally meta_window_x11_same_application() is a better idea
|
||||
* of "sameness", since it handles the case where multiple apps
|
||||
* want to look like the same app or the same app wants to look
|
||||
*/
|
||||
--
|
||||
2.43.2
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
||||
|
@ -0,0 +1,62 @@
|
||||
From d1be108c729331aa169a2a0397925c7b17507857 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Fri, 20 Oct 2023 15:44:29 +0800
|
||||
Subject: [PATCH 1/4] x11-display: Make subwindow redirection call mode
|
||||
specific
|
||||
|
||||
This means that for X11 sessions we'll do it before any windows are
|
||||
mapped, and before any plugin implementation is started. Doing it before
|
||||
a plugin is started is important, because things that the plugin does
|
||||
during startup can have consequences on how compositing on Xorg works.
|
||||
|
||||
For the Xwayland case, we'll do it relatively in the setup phase. It
|
||||
appears to have been harmless to do it later in the post-opened signal,
|
||||
but there is no harm in doing it as one of the earlier steps.
|
||||
|
||||
Closes: https://gitlab.gnome.org/GNOME/mutter/-/issues/3089
|
||||
---
|
||||
src/compositor/meta-compositor-x11.c | 2 ++
|
||||
src/wayland/meta-xwayland.c | 1 +
|
||||
src/x11/meta-x11-display.c | 1 -
|
||||
3 files changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/compositor/meta-compositor-x11.c b/src/compositor/meta-compositor-x11.c
|
||||
index cbc48bcefc..760d6fdddc 100644
|
||||
--- a/src/compositor/meta-compositor-x11.c
|
||||
+++ b/src/compositor/meta-compositor-x11.c
|
||||
@@ -188,6 +188,8 @@ meta_compositor_x11_manage (MetaCompositor *compositor,
|
||||
|
||||
compositor_x11->have_x11_sync_object = meta_sync_ring_init (xdisplay);
|
||||
|
||||
+ meta_x11_display_redirect_windows (x11_display, display);
|
||||
+
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
diff --git a/src/wayland/meta-xwayland.c b/src/wayland/meta-xwayland.c
|
||||
index 3366f11adc..db0a4a271a 100644
|
||||
--- a/src/wayland/meta-xwayland.c
|
||||
+++ b/src/wayland/meta-xwayland.c
|
||||
@@ -1179,6 +1179,7 @@ on_x11_display_setup (MetaDisplay *display,
|
||||
{
|
||||
MetaX11Display *x11_display = meta_display_get_x11_display (display);
|
||||
|
||||
+ meta_x11_display_redirect_windows (x11_display, display);
|
||||
meta_xwayland_init_dnd (x11_display);
|
||||
meta_xwayland_init_xrandr (manager, x11_display);
|
||||
}
|
||||
diff --git a/src/x11/meta-x11-display.c b/src/x11/meta-x11-display.c
|
||||
index 6b8d7faf55..6de0511dc6 100644
|
||||
--- a/src/x11/meta-x11-display.c
|
||||
+++ b/src/x11/meta-x11-display.c
|
||||
@@ -308,7 +308,6 @@ on_x11_display_opened (MetaX11Display *x11_display,
|
||||
MetaDisplay *display)
|
||||
{
|
||||
meta_display_manage_all_xwindows (display);
|
||||
- meta_x11_display_redirect_windows (x11_display, display);
|
||||
}
|
||||
|
||||
static void
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -0,0 +1,47 @@
|
||||
From 3a73958f7eab973189441ec9b4a4c96ee6bb8ec7 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Mon, 22 Jul 2024 12:55:30 +0200
|
||||
Subject: [PATCH 2/3] Revert "x11/window: Update comment and variable name to
|
||||
reflect current behavior"
|
||||
|
||||
This reverts commit e4763d00e8512aeb408ae118597d753f12217487.
|
||||
---
|
||||
src/x11/window-x11.c | 15 ++++++++-------
|
||||
1 file changed, 8 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index e7c76dd674..b358b64bf2 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2491,20 +2491,21 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
|
||||
if (region != NULL)
|
||||
{
|
||||
- MtkRectangle bounding_rect;
|
||||
+ MtkRectangle client_area;
|
||||
|
||||
- bounding_rect.x = 0;
|
||||
- bounding_rect.y = 0;
|
||||
- bounding_rect.width = window->buffer_rect.width;
|
||||
- bounding_rect.height = window->buffer_rect.height;
|
||||
+ client_area.x = 0;
|
||||
+ client_area.y = 0;
|
||||
+ client_area.width = window->buffer_rect.width;
|
||||
+ client_area.height = window->buffer_rect.height;
|
||||
|
||||
/* The shape we get back from the client may have coordinates
|
||||
* outside of the frame. The X SHAPE Extension requires that
|
||||
* the overall shape the client provides never exceeds the
|
||||
* "bounding rectangle" of the window -- the shape that the
|
||||
- * window would have gotten if it was unshaped.
|
||||
+ * window would have gotten if it was unshaped. In our case,
|
||||
+ * this is simply the client area.
|
||||
*/
|
||||
- mtk_region_intersect_rectangle (region, &bounding_rect);
|
||||
+ mtk_region_intersect_rectangle (region, &client_area);
|
||||
}
|
||||
|
||||
meta_window_set_input_region (window, region);
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -1,34 +1,20 @@
|
||||
From e20ebeefa42997fe65008b11ef771c71b697273c Mon Sep 17 00:00:00 2001
|
||||
From: Adam Williamson <awilliam@redhat.com>
|
||||
Date: Fri, 20 Oct 2023 22:12:23 -0700
|
||||
Subject: [PATCH] modified 3329
|
||||
From c6a74d8f4161440a530bea5ca3b5cf199beb046b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Fri, 20 Oct 2023 17:03:31 +0800
|
||||
Subject: [PATCH 2/4] display: Move X11 initial focus handling to
|
||||
MetaX11Display
|
||||
|
||||
Signed-off-by: Adam Williamson <awilliam@redhat.com>
|
||||
It's X11 specific, so put it in the X11 display manager object.
|
||||
---
|
||||
src/compositor/meta-compositor-x11.c | 2 ++
|
||||
src/core/display.c | 34 ----------------------------
|
||||
src/tests/x11-test.sh | 3 +++
|
||||
src/x11/meta-x11-display.c | 30 +++++++++++++++++++++++-
|
||||
4 files changed, 34 insertions(+), 35 deletions(-)
|
||||
|
||||
diff --git a/src/compositor/meta-compositor-x11.c b/src/compositor/meta-compositor-x11.c
|
||||
index 1ad3327dd..ce7bc1945 100644
|
||||
--- a/src/compositor/meta-compositor-x11.c
|
||||
+++ b/src/compositor/meta-compositor-x11.c
|
||||
@@ -188,6 +188,8 @@ meta_compositor_x11_manage (MetaCompositor *compositor,
|
||||
|
||||
compositor_x11->have_x11_sync_object = meta_sync_ring_init (xdisplay);
|
||||
|
||||
+ meta_x11_display_redirect_windows (x11_display, display);
|
||||
+
|
||||
return TRUE;
|
||||
}
|
||||
src/core/display.c | 34 ----------------------------------
|
||||
src/x11/meta-x11-display.c | 25 +++++++++++++++++++++++++
|
||||
2 files changed, 25 insertions(+), 34 deletions(-)
|
||||
|
||||
diff --git a/src/core/display.c b/src/core/display.c
|
||||
index 0a191c0fb..b16e50e21 100644
|
||||
index bd09082ed2..ddd475f457 100644
|
||||
--- a/src/core/display.c
|
||||
+++ b/src/core/display.c
|
||||
@@ -930,9 +930,6 @@ meta_display_new (MetaContext *context,
|
||||
@@ -945,9 +945,6 @@ meta_display_new (MetaContext *context,
|
||||
MetaDisplay *display;
|
||||
MetaDisplayPrivate *priv;
|
||||
guint32 timestamp;
|
||||
@ -38,7 +24,7 @@ index 0a191c0fb..b16e50e21 100644
|
||||
MetaMonitorManager *monitor_manager;
|
||||
MetaSettings *settings;
|
||||
MetaInputCapture *input_capture;
|
||||
@@ -1048,14 +1045,6 @@ meta_display_new (MetaContext *context,
|
||||
@@ -1065,14 +1062,6 @@ meta_display_new (MetaContext *context,
|
||||
display->last_focus_time = timestamp;
|
||||
display->last_user_time = timestamp;
|
||||
|
||||
@ -53,7 +39,7 @@ index 0a191c0fb..b16e50e21 100644
|
||||
if (!meta_compositor_manage (display->compositor, error))
|
||||
{
|
||||
g_object_unref (display);
|
||||
@@ -1076,30 +1065,7 @@ meta_display_new (MetaContext *context,
|
||||
@@ -1093,30 +1082,7 @@ meta_display_new (MetaContext *context,
|
||||
g_signal_connect (display->gesture_tracker, "state-changed",
|
||||
G_CALLBACK (gesture_tracker_state_changed), display);
|
||||
|
||||
@ -84,25 +70,11 @@ index 0a191c0fb..b16e50e21 100644
|
||||
|
||||
g_signal_connect (stage, "notify::is-grabbed",
|
||||
G_CALLBACK (on_is_grabbed_changed), display);
|
||||
diff --git a/src/tests/x11-test.sh b/src/tests/x11-test.sh
|
||||
index 59e460fc3..d95b2460f 100755
|
||||
--- a/src/tests/x11-test.sh
|
||||
+++ b/src/tests/x11-test.sh
|
||||
@@ -34,6 +34,9 @@ echo \# Launched with pid $MUTTER2_PID
|
||||
MUTTER2_PID=$!
|
||||
wait $MUTTER1_PID
|
||||
|
||||
+echo \# Waiting for the second mutter to finish loading
|
||||
+gdbus wait --session org.gnome.Mutter.IdleMonitor
|
||||
+
|
||||
sleep 2
|
||||
|
||||
echo \# Terminating clients > /dev/stderr
|
||||
diff --git a/src/x11/meta-x11-display.c b/src/x11/meta-x11-display.c
|
||||
index 4e98203dd..4ca620410 100644
|
||||
index 6de0511dc6..267fa1b835 100644
|
||||
--- a/src/x11/meta-x11-display.c
|
||||
+++ b/src/x11/meta-x11-display.c
|
||||
@@ -300,8 +300,36 @@ static void
|
||||
@@ -307,7 +307,32 @@ static void
|
||||
on_x11_display_opened (MetaX11Display *x11_display,
|
||||
MetaDisplay *display)
|
||||
{
|
||||
@ -115,13 +87,8 @@ index 4e98203dd..4ca620410 100644
|
||||
+ display->x11_display->atom__NET_ACTIVE_WINDOW,
|
||||
+ &old_active_xwindow);
|
||||
+ }
|
||||
+
|
||||
+ if (meta_is_wayland_compositor ())
|
||||
+ meta_x11_display_redirect_windows (x11_display, display);
|
||||
+
|
||||
+
|
||||
meta_display_manage_all_xwindows (display);
|
||||
- meta_x11_display_redirect_windows (x11_display, display);
|
||||
+
|
||||
+ if (old_active_xwindow != None)
|
||||
+ {
|
||||
@ -141,5 +108,5 @@ index 4e98203dd..4ca620410 100644
|
||||
|
||||
static void
|
||||
--
|
||||
2.41.0
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -0,0 +1,29 @@
|
||||
From 3e6ba58c875055037e45f651bbcf866d2d47d82f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Mon, 22 Jul 2024 12:55:44 +0200
|
||||
Subject: [PATCH 3/3] Revert "x11/window: Use correct bounding rect to
|
||||
determine NULL input region"
|
||||
|
||||
This reverts commit 6bd920b355d12395dbf00b99374fc1f23783caaf.
|
||||
---
|
||||
src/x11/window-x11.c | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/x11/window-x11.c b/src/x11/window-x11.c
|
||||
index b358b64bf2..16dc57eec2 100644
|
||||
--- a/src/x11/window-x11.c
|
||||
+++ b/src/x11/window-x11.c
|
||||
@@ -2473,8 +2473,8 @@ meta_window_x11_update_input_region (MetaWindow *window)
|
||||
else if (n_rects == 1 &&
|
||||
(rects[0].x == 0 &&
|
||||
rects[0].y == 0 &&
|
||||
- rects[0].width == window->buffer_rect.width &&
|
||||
- rects[0].height == window->buffer_rect.height))
|
||||
+ rects[0].width == priv->client_rect.width &&
|
||||
+ rects[0].height == priv->client_rect.height))
|
||||
{
|
||||
/* This is the bounding region case. Keep the
|
||||
* region as NULL. */
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -0,0 +1,33 @@
|
||||
From cc450c372358bc32960102ffdb2769a9f70cb6d5 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Tue, 17 Oct 2023 15:46:00 +0800
|
||||
Subject: [PATCH 3/4] tests/x11: Fix replace test to catch the second instance
|
||||
failing
|
||||
|
||||
The test never noticed that the second instance never actually managed
|
||||
to load; it was looping a multi second retry session trying to redirect
|
||||
windows, meaning it failed to catch https://gitlab.gnome.org/GNOME/mutter/-/issues/3089.
|
||||
|
||||
Fix the test so that it always waits for mutter to finish loading
|
||||
successfully, just like it waits fro the first.
|
||||
---
|
||||
src/tests/x11-test.sh | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/src/tests/x11-test.sh b/src/tests/x11-test.sh
|
||||
index 59e460fc33..d95b2460f6 100755
|
||||
--- a/src/tests/x11-test.sh
|
||||
+++ b/src/tests/x11-test.sh
|
||||
@@ -34,6 +34,9 @@ echo \# Launched with pid $MUTTER2_PID
|
||||
MUTTER2_PID=$!
|
||||
wait $MUTTER1_PID
|
||||
|
||||
+echo \# Waiting for the second mutter to finish loading
|
||||
+gdbus wait --session org.gnome.Mutter.IdleMonitor
|
||||
+
|
||||
sleep 2
|
||||
|
||||
echo \# Terminating clients > /dev/stderr
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -0,0 +1,41 @@
|
||||
From 5b589b298680bd394dd6a1ee7bef3d7def1a96c8 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jonas=20=C3=85dahl?= <jadahl@gmail.com>
|
||||
Date: Mon, 23 Oct 2023 14:47:33 +0800
|
||||
Subject: [PATCH 4/4] display: Rename mandatory X11 initialization function
|
||||
|
||||
Simply to make it clear that the renamed function is specific to a
|
||||
particular X11 initialization mode (mandatory Xwayland), put that in the
|
||||
name, so that it's easier to understand when this function is relevant.
|
||||
---
|
||||
src/core/display.c | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/src/core/display.c b/src/core/display.c
|
||||
index ddd475f457..e4f623ff9d 100644
|
||||
--- a/src/core/display.c
|
||||
+++ b/src/core/display.c
|
||||
@@ -910,9 +910,9 @@ meta_display_init_x11 (MetaDisplay *display,
|
||||
}
|
||||
|
||||
static void
|
||||
-on_x11_initialized (MetaDisplay *display,
|
||||
- GAsyncResult *result,
|
||||
- gpointer user_data)
|
||||
+on_mandatory_x11_initialized (MetaDisplay *display,
|
||||
+ GAsyncResult *result,
|
||||
+ gpointer user_data)
|
||||
{
|
||||
g_autoptr (GError) error = NULL;
|
||||
|
||||
@@ -1035,7 +1035,7 @@ meta_display_new (MetaContext *context,
|
||||
if (x11_display_policy == META_X11_DISPLAY_POLICY_MANDATORY)
|
||||
{
|
||||
meta_display_init_x11 (display, NULL,
|
||||
- (GAsyncReadyCallback) on_x11_initialized,
|
||||
+ (GAsyncReadyCallback) on_mandatory_x11_initialized,
|
||||
NULL);
|
||||
}
|
||||
#endif /* HAVE_XWAYLAND */
|
||||
--
|
||||
2.44.0.501.g19981daefd.dirty
|
||||
|
@ -1,25 +0,0 @@
|
||||
From a5c67e0debaa89f7a73452560664cdc5c581ab95 Mon Sep 17 00:00:00 2001
|
||||
From: Adam Williamson <awilliam@redhat.com>
|
||||
Date: Tue, 9 Mar 2021 17:21:59 -0800
|
||||
Subject: [PATCH] Test: deny atomic KMS for "tegra" (RHBZ #1936991)
|
||||
|
||||
Signed-off-by: Adam Williamson <awilliam@redhat.com>
|
||||
---
|
||||
src/backends/native/meta-kms-impl-device-atomic.c | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/src/backends/native/meta-kms-impl-device-atomic.c b/src/backends/native/meta-kms-impl-device-atomic.c
|
||||
index 35837f7429..ffff7b8e23 100644
|
||||
--- a/src/backends/native/meta-kms-impl-device-atomic.c
|
||||
+++ b/src/backends/native/meta-kms-impl-device-atomic.c
|
||||
@@ -1352,6 +1352,7 @@ is_atomic_allowed (const char *driver_name)
|
||||
{
|
||||
const char *atomic_driver_deny_list[] = {
|
||||
"xlnx",
|
||||
+ "tegra",
|
||||
NULL,
|
||||
};
|
||||
|
||||
--
|
||||
2.43.0
|
||||
|
24
mutter.spec
24
mutter.spec
@ -8,12 +8,12 @@
|
||||
%global lcms2_version 2.6
|
||||
%global colord_version 1.4.5
|
||||
%global libei_version 1.0.0
|
||||
%global mutter_api_version 14
|
||||
%global mutter_api_version 15
|
||||
|
||||
%global tarball_version %%(echo %{version} | tr '~' '.')
|
||||
|
||||
Name: mutter
|
||||
Version: 46.3
|
||||
Version: 47.alpha
|
||||
Release: %autorelease
|
||||
Summary: Window and compositing manager based on Clutter
|
||||
|
||||
@ -25,7 +25,7 @@ Source0: http://download.gnome.org/sources/%{name}/45/%{name}-%{tarball_ve
|
||||
Patch: 0001-window-actor-Special-case-shaped-Java-windows.patch
|
||||
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1936991
|
||||
Patch: mutter-42.alpha-disable-tegra.patch
|
||||
Patch: 0001-Test-deny-atomic-KMS-for-tegra-RHBZ-1936991.patch
|
||||
|
||||
# https://pagure.io/fedora-workstation/issue/79
|
||||
Patch: 0001-place-Always-center-initial-setup-fedora-welcome.patch
|
||||
@ -34,13 +34,15 @@ Patch: 0001-place-Always-center-initial-setup-fedora-welcome.patch
|
||||
# https://gitlab.gnome.org/GNOME/mutter/-/issues/3068
|
||||
# not upstreamed because for upstream we'd really want to find a way
|
||||
# to fix *both* problems
|
||||
Patch: 0001-Revert-x11-Use-input-region-from-frame-window-for-de.patch
|
||||
Patch: 0001-Revert-x11-window-Compare-input-shape-to-client-rect.patch
|
||||
Patch: 0002-Revert-x11-window-Update-comment-and-variable-name-t.patch
|
||||
Patch: 0003-Revert-x11-window-Use-correct-bounding-rect-to-deter.patch
|
||||
|
||||
# https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3329
|
||||
# Modified to add the change from
|
||||
# https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3329#note_1874837
|
||||
# which solves the problems reported with #3329 alone
|
||||
Patch: 0001-modified-3329.patch
|
||||
Patch: 0001-x11-display-Make-subwindow-redirection-call-mode-spe.patch
|
||||
Patch: 0002-display-Move-X11-initial-focus-handling-to-MetaX11Di.patch
|
||||
Patch: 0003-tests-x11-Fix-replace-test-to-catch-the-second-insta.patch
|
||||
Patch: 0004-display-Rename-mandatory-X11-initialization-function.patch
|
||||
|
||||
BuildRequires: pkgconfig(gobject-introspection-1.0) >= 1.41.0
|
||||
BuildRequires: pkgconfig(sm)
|
||||
@ -121,11 +123,11 @@ Provides: firstboot(windowmanager) = mutter
|
||||
Provides: bundled(cogl) = 1.22.0
|
||||
Provides: bundled(clutter) = 1.26.0
|
||||
|
||||
Conflicts: mutter < 45~beta.1-2
|
||||
Conflicts: mutter < 46~beta
|
||||
|
||||
# Make sure dnf updates gnome-shell together with this package; otherwise we
|
||||
# might end up with broken gnome-shell installations due to mutter ABI changes.
|
||||
Conflicts: gnome-shell < 45~rc
|
||||
Conflicts: gnome-shell < 46~rc
|
||||
|
||||
%description
|
||||
Mutter is a window and compositing manager that displays and manages
|
||||
@ -142,7 +144,7 @@ behaviors to meet the needs of the environment.
|
||||
%package common
|
||||
Summary: Common files used by %{name} and forks of %{name}
|
||||
BuildArch: noarch
|
||||
Conflicts: mutter < 45~beta.1-2
|
||||
Conflicts: mutter < 46~beta
|
||||
|
||||
%description common
|
||||
Common files used by Mutter and soft forks of Mutter
|
||||
|
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (mutter-46.3.tar.xz) = 82e2e8455556e1a6e9dfd8b7d36f8d500fac69094907012754ee8d653f448397fe4a277e5a9b327051a319697205b56d0f7a9ea789d210e58ec685b589d2f150
|
||||
SHA512 (mutter-47.alpha.tar.xz) = 5f296aa3fa7739e9ff855e58e3bb8edf2fb869f4ce299982dca948b30ff1cb21adbcf34a18bb78d6e15e59a4451bc1130d985012daecebe0e4bbb0f8e3aa7191
|
||||
|
Loading…
Reference in New Issue
Block a user