diff --git a/0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch b/0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch index 9d3846f..3501eb5 100644 --- a/0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch +++ b/0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch @@ -9,11 +9,11 @@ This reverts commit 703bbe0e99dbb688352e0bff396e5cbf2c6af45b. clutter/clutter/clutter-actor.c | 67 ++++++++++----------------------- 1 file changed, 20 insertions(+), 47 deletions(-) -diff --git a/clutter/clutter/clutter-actor.c b/clutter/clutter/clutter-actor.c -index dd0d5ceb6..70dea5ca2 100644 ---- a/clutter/clutter/clutter-actor.c -+++ b/clutter/clutter/clutter-actor.c -@@ -612,7 +612,7 @@ struct _ClutterActorPrivate +Index: mutter-47.beta/clutter/clutter/clutter-actor.c +=================================================================== +--- mutter-47.beta.orig/clutter/clutter/clutter-actor.c ++++ mutter-47.beta/clutter/clutter/clutter-actor.c +@@ -567,7 +567,7 @@ struct _ClutterActorPrivate /* the cached transformation matrix; see apply_transform() */ graphene_matrix_t transform; @@ -22,7 +22,7 @@ index dd0d5ceb6..70dea5ca2 100644 float resource_scale; -@@ -776,7 +776,7 @@ struct _ClutterActorPrivate +@@ -731,7 +731,7 @@ struct _ClutterActorPrivate guint clear_stage_views_needs_stage_views_changed : 1; guint needs_redraw : 1; guint needs_finish_layout : 1; @@ -31,7 +31,7 @@ index dd0d5ceb6..70dea5ca2 100644 }; enum -@@ -2425,7 +2425,7 @@ absolute_geometry_changed (ClutterActor *actor) +@@ -2315,7 +2315,7 @@ absolute_geometry_changed (ClutterActor { actor->priv->needs_update_stage_views = TRUE; actor->priv->needs_visible_paint_volume_update = TRUE; @@ -40,7 +40,7 @@ index dd0d5ceb6..70dea5ca2 100644 actor->priv->needs_finish_layout = TRUE; /* needs_finish_layout is already TRUE on the whole parent tree thanks -@@ -3047,9 +3047,8 @@ _clutter_actor_apply_relative_transformation_matrix (ClutterActor *self, +@@ -2944,9 +2944,8 @@ _clutter_actor_apply_relative_transforma graphene_matrix_t *matrix) { ClutterActorPrivate *priv = self->priv; @@ -52,7 +52,7 @@ index dd0d5ceb6..70dea5ca2 100644 /* Note we terminate before ever calling stage->apply_transform() * since that would conceptually be relative to the underlying -@@ -3058,63 +3057,37 @@ _clutter_actor_apply_relative_transformation_matrix (ClutterActor *self, +@@ -2955,63 +2954,37 @@ _clutter_actor_apply_relative_transforma if (self == ancestor) return; @@ -130,7 +130,7 @@ index dd0d5ceb6..70dea5ca2 100644 return; } -@@ -7469,7 +7442,7 @@ clutter_actor_init (ClutterActor *self) +@@ -7398,7 +7371,7 @@ clutter_actor_init (ClutterActor *self) priv->enable_model_view_transform = TRUE; priv->transform_valid = FALSE; @@ -139,6 +139,3 @@ index dd0d5ceb6..70dea5ca2 100644 /* the default is to stretch the content, to match the * current behaviour of basically all actors. also, it's --- -2.44.0 - diff --git a/0001-Revert-clutter-stage-Avoid-queueing-stage-updates-wh.patch b/0001-Revert-clutter-stage-Avoid-queueing-stage-updates-wh.patch deleted file mode 100644 index fe3bb09..0000000 --- a/0001-Revert-clutter-stage-Avoid-queueing-stage-updates-wh.patch +++ /dev/null @@ -1,134 +0,0 @@ -From 3f3c8876e0494cf7af92ce9b216da70fd4c0c275 Mon Sep 17 00:00:00 2001 -From: Xiaoguang Wang -Date: Tue, 23 Apr 2024 12:28:45 +0800 -Subject: [PATCH] Revert "clutter/stage: Avoid queueing stage updates when - they're already queued" - -This reverts commit 261f516af4e635d4bb263bbbbb2f843f0cbe09de. ---- - clutter/clutter/clutter-stage-private.h | 2 +- - clutter/clutter/clutter-stage-view.c | 2 +- - clutter/clutter/clutter-stage.c | 30 +++++++++---------------- - 3 files changed, 12 insertions(+), 22 deletions(-) - -diff --git a/clutter/clutter/clutter-stage-private.h b/clutter/clutter/clutter-stage-private.h -index c2460b327..f84fb10fe 100644 ---- a/clutter/clutter/clutter-stage-private.h -+++ b/clutter/clutter/clutter-stage-private.h -@@ -61,7 +61,7 @@ void clutter_stage_emit_before_paint (ClutterStage - void clutter_stage_emit_after_paint (ClutterStage *stage, - ClutterStageView *view, - ClutterFrame *frame); --void clutter_stage_after_update (ClutterStage *stage, -+void clutter_stage_emit_after_update (ClutterStage *stage, - ClutterStageView *view, - ClutterFrame *frame); - -diff --git a/clutter/clutter/clutter-stage-view.c b/clutter/clutter/clutter-stage-view.c -index 168746dd4..b59d1cc00 100644 ---- a/clutter/clutter/clutter-stage-view.c -+++ b/clutter/clutter/clutter-stage-view.c -@@ -1279,7 +1279,7 @@ handle_frame_clock_frame (ClutterFrameClock *frame_clock, - priv->needs_update_devices = FALSE; - - _clutter_run_repaint_functions (CLUTTER_REPAINT_FLAGS_POST_PAINT); -- clutter_stage_after_update (stage, view, frame); -+ clutter_stage_emit_after_update (stage, view, frame); - - return clutter_frame_get_result (frame); - } -diff --git a/clutter/clutter/clutter-stage.c b/clutter/clutter/clutter-stage.c -index 47405872b..f1d40426f 100644 ---- a/clutter/clutter/clutter-stage.c -+++ b/clutter/clutter/clutter-stage.c -@@ -137,8 +137,6 @@ struct _ClutterStagePrivate - - int update_freeze_count; - -- gboolean update_scheduled; -- - GHashTable *pointer_devices; - GHashTable *touch_sequences; - -@@ -528,15 +526,11 @@ clutter_stage_emit_after_paint (ClutterStage *stage, - } - - void --clutter_stage_after_update (ClutterStage *stage, -- ClutterStageView *view, -- ClutterFrame *frame) -+clutter_stage_emit_after_update (ClutterStage *stage, -+ ClutterStageView *view, -+ ClutterFrame *frame) - { -- ClutterStagePrivate *priv = stage->priv; -- - g_signal_emit (stage, stage_signals[AFTER_UPDATE], 0, view, frame); -- -- priv->update_scheduled = FALSE; - } - - static gboolean -@@ -647,15 +641,19 @@ _clutter_stage_queue_event (ClutterStage *stage, - gboolean copy_event) - { - ClutterStagePrivate *priv; -+ gboolean first_event; - - g_return_if_fail (CLUTTER_IS_STAGE (stage)); - - priv = stage->priv; - -+ first_event = priv->event_queue->length == 0; -+ - g_queue_push_tail (priv->event_queue, - copy_event ? clutter_event_copy (event) : event); - -- clutter_stage_schedule_update (stage); -+ if (first_event) -+ clutter_stage_schedule_update (stage); - } - - gboolean -@@ -818,7 +816,8 @@ clutter_stage_queue_actor_relayout (ClutterStage *stage, - { - ClutterStagePrivate *priv = stage->priv; - -- clutter_stage_schedule_update (stage); -+ if (priv->pending_relayouts == NULL) -+ clutter_stage_schedule_update (stage); - - priv->pending_relayouts = g_slist_prepend (priv->pending_relayouts, - g_object_ref (actor)); -@@ -2532,19 +2531,12 @@ _clutter_stage_get_default_window (void) - void - clutter_stage_schedule_update (ClutterStage *stage) - { -- ClutterStagePrivate *priv = stage->priv; - ClutterStageWindow *stage_window; -- gboolean first_event; - GList *l; - - if (CLUTTER_ACTOR_IN_DESTRUCTION (stage)) - return; - -- first_event = priv->event_queue->length == 0; -- -- if (priv->update_scheduled && !first_event) -- return; -- - stage_window = _clutter_stage_get_window (stage); - if (stage_window == NULL) - return; -@@ -2555,8 +2547,6 @@ clutter_stage_schedule_update (ClutterStage *stage) - - clutter_stage_view_schedule_update (view); - } -- -- priv->update_scheduled = TRUE; - } - - ClutterPaintVolume * --- -2.44.0 - diff --git a/_service b/_service index 6f25d82..2f90786 100644 --- a/_service +++ b/_service @@ -3,16 +3,24 @@ git https://gitlab.gnome.org/GNOME/mutter.git - refs/tags/45.3 + 47.1 @PARENT_TAG@+@TAG_OFFSET@ (.*)\+0 \1 - + disable + + + git + https://gitlab.gnome.org/GNOME/gvdb.git + b54bc5da25127ef416858a3ad92e57159ff565b3 + 0.gitmodule *.tar zst - + + mutter + diff --git a/gvdb-0.gitmodule.obscpio b/gvdb-0.gitmodule.obscpio new file mode 100644 index 0000000..7c666ec --- /dev/null +++ b/gvdb-0.gitmodule.obscpio @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8d359f5c97fe6db79919d7b299eb18b6f858be869a21636fbdfa452325f424b7 +size 110091 diff --git a/gvdb.obsinfo b/gvdb.obsinfo new file mode 100644 index 0000000..33df2bd --- /dev/null +++ b/gvdb.obsinfo @@ -0,0 +1,4 @@ +name: gvdb +version: 0.gitmodule +mtime: 1725181085 +commit: b54bc5da25127ef416858a3ad92e57159ff565b3 diff --git a/mutter-45.3.obscpio b/mutter-45.3.obscpio deleted file mode 100644 index 9f463dd..0000000 --- a/mutter-45.3.obscpio +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9a83a17f6b454d3247772ed43d5999efe9726d1b09fbc8cceebd8208f599efdc -size 26478093 diff --git a/mutter-47.1.obscpio b/mutter-47.1.obscpio new file mode 100644 index 0000000..39cae95 --- /dev/null +++ b/mutter-47.1.obscpio @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d66c0f1a0a5ae3c6e8c44b9dd2213f70b8af0021d5bf54dc6a8fa4c20ad68d9 +size 30735373 diff --git a/mutter-SLE-relax-some-constraints-on-CSD-windows.patch b/mutter-SLE-relax-some-constraints-on-CSD-windows.patch index 05edb40..689abdf 100644 --- a/mutter-SLE-relax-some-constraints-on-CSD-windows.patch +++ b/mutter-SLE-relax-some-constraints-on-CSD-windows.patch @@ -1,8 +1,7 @@ -Index: mutter-3.23.2/src/core/constraints.c -=================================================================== ---- mutter-3.23.2.orig/src/core/constraints.c -+++ mutter-3.23.2/src/core/constraints.c -@@ -1466,6 +1466,12 @@ constrain_to_single_monitor (MetaWindow +diff -urp mutter-46.3.1.orig/src/core/constraints.c mutter-46.3.1/src/core/constraints.c +--- mutter-46.3.1.orig/src/core/constraints.c 2024-07-30 13:54:28.842797794 -0500 ++++ mutter-46.3.1/src/core/constraints.c 2024-07-30 14:02:54.984030220 -0500 +@@ -1730,6 +1730,12 @@ constrain_to_single_monitor (MetaWindow } static gboolean @@ -15,7 +14,7 @@ Index: mutter-3.23.2/src/core/constraints.c constrain_fully_onscreen (MetaWindow *window, ConstraintInfo *info, ConstraintPriority priority, -@@ -1481,6 +1487,11 @@ constrain_fully_onscreen (MetaWindow +@@ -1745,6 +1751,11 @@ constrain_fully_onscreen (MetaWindow if (window->type == META_WINDOW_DESKTOP || window->type == META_WINDOW_DOCK || window->fullscreen || @@ -27,7 +26,7 @@ Index: mutter-3.23.2/src/core/constraints.c !window->require_fully_onscreen || info->is_user_action || meta_window_get_placement_rule (window)) -@@ -1518,11 +1529,12 @@ constrain_titlebar_visible (MetaWindow +@@ -1802,12 +1813,13 @@ constrain_titlebar_visible (MetaWindow * is only meant for normal windows (e.g. we don't want docks to be shoved * "onscreen" by their own strut). */ @@ -36,12 +35,14 @@ Index: mutter-3.23.2/src/core/constraints.c - window->fullscreen || - !window->require_titlebar_visible || - unconstrained_user_action || +- user_nonnorthern_resize || + if (window->type == META_WINDOW_DESKTOP || + window->type == META_WINDOW_DOCK || + window->fullscreen || -+ (constraint_is_sle_classic() && !window->decorated) || + !window->require_titlebar_visible || ++ (constraint_is_sle_classic() && !window->decorated) || + unconstrained_user_action || ++ user_nonnorthern_resize || meta_window_get_placement_rule (window)) return TRUE; diff --git a/mutter-disable-cvt-s390x.patch b/mutter-disable-cvt-s390x.patch index eb16e8b..a0a4069 100644 --- a/mutter-disable-cvt-s390x.patch +++ b/mutter-disable-cvt-s390x.patch @@ -1,6 +1,7 @@ -diff -druN mutter-45.1.orig/src/backends/native/meta-default-modes-s390x.h mutter-45.1/src/backends/native/meta-default-modes-s390x.h ---- mutter-45.1.orig/src/backends/native/meta-default-modes-s390x.h 1970-01-01 01:00:00.000000000 +0100 -+++ mutter-45.1/src/backends/native/meta-default-modes-s390x.h 2024-01-23 16:35:55.791416596 +0100 +Index: mutter-47.beta/src/backends/native/meta-default-modes-s390x.h +=================================================================== +--- /dev/null ++++ mutter-47.beta/src/backends/native/meta-default-modes-s390x.h @@ -0,0 +1,57 @@ +/* Generated by gen-default-modes.py */ + @@ -59,10 +60,11 @@ diff -druN mutter-45.1.orig/src/backends/native/meta-default-modes-s390x.h mutte +{ 813000, 2304, 2307, 2312, 2386, 0, 4096, 4440, 4888, 5680, 0, 0, DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, DRM_MODE_TYPE_DEFAULT, "2304x4096_60.00" }, +{ 1276500, 2880, 2883, 2888, 2982, 0, 5120, 5560, 6128, 7136, 0, 0, DRM_MODE_FLAG_PHSYNC | DRM_MODE_FLAG_NVSYNC, DRM_MODE_TYPE_DEFAULT, "2880x5120_60.00" }, +}; -diff -druN mutter-45.1.orig/src/meson.build mutter-45.1/src/meson.build ---- mutter-45.1.orig/src/meson.build 2023-10-31 19:35:00.000000000 +0100 -+++ mutter-45.1/src/meson.build 2024-01-23 18:07:33.487280694 +0100 -@@ -958,6 +958,7 @@ +Index: mutter-47.beta/src/meson.build +=================================================================== +--- mutter-47.beta.orig/src/meson.build ++++ mutter-47.beta/src/meson.build +@@ -985,6 +985,7 @@ if have_profiler endif if have_native_backend @@ -70,7 +72,7 @@ diff -druN mutter-45.1.orig/src/meson.build mutter-45.1/src/meson.build cvt = find_program('cvt') gen_default_modes = find_program('backends/native/gen-default-modes.py') -@@ -965,6 +966,13 @@ +@@ -992,6 +993,13 @@ if have_native_backend output: 'meta-default-modes.h', command: [gen_default_modes, '@OUTPUT@'] ) diff --git a/mutter-fix-initial-suspended-state.patch b/mutter-fix-initial-suspended-state.patch deleted file mode 100644 index 2b52488..0000000 --- a/mutter-fix-initial-suspended-state.patch +++ /dev/null @@ -1,182 +0,0 @@ -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/core/window.c mutter-45.3.new/src/core/window.c ---- mutter-45.3.old/src/core/window.c 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/core/window.c 2024-06-04 16:54:29.485138788 +0800 -@@ -165,6 +165,8 @@ - MetaTileMode mode); - static void update_edge_constraints (MetaWindow *window); - -+static void set_hidden_suspended_state (MetaWindow *window); -+ - static void initable_iface_init (GInitableIface *initable_iface); - - typedef struct _MetaWindowPrivate -@@ -750,9 +752,6 @@ - static void - meta_window_init (MetaWindow *window) - { -- MetaWindowPrivate *priv = meta_window_get_instance_private (window); -- -- priv->suspend_state = META_WINDOW_SUSPEND_STATE_SUSPENDED; - window->stamp = next_window_stamp++; - meta_prefs_add_listener (prefs_changed_callback, window); - window->is_alive = TRUE; -@@ -1026,6 +1025,7 @@ - meta_window_constructed (GObject *object) - { - MetaWindow *window = META_WINDOW (object); -+ MetaWindowPrivate *priv = meta_window_get_instance_private (window); - MetaDisplay *display = window->display; - MetaContext *context = meta_display_get_context (display); - MetaBackend *backend = meta_context_get_backend (context); -@@ -1381,6 +1381,11 @@ - !window->initially_iconic) - unminimize_window_and_all_transient_parents (window); - -+ /* There is a slim chance we'll hit time out before a extremely slow client -+ * managed to become active, but unlikely enough. */ -+ priv->suspend_state = META_WINDOW_SUSPEND_STATE_HIDDEN; -+ set_hidden_suspended_state (window); -+ - window->constructing = FALSE; - } - -@@ -1716,9 +1721,9 @@ - return TRUE; - } - --gboolean --meta_window_should_be_showing_on_workspace (MetaWindow *window, -- MetaWorkspace *workspace) -+ -+static gboolean -+meta_window_is_showable (MetaWindow *window) - { - #ifdef HAVE_WAYLAND - if (window->client_type == META_WINDOW_CLIENT_TYPE_WAYLAND && -@@ -1730,12 +1735,72 @@ - window->decorated && !window->frame) - return FALSE; - -- /* Windows should be showing if they're located on the -- * workspace and they're showing on their own workspace. */ -+ return TRUE; -+} -+ -+/** -+ * meta_window_should_show_on_workspace: -+ * -+ * Tells whether a window should be showing on the passed workspace, without -+ * taking into account whether it can immediately be shown. Whether it can be -+ * shown or not depends on what windowing system it was created from. -+ * -+ * Returns: %TRUE if the window should show. -+ */ -+static gboolean -+meta_window_should_show_on_workspace (MetaWindow *window, -+ MetaWorkspace *workspace) -+{ - return (meta_window_located_on_workspace (window, workspace) && - meta_window_showing_on_its_workspace (window)); - } - -+/** -+ * meta_window_should_show: -+ * -+ * Tells whether a window should be showing on the current workspace, without -+ * taking into account whether it can immediately be shown. Whether it can be -+ * shown or not depends on what windowing system it was created from. -+ * -+ * Returns: %TRUE if the window should show. -+ */ -+gboolean -+meta_window_should_show (MetaWindow *window) -+{ -+ MetaWorkspaceManager *workspace_manager = window->display->workspace_manager; -+ MetaWorkspace *active_workspace = workspace_manager->active_workspace; -+ -+ return meta_window_should_show_on_workspace (window, active_workspace); -+} -+ -+/** -+ * meta_window_should_be_showing_on_workspace: -+ * -+ * Tells whether a window should be showing on the passed workspace, while -+ * taking whether it can be immediately be shown. Whether it can be shown or -+ * not depends on what windowing system it was created from. -+ * -+ * Returns: %TRUE if the window should and can be shown. -+ */ -+gboolean -+meta_window_should_be_showing_on_workspace (MetaWindow *window, -+ MetaWorkspace *workspace) -+{ -+ if (!meta_window_is_showable (window)) -+ return FALSE; -+ -+ return meta_window_should_show_on_workspace (window, workspace); -+} -+ -+/** -+ * meta_window_should_be_showing: -+ * -+ * Tells whether a window should be showing on the current workspace, while -+ * taking whether it can be immediately be shown. Whether it can be shown or -+ * not depends on what windowing system it was created from. -+ * -+ * Returns: %TRUE if the window should and can be shown. -+ */ - gboolean - meta_window_should_be_showing (MetaWindow *window) - { -@@ -2132,6 +2197,19 @@ - } - - static void -+set_hidden_suspended_state (MetaWindow *window) -+{ -+ MetaWindowPrivate *priv = meta_window_get_instance_private (window); -+ -+ priv->suspend_state = META_WINDOW_SUSPEND_STATE_HIDDEN; -+ g_return_if_fail (!priv->suspend_timoeut_id); -+ priv->suspend_timoeut_id = -+ g_timeout_add_seconds (SUSPEND_HIDDEN_TIMEOUT_S, -+ enter_suspend_state_cb, -+ window); -+} -+ -+static void - update_suspend_state (MetaWindow *window) - { - MetaWindowPrivate *priv = meta_window_get_instance_private (window); -@@ -2148,13 +2226,8 @@ - } - else if (priv->suspend_state == META_WINDOW_SUSPEND_STATE_ACTIVE) - { -- priv->suspend_state = META_WINDOW_SUSPEND_STATE_HIDDEN; -+ set_hidden_suspended_state (window); - g_object_notify_by_pspec (G_OBJECT (window), obj_props[PROP_SUSPEND_STATE]); -- g_return_if_fail (!priv->suspend_timoeut_id); -- priv->suspend_timoeut_id = -- g_timeout_add_seconds (SUSPEND_HIDDEN_TIMEOUT_S, -- enter_suspend_state_cb, -- window); - } - } - -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/core/window-private.h mutter-45.3.new/src/core/window-private.h ---- mutter-45.3.old/src/core/window-private.h 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/core/window-private.h 2024-06-04 16:49:30.834738705 +0800 -@@ -679,9 +679,12 @@ - gboolean meta_window_should_be_showing_on_workspace (MetaWindow *window, - MetaWorkspace *workspace); - --/* Return whether the window should be currently mapped */ -+META_EXPORT_TEST - gboolean meta_window_should_be_showing (MetaWindow *window); - -+META_EXPORT_TEST -+gboolean meta_window_should_show (MetaWindow *window); -+ - void meta_window_update_struts (MetaWindow *window); - - /* gets position we need to set to stay in current position, diff --git a/mutter-fix-text-input-delete-surrounding.patch b/mutter-fix-text-input-delete-surrounding.patch deleted file mode 100644 index 6ab05d4..0000000 --- a/mutter-fix-text-input-delete-surrounding.patch +++ /dev/null @@ -1,207 +0,0 @@ -From 27bdf0c577a551254551fdaaf7870c5072707c69 Mon Sep 17 00:00:00 2001 -From: Alynx Zhou -Date: Fri, 25 Nov 2022 15:48:01 +0800 -Subject: [PATCH 1/2] wayland/text-input: Use byte based offset in - delete_surrounding_text - -ClutterInputFocus/GtkIMContext uses char based offset for -delete_surrounding, however, text_input_v3 uses byte based offset for -it. Currently only GTK with mutter can work correctly via text_input_v3 -because they both forget to convert between char based offset and byte -based offset. - -This commit fixes it in mutter by saving committed surrounding text in -MetaWaylandTextInput and converting char based offset to byte based -offset with the UTF-8 encoded surrounding text. - -Fixes . - -Part-of: ---- - src/wayland/meta-wayland-text-input.c | 55 +++++++++++++++++++++++---- - 1 file changed, 47 insertions(+), 8 deletions(-) - -diff --git a/src/wayland/meta-wayland-text-input.c b/src/wayland/meta-wayland-text-input.c -index b1ceb1a6bb5..2e694dc1eb8 100644 ---- a/src/wayland/meta-wayland-text-input.c -+++ b/src/wayland/meta-wayland-text-input.c -@@ -58,6 +58,20 @@ struct _MetaWaylandTextInput - - GHashTable *resource_serials; - -+ /* This saves the uncommitted middle state of surrounding text from client -+ * between `set_surrounding_text` and `commit`, will be cleared after -+ * committed. -+ */ -+ struct -+ { -+ char *text; -+ uint32_t cursor; -+ uint32_t anchor; -+ } pending_surrounding; -+ -+ /* This is the actual committed surrounding text after `commit`, we need this -+ * to convert between char based offset and byte based offset. -+ */ - struct - { - char *text; -@@ -216,14 +230,32 @@ meta_wayland_text_input_focus_delete_surrounding (ClutterInputFocus *focus, - guint len) - { - MetaWaylandTextInput *text_input; -+ const char *start, *end; -+ const char *before, *after; -+ const char *cursor; - uint32_t before_length; - uint32_t after_length; - struct wl_resource *resource; - -+ /* offset and len are counted by UTF-8 chars, but text_input_v3's lengths are -+ * counted by bytes, so we convert UTF-8 char offsets to pointers here, this -+ * needs the surrounding text -+ */ - text_input = META_WAYLAND_TEXT_INPUT_FOCUS (focus)->text_input; -- before_length = ABS (MIN (offset, 0)); -- after_length = MAX (0, offset + len); -- g_warn_if_fail (ABS (offset) <= len); -+ offset = MIN (offset, 0); -+ -+ start = text_input->surrounding.text; -+ end = start + strlen (text_input->surrounding.text); -+ cursor = start + text_input->surrounding.cursor; -+ -+ before = g_utf8_offset_to_pointer (cursor, offset); -+ g_assert (before >= start); -+ -+ after = g_utf8_offset_to_pointer (cursor, offset + len); -+ g_assert (after <= end); -+ -+ before_length = cursor - before; -+ after_length = after - cursor; - - wl_resource_for_each (resource, &text_input->focus_resource_list) - { -@@ -468,10 +500,10 @@ text_input_set_surrounding_text (struct wl_client *client, - if (!client_matches_focus (text_input, client)) - return; - -- g_free (text_input->surrounding.text); -- text_input->surrounding.text = g_strdup (text); -- text_input->surrounding.cursor = cursor; -- text_input->surrounding.anchor = anchor; -+ g_free (text_input->pending_surrounding.text); -+ text_input->pending_surrounding.text = g_strdup (text); -+ text_input->pending_surrounding.cursor = cursor; -+ text_input->pending_surrounding.anchor = anchor; - text_input->pending_state |= META_WAYLAND_PENDING_STATE_SURROUNDING_TEXT; - } - -@@ -591,7 +623,7 @@ text_input_set_cursor_rectangle (struct wl_client *client, - static void - meta_wayland_text_input_reset (MetaWaylandTextInput *text_input) - { -- g_clear_pointer (&text_input->surrounding.text, g_free); -+ g_clear_pointer (&text_input->pending_surrounding.text, g_free); - text_input->content_type_hint = ZWP_TEXT_INPUT_V3_CONTENT_HINT_NONE; - text_input->content_type_purpose = ZWP_TEXT_INPUT_V3_CONTENT_PURPOSE_NORMAL; - text_input->text_change_cause = ZWP_TEXT_INPUT_V3_CHANGE_CAUSE_INPUT_METHOD; -@@ -651,6 +683,12 @@ text_input_commit_state (struct wl_client *client, - - if (text_input->pending_state & META_WAYLAND_PENDING_STATE_SURROUNDING_TEXT) - { -+ /* Save the surrounding text for `delete_surrounding_text`. */ -+ g_free (text_input->surrounding.text); -+ text_input->surrounding.text = g_steal_pointer (&text_input->pending_surrounding.text); -+ text_input->surrounding.cursor = text_input->pending_surrounding.cursor; -+ text_input->surrounding.anchor = text_input->pending_surrounding.anchor; -+ /* Pass the surrounding text to Clutter to handle it with input method. */ - clutter_input_focus_set_surrounding (text_input->input_focus, - text_input->surrounding.text, - text_input->surrounding.cursor, -@@ -720,6 +758,7 @@ meta_wayland_text_input_destroy (MetaWaylandTextInput *text_input) - g_object_unref (text_input->input_focus); - g_hash_table_destroy (text_input->resource_serials); - g_clear_pointer (&text_input->preedit.string, g_free); -+ g_clear_pointer (&text_input->pending_surrounding.text, g_free); - g_clear_pointer (&text_input->surrounding.text, g_free); - g_free (text_input); - } --- -GitLab - - -From 33088d59db742cf802977a9d8ec8b4ea3ca79ea0 Mon Sep 17 00:00:00 2001 -From: Alynx Zhou -Date: Mon, 23 Oct 2023 14:32:21 +0800 -Subject: [PATCH 2/2] wayland/text-input: Pass char based offset to - ClutterInputFocus - -Wayland's text-input-v3 uses byte based offset for cursor and anchor of -surrounding text, but Clutter needs char based offset here. This commit -converts byte based offset to char based offset before passing them to -ClutterInputFocus. - -Fixes . - -Part-of: ---- - src/wayland/meta-wayland-text-input.c | 24 +++++++++++++++++++----- - 1 file changed, 19 insertions(+), 5 deletions(-) - -diff --git a/src/wayland/meta-wayland-text-input.c b/src/wayland/meta-wayland-text-input.c -index 2e694dc1eb8..c8f50847a88 100644 ---- a/src/wayland/meta-wayland-text-input.c -+++ b/src/wayland/meta-wayland-text-input.c -@@ -122,12 +122,18 @@ static void - meta_wayland_text_input_focus_request_surrounding (ClutterInputFocus *focus) - { - MetaWaylandTextInput *text_input; -+ long cursor, anchor; - -+ /* Clutter uses char offsets but text-input-v3 uses byte offsets. */ - text_input = META_WAYLAND_TEXT_INPUT_FOCUS (focus)->text_input; -+ cursor = g_utf8_strlen (text_input->surrounding.text, -+ text_input->surrounding.cursor); -+ anchor = g_utf8_strlen (text_input->surrounding.text, -+ text_input->surrounding.anchor); - clutter_input_focus_set_surrounding (focus, -- text_input->surrounding.text, -- text_input->surrounding.cursor, -- text_input->surrounding.anchor); -+ text_input->surrounding.text, -+ cursor, -+ anchor); - } - - static uint32_t -@@ -683,16 +689,24 @@ text_input_commit_state (struct wl_client *client, - - if (text_input->pending_state & META_WAYLAND_PENDING_STATE_SURROUNDING_TEXT) - { -+ long cursor, anchor; -+ - /* Save the surrounding text for `delete_surrounding_text`. */ - g_free (text_input->surrounding.text); - text_input->surrounding.text = g_steal_pointer (&text_input->pending_surrounding.text); - text_input->surrounding.cursor = text_input->pending_surrounding.cursor; - text_input->surrounding.anchor = text_input->pending_surrounding.anchor; -+ - /* Pass the surrounding text to Clutter to handle it with input method. */ -+ /* Clutter uses char offsets but text-input-v3 uses byte offsets. */ -+ cursor = g_utf8_strlen (text_input->surrounding.text, -+ text_input->surrounding.cursor); -+ anchor = g_utf8_strlen (text_input->surrounding.text, -+ text_input->surrounding.anchor); - clutter_input_focus_set_surrounding (text_input->input_focus, - text_input->surrounding.text, -- text_input->surrounding.cursor, -- text_input->surrounding.anchor); -+ cursor, -+ anchor); - } - - if (text_input->pending_state & META_WAYLAND_PENDING_STATE_INPUT_RECT) --- -GitLab - diff --git a/mutter-fix-x11-restart.patch b/mutter-fix-x11-restart.patch deleted file mode 100644 index 82a49de..0000000 --- a/mutter-fix-x11-restart.patch +++ /dev/null @@ -1,251 +0,0 @@ -From b7a1159a1ecd08b5e6aa1279fea84accf846b411 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Jonas=20=C3=85dahl?= -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 1ad3327ddf6..ce7bc1945ce 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 e95ca564010..83f2fcb25d9 100644 ---- a/src/wayland/meta-xwayland.c -+++ b/src/wayland/meta-xwayland.c -@@ -1170,6 +1170,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 4e98203dd25..c634a71fb2a 100644 ---- a/src/x11/meta-x11-display.c -+++ b/src/x11/meta-x11-display.c -@@ -301,7 +301,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 --- -GitLab - - -From 77fc07943c3171a5e7a047ca34af46feeca347c2 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Jonas=20=C3=85dahl?= -Date: Fri, 20 Oct 2023 17:03:31 +0800 -Subject: [PATCH 2/4] display: Move X11 initial focus handling to - MetaX11Display - -It's X11 specific, so put it in the X11 display manager object. ---- - 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 0a191c0fbca..b16e50e21de 100644 ---- a/src/core/display.c -+++ b/src/core/display.c -@@ -930,9 +930,6 @@ meta_display_new (MetaContext *context, - MetaDisplay *display; - MetaDisplayPrivate *priv; - guint32 timestamp; --#ifdef HAVE_X11_CLIENT -- Window old_active_xwindow = None; --#endif - MetaMonitorManager *monitor_manager; - MetaSettings *settings; - MetaInputCapture *input_capture; -@@ -1048,14 +1045,6 @@ meta_display_new (MetaContext *context, - display->last_focus_time = timestamp; - display->last_user_time = timestamp; - --#ifdef HAVE_X11 -- if (!meta_is_wayland_compositor ()) -- meta_prop_get_window (display->x11_display, -- display->x11_display->xroot, -- display->x11_display->atom__NET_ACTIVE_WINDOW, -- &old_active_xwindow); --#endif -- - if (!meta_compositor_manage (display->compositor, error)) - { - g_object_unref (display); -@@ -1076,30 +1065,7 @@ meta_display_new (MetaContext *context, - g_signal_connect (display->gesture_tracker, "state-changed", - G_CALLBACK (gesture_tracker_state_changed), display); - -- /* We know that if mutter is running as a Wayland compositor, -- * we start out with no windows. -- */ --#ifdef HAVE_X11_CLIENT -- if (!meta_is_wayland_compositor ()) -- meta_display_manage_all_xwindows (display); -- -- if (old_active_xwindow != None) -- { -- MetaWindow *old_active_window; -- old_active_window = meta_x11_display_lookup_x_window (display->x11_display, -- old_active_xwindow); -- if (old_active_window) -- meta_window_focus (old_active_window, timestamp); -- else -- meta_display_unset_input_focus (display, timestamp); -- } -- else -- { -- meta_display_unset_input_focus (display, timestamp); -- } --#else - meta_display_unset_input_focus (display, timestamp); --#endif - - g_signal_connect (stage, "notify::is-grabbed", - G_CALLBACK (on_is_grabbed_changed), display); -diff --git a/src/x11/meta-x11-display.c b/src/x11/meta-x11-display.c -index c634a71fb2a..599968a363b 100644 ---- a/src/x11/meta-x11-display.c -+++ b/src/x11/meta-x11-display.c -@@ -300,7 +300,32 @@ static void - on_x11_display_opened (MetaX11Display *x11_display, - MetaDisplay *display) - { -+ Window old_active_xwindow = None; -+ -+ if (!meta_is_wayland_compositor ()) -+ { -+ meta_prop_get_window (display->x11_display, -+ display->x11_display->xroot, -+ display->x11_display->atom__NET_ACTIVE_WINDOW, -+ &old_active_xwindow); -+ } -+ - meta_display_manage_all_xwindows (display); -+ -+ if (old_active_xwindow != None) -+ { -+ MetaWindow *old_active_window; -+ -+ old_active_window = meta_x11_display_lookup_x_window (x11_display, -+ old_active_xwindow); -+ if (old_active_window) -+ { -+ uint32_t timestamp; -+ -+ timestamp = display->x11_display->timestamp; -+ meta_window_focus (old_active_window, timestamp); -+ } -+ } - } - - static void --- -GitLab - - -From 668eb0d198dba58c7833b09926dce2f043889155 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Jonas=20=C3=85dahl?= -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 59e460fc336..d95b2460f6e 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 --- -GitLab - - -From 8e6f18fcaf63968b0a75bf65da0c00473d71acb3 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Jonas=20=C3=85dahl?= -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 b16e50e21de..f851f1be372 100644 ---- a/src/core/display.c -+++ b/src/core/display.c -@@ -897,9 +897,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; - -@@ -1018,7 +1018,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 */ --- -GitLab - diff --git a/mutter-implement-text-input-v1.patch b/mutter-implement-text-input-v1.patch index 538d8fe..6db1b1b 100644 --- a/mutter-implement-text-input-v1.patch +++ b/mutter-implement-text-input-v1.patch @@ -1,7 +1,35 @@ -diff --unified --recursive --text --new-file --color mutter-45.3.old/clutter/clutter/clutter-enums.h mutter-45.3.new/clutter/clutter/clutter-enums.h ---- mutter-45.3.old/clutter/clutter/clutter-enums.h 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/clutter/clutter/clutter-enums.h 2024-05-21 16:47:09.832458185 +0800 -@@ -1423,6 +1423,9 @@ +From 2a94e19b00434fe4d7ab858a6cdcff6364f6e408 Mon Sep 17 00:00:00 2001 +From: Alynx Zhou +Date: Wed, 15 May 2024 00:07:41 +0800 +Subject: [PATCH 2/2] wayland/text-input-v1: Implement basic text-input-v1 + support + +This commit makes input methods work in text-input-v1 only clients +(mostly Chromium/Electron based apps with Ozone Wayland), which is +needed by users who needs IME to input their languages, like Chinese, +Japanese or Korean. + +Closes . +--- + clutter/clutter/clutter-enums.h | 3 + + src/core/events.c | 11 +- + src/meson.build | 3 + + src/wayland/meta-wayland-seat.c | 12 +- + src/wayland/meta-wayland-seat.h | 2 + + src/wayland/meta-wayland-text-input-v1.c | 859 +++++++++++++++++++++++ + src/wayland/meta-wayland-text-input-v1.h | 38 + + src/wayland/meta-wayland-versions.h | 1 + + src/wayland/meta-wayland.c | 7 + + src/wayland/meta-wayland.h | 2 + + 10 files changed, 933 insertions(+), 5 deletions(-) + create mode 100644 src/wayland/meta-wayland-text-input-v1.c + create mode 100644 src/wayland/meta-wayland-text-input-v1.h + +Index: mutter-47.beta/clutter/clutter/clutter-enums.h +=================================================================== +--- mutter-47.beta.orig/clutter/clutter/clutter-enums.h ++++ mutter-47.beta/clutter/clutter/clutter-enums.h +@@ -1215,6 +1215,9 @@ typedef enum CLUTTER_INPUT_CONTENT_HINT_SENSITIVE_DATA = 1 << 7, CLUTTER_INPUT_CONTENT_HINT_LATIN = 1 << 8, CLUTTER_INPUT_CONTENT_HINT_MULTILINE = 1 << 9, @@ -11,10 +39,11 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/clutter/clu } ClutterInputContentHintFlags; typedef enum -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/core/events.c mutter-45.3.new/src/core/events.c ---- mutter-45.3.old/src/core/events.c 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/core/events.c 2024-05-21 16:50:33.437595102 +0800 -@@ -241,6 +241,7 @@ +Index: mutter-47.beta/src/core/events.c +=================================================================== +--- mutter-47.beta.orig/src/core/events.c ++++ mutter-47.beta/src/core/events.c +@@ -239,6 +239,7 @@ meta_display_handle_event (MetaDisplay #ifdef HAVE_WAYLAND MetaWaylandCompositor *wayland_compositor; MetaWaylandTextInput *wayland_text_input = NULL; @@ -22,7 +51,7 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/core/ev #endif #ifdef HAVE_WAYLAND -@@ -249,6 +250,8 @@ +@@ -247,6 +248,8 @@ meta_display_handle_event (MetaDisplay { wayland_text_input = meta_wayland_compositor_get_text_input (wayland_compositor); @@ -31,24 +60,26 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/core/ev } #endif -@@ -293,10 +296,10 @@ +@@ -288,9 +291,11 @@ meta_display_handle_event (MetaDisplay } #ifdef HAVE_WAYLAND - if (wayland_text_input && -- !has_grab && -+ if (!has_grab && - !meta_compositor_get_current_window_drag (compositor) && +- !meta_compositor_get_current_window_drag (compositor) && - meta_wayland_text_input_update (wayland_text_input, event)) -+ ((wayland_text_input && meta_wayland_text_input_update (wayland_text_input, event)) || -+ (wayland_text_input_v1 && meta_wayland_text_input_v1_update (wayland_text_input_v1, event)))) - { - bypass_wayland = bypass_clutter = TRUE; - goto out; -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/meson.build mutter-45.3.new/src/meson.build ---- mutter-45.3.old/src/meson.build 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/meson.build 2024-05-21 16:47:09.832458185 +0800 -@@ -692,6 +692,8 @@ ++ if (!meta_compositor_get_current_window_drag (compositor) && ++ ((wayland_text_input && ++ meta_wayland_text_input_update (wayland_text_input, event)) || ++ (wayland_text_input_v1 && ++ meta_wayland_text_input_v1_update (wayland_text_input_v1, event)))) + return CLUTTER_EVENT_STOP; + + if (wayland_compositor) +Index: mutter-47.beta/src/meson.build +=================================================================== +--- mutter-47.beta.orig/src/meson.build ++++ mutter-47.beta/src/meson.build +@@ -694,6 +694,8 @@ if have_wayland 'wayland/meta-wayland-tablet-tool.h', 'wayland/meta-wayland-text-input.c', 'wayland/meta-wayland-text-input.h', @@ -57,61 +88,27 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/meson.b 'wayland/meta-wayland-touch.c', 'wayland/meta-wayland-touch.h', 'wayland/meta-wayland-transaction.c', -@@ -1073,6 +1075,7 @@ +@@ -1102,6 +1104,7 @@ if have_wayland ['single-pixel-buffer', 'staging', 'v1', ], ['tablet', 'unstable', 'v2', ], ['text-input', 'unstable', 'v3', ], + ['text-input', 'unstable', 'v1', ], ['viewporter', 'stable', ], ['xdg-activation', 'staging', 'v1', ], - ['xdg-foreign', 'unstable', 'v1', ], -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland.c mutter-45.3.new/src/wayland/meta-wayland.c ---- mutter-45.3.old/src/wayland/meta-wayland.c 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland.c 2024-05-21 16:47:09.832458185 +0800 -@@ -804,6 +804,7 @@ - meta_wayland_keyboard_shortcuts_inhibit_init (compositor); - meta_wayland_surface_inhibit_shortcuts_dialog_init (); - meta_wayland_text_input_init (compositor); -+ meta_wayland_text_input_v1_init (compositor); - meta_wayland_init_presentation_time (compositor); - meta_wayland_activation_init (compositor); - meta_wayland_transaction_init (compositor); -@@ -970,6 +971,12 @@ + ['xdg-dialog', 'staging', 'v1', ], +Index: mutter-47.beta/src/wayland/meta-wayland-seat.c +=================================================================== +--- mutter-47.beta.orig/src/wayland/meta-wayland-seat.c ++++ mutter-47.beta/src/wayland/meta-wayland-seat.c +@@ -229,6 +229,7 @@ default_focus (MetaWaylandEventHandler * + surface); + meta_wayland_tablet_seat_set_pad_focus (seat->tablet_seat, surface); + meta_wayland_text_input_set_focus (seat->text_input, surface); ++ /* text-input-v1 will set focused surface on activate. */ } - } -+MetaWaylandTextInputV1 * -+meta_wayland_compositor_get_text_input_v1 (MetaWaylandCompositor *compositor) -+{ -+ return compositor->seat->text_input_v1; -+} -+ - static void - on_scheduled_association_unmanaged (MetaWindow *window, - gpointer user_data) -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland.h mutter-45.3.new/src/wayland/meta-wayland.h ---- mutter-45.3.old/src/wayland/meta-wayland.h 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland.h 2024-05-21 16:47:09.832458185 +0800 -@@ -26,6 +26,7 @@ - #include "meta/types.h" - #include "meta/meta-wayland-compositor.h" - #include "wayland/meta-wayland-text-input.h" -+#include "wayland/meta-wayland-text-input-v1.h" - #include "wayland/meta-wayland-types.h" - - META_EXPORT_TEST -@@ -88,6 +89,7 @@ - MetaWindow *window); - - MetaWaylandTextInput * meta_wayland_compositor_get_text_input (MetaWaylandCompositor *compositor); -+MetaWaylandTextInputV1 * meta_wayland_compositor_get_text_input_v1 (MetaWaylandCompositor *compositor); - - #ifdef HAVE_XWAYLAND - void meta_wayland_compositor_notify_surface_id (MetaWaylandCompositor *compositor, -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland-seat.c mutter-45.3.new/src/wayland/meta-wayland-seat.c ---- mutter-45.3.old/src/wayland/meta-wayland-seat.c 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland-seat.c 2024-05-21 16:51:15.168867935 +0800 -@@ -225,6 +225,8 @@ + if (caps & CLUTTER_INPUT_CAPABILITY_TABLET_TOOL) +@@ -290,6 +291,8 @@ meta_wayland_seat_new (MetaWaylandCompos NULL); seat->text_input = meta_wayland_text_input_new (seat); @@ -120,7 +117,7 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland meta_wayland_data_device_init (&seat->data_device, seat); meta_wayland_data_device_primary_init (&seat->primary_data_device, seat); -@@ -264,6 +266,7 @@ +@@ -338,6 +341,7 @@ meta_wayland_seat_free (MetaWaylandSeat g_object_unref (seat->touch); meta_wayland_text_input_destroy (seat->text_input); @@ -128,7 +125,7 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland g_free (seat); } -@@ -371,7 +374,10 @@ +@@ -478,7 +482,10 @@ meta_wayland_seat_handle_event_internal if (event_type == CLUTTER_BUTTON_PRESS || event_type == CLUTTER_TOUCH_BEGIN) { @@ -140,7 +137,7 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland } switch (event_type) -@@ -403,7 +409,8 @@ +@@ -510,7 +517,8 @@ meta_wayland_seat_handle_event_internal case CLUTTER_IM_COMMIT: case CLUTTER_IM_DELETE: case CLUTTER_IM_PREEDIT: @@ -150,18 +147,11 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland return TRUE; break; -@@ -432,6 +439,7 @@ - meta_wayland_tablet_seat_set_pad_focus (tablet_seat, surface); - - meta_wayland_text_input_set_focus (seat->text_input, surface); -+ /* text-input-v1 will set focused surface on activate. */ - } - - gboolean -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland-seat.h mutter-45.3.new/src/wayland/meta-wayland-seat.h ---- mutter-45.3.old/src/wayland/meta-wayland-seat.h 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland-seat.h 2024-05-21 16:47:09.832458185 +0800 -@@ -29,6 +29,7 @@ +Index: mutter-47.beta/src/wayland/meta-wayland-seat.h +=================================================================== +--- mutter-47.beta.orig/src/wayland/meta-wayland-seat.h ++++ mutter-47.beta/src/wayland/meta-wayland-seat.h +@@ -30,6 +30,7 @@ #include "wayland/meta-wayland-pointer.h" #include "wayland/meta-wayland-tablet-tool.h" #include "wayland/meta-wayland-text-input.h" @@ -169,17 +159,18 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland #include "wayland/meta-wayland-touch.h" #include "wayland/meta-wayland-types.h" -@@ -47,6 +48,7 @@ +@@ -49,6 +50,7 @@ struct _MetaWaylandSeat MetaWaylandDataDevicePrimary primary_data_device; MetaWaylandTextInput *text_input; + MetaWaylandTextInputV1 *text_input_v1; - guint capabilities; - }; -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland-text-input-v1.c mutter-45.3.new/src/wayland/meta-wayland-text-input-v1.c ---- mutter-45.3.old/src/wayland/meta-wayland-text-input-v1.c 1970-01-01 08:00:00.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland-text-input-v1.c 2024-05-21 16:47:09.832458185 +0800 + MetaWaylandInput *input_handler; + MetaWaylandEventHandler *default_handler; +Index: mutter-47.beta/src/wayland/meta-wayland-text-input-v1.c +=================================================================== +--- /dev/null ++++ mutter-47.beta/src/wayland/meta-wayland-text-input-v1.c @@ -0,0 +1,859 @@ +/* + * Copyright (C) 2024 SUSE LLC @@ -1040,9 +1031,10 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland + + return retval; +} -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland-text-input-v1.h mutter-45.3.new/src/wayland/meta-wayland-text-input-v1.h ---- mutter-45.3.old/src/wayland/meta-wayland-text-input-v1.h 1970-01-01 08:00:00.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland-text-input-v1.h 2024-05-21 16:47:09.832458185 +0800 +Index: mutter-47.beta/src/wayland/meta-wayland-text-input-v1.h +=================================================================== +--- /dev/null ++++ mutter-47.beta/src/wayland/meta-wayland-text-input-v1.h @@ -0,0 +1,38 @@ +/* + * Copyright (C) 2024 SUSE LLC @@ -1082,9 +1074,10 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland + +gboolean meta_wayland_text_input_v1_handle_event (MetaWaylandTextInputV1 *text_input, + const ClutterEvent *event); -diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland/meta-wayland-versions.h mutter-45.3.new/src/wayland/meta-wayland-versions.h ---- mutter-45.3.old/src/wayland/meta-wayland-versions.h 2024-01-07 07:34:55.000000000 +0800 -+++ mutter-45.3.new/src/wayland/meta-wayland-versions.h 2024-05-21 16:47:09.832458185 +0800 +Index: mutter-47.beta/src/wayland/meta-wayland-versions.h +=================================================================== +--- mutter-47.beta.orig/src/wayland/meta-wayland-versions.h ++++ mutter-47.beta/src/wayland/meta-wayland-versions.h @@ -49,6 +49,7 @@ #define META_ZXDG_OUTPUT_V1_VERSION 3 #define META_ZWP_XWAYLAND_KEYBOARD_GRAB_V1_VERSION 1 @@ -1093,3 +1086,48 @@ diff --unified --recursive --text --new-file --color mutter-45.3.old/src/wayland #define META_WP_VIEWPORTER_VERSION 1 #define META_ZWP_PRIMARY_SELECTION_V1_VERSION 1 #define META_WP_PRESENTATION_VERSION 1 +Index: mutter-47.beta/src/wayland/meta-wayland.c +=================================================================== +--- mutter-47.beta.orig/src/wayland/meta-wayland.c ++++ mutter-47.beta/src/wayland/meta-wayland.c +@@ -869,6 +869,7 @@ meta_wayland_compositor_new (MetaContext + meta_wayland_keyboard_shortcuts_inhibit_init (compositor); + meta_wayland_surface_inhibit_shortcuts_dialog_init (); + meta_wayland_text_input_init (compositor); ++ meta_wayland_text_input_v1_init (compositor); + meta_wayland_init_presentation_time (compositor); + meta_wayland_activation_init (compositor); + meta_wayland_transaction_init (compositor); +@@ -1133,6 +1134,12 @@ meta_wayland_compositor_get_text_input ( + return compositor->seat->text_input; + } + ++MetaWaylandTextInputV1 * ++meta_wayland_compositor_get_text_input_v1 (MetaWaylandCompositor *compositor) ++{ ++ return compositor->seat->text_input_v1; ++} ++ + static void + meta_wayland_compositor_update_focus (MetaWaylandCompositor *compositor, + MetaWindow *window) +Index: mutter-47.beta/src/wayland/meta-wayland.h +=================================================================== +--- mutter-47.beta.orig/src/wayland/meta-wayland.h ++++ mutter-47.beta/src/wayland/meta-wayland.h +@@ -26,6 +26,7 @@ + #include "meta/types.h" + #include "meta/meta-wayland-compositor.h" + #include "wayland/meta-wayland-text-input.h" ++#include "wayland/meta-wayland-text-input-v1.h" + #include "wayland/meta-wayland-types.h" + + META_EXPORT_TEST +@@ -88,6 +89,7 @@ void meta_wayland_com + MetaWindow *window); + + MetaWaylandTextInput * meta_wayland_compositor_get_text_input (MetaWaylandCompositor *compositor); ++MetaWaylandTextInputV1 * meta_wayland_compositor_get_text_input_v1 (MetaWaylandCompositor *compositor); + + #ifdef HAVE_XWAYLAND + void meta_wayland_compositor_notify_surface_id (MetaWaylandCompositor *compositor, diff --git a/mutter-window-actor-Special-case-shaped-Java-windows.patch b/mutter-window-actor-Special-case-shaped-Java-windows.patch index 0642236..8a3ed13 100644 --- a/mutter-window-actor-Special-case-shaped-Java-windows.patch +++ b/mutter-window-actor-Special-case-shaped-Java-windows.patch @@ -1,4 +1,4 @@ -From 9efcc35102b4c41265e93461b35a1193b3d5822d Mon Sep 17 00:00:00 2001 +From b3b5aa01c63aee1df079e0394b0e6372df1838d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Fri, 12 May 2017 13:40:31 +0200 Subject: [PATCH] window-actor: Special-case shaped Java windows @@ -9,15 +9,17 @@ 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 ++++++++ - 1 file changed, 8 insertions(+) + src/x11/window-x11-private.h | 2 ++ + src/x11/window-x11.c | 9 +++++++++ + 3 files changed, 19 insertions(+) -Index: mutter-44.beta/src/compositor/meta-window-actor-x11.c +Index: mutter-47.beta/src/compositor/meta-window-actor-x11.c =================================================================== ---- mutter-44.beta.orig/src/compositor/meta-window-actor-x11.c -+++ mutter-44.beta/src/compositor/meta-window-actor-x11.c -@@ -428,6 +428,14 @@ has_shadow (MetaWindowActorX11 *actor_x1 +--- mutter-47.beta.orig/src/compositor/meta-window-actor-x11.c ++++ mutter-47.beta/src/compositor/meta-window-actor-x11.c +@@ -423,6 +423,14 @@ has_shadow (MetaWindowActorX11 *actor_x1 */ - if (window->has_custom_frame_extents) + if (!meta_window_actor_is_opaque (META_WINDOW_ACTOR (actor_x11))) return FALSE; + + /* @@ -25,8 +27,41 @@ Index: mutter-44.beta/src/compositor/meta-window-actor-x11.c + * shadows; make its compliance tests happy to give it what it wants ... + */ + if (g_strcmp0 (window->res_name, "sun-awt-X11-XWindowPeer") == 0 && -+ window->shape_region != NULL) ++ meta_window_x11_is_shaped (window)) + return FALSE; /* - * Generate shadows for all other windows. + * If a window specifies that it has custom frame extents, that likely +Index: mutter-47.beta/src/x11/window-x11-private.h +=================================================================== +--- mutter-47.beta.orig/src/x11/window-x11-private.h ++++ mutter-47.beta/src/x11/window-x11-private.h +@@ -128,6 +128,8 @@ gboolean meta_window_x11_has_pointer (Me + 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 +Index: mutter-47.beta/src/x11/window-x11.c +=================================================================== +--- mutter-47.beta.orig/src/x11/window-x11.c ++++ mutter-47.beta/src/x11/window-x11.c +@@ -2605,6 +2605,15 @@ meta_window_x11_update_shape_region (Met + 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 diff --git a/mutter.changes b/mutter.changes index 8cbfbba..d59f0e4 100644 --- a/mutter.changes +++ b/mutter.changes @@ -1,19 +1,234 @@ ------------------------------------------------------------------- -Tue Jun 4 08:57:08 UTC 2024 - Alynx Zhou +Sat Oct 19 08:39:02 UTC 2024 - Bjørn Lie -- Add mutter-fix-initial-suspended-state.patch: With Qt 6.7 some - apps cannot shown on launch, this patch fixes the initial - suspended state to make those windows visible - (glgo#GNOME/mutter!3475, bsc#1223393). +- Update to version 47.1: + + gwakeup: Reduce wake-ups to only first item in queue + + x11: Reduce chances XPending does recvmsg() syscall + + Fix grabbing tablet devices + + Fix misplaced windows and random resizes on scaled monitors + + Fix explicit sync with virtual monitors w/o pipewire streams + + Improve detecting preferred primary devices + + Fixed crashes + + Misc. bug fixes and cleanups + + Updated translations. ------------------------------------------------------------------- -Tue May 21 08:26:15 UTC 2024 - Alynx Zhou +Thu Oct 17 17:07:10 UTC 2024 - bjorn.lie@gmail.com + +- Update to version 47.0+24: + * stage-impl: Ensure that a sync object is created in headless mode + * backends/x11: Avoid potential crash in pad_switch_mode + * display: Do not crash attempting to display OSD for unknown + Wacom device + * wayland/drm-lease: Do not add connector twice on lease + disappeared + * wayland/drm-lease: Hold device fd when listing leases + +------------------------------------------------------------------- +Thu Sep 26 18:20:54 UTC 2024 - bjorn.lie@gmail.com + +- Update to version 47.0+19: + * Revert "window/wayland: Use scale for configured rect in + configuration" + * cogl/gles: Don't initialize glGetStringi + * cogl/gl: Don't initialize potentially unused/unsupported + functions + * cogl: Don't _cogl_context_get_gl_extensions before + check_gl_version + * cogl/egl: Restore support for EGL 1.4 + * wayland/tablet-tool: Fix grabbing tablet devices + * cogl/gles: Use unsized internal formats for RGB8, RGBA8 in GLES + 2.0 + * wayland/color-management: Fix SIGSEGV on dispose + * x11: Reduce chances XPending does recvmsg() syscall + * gwakeup: Reduce wake-ups to only first item in queue + * window/x11: Use g_autoslist (MetaStrut) in + meta_window_x11_update_struts + * Updated translations. + +------------------------------------------------------------------- +Mon Sep 16 22:52:32 UTC 2024 - Bjørn Lie + +- Update to version 47.0: + + Fix resizing of electron windows + + Fix using modifiers on multi-GPU setups + + Don't override externally set tablet calibration + + Add experimental support for xdg-session-manager-v1 protocol + + Fixed crashes + + Misc. bug fixes and cleanups + + Updated translations. +- Add gvdb submodule and add as source. + +------------------------------------------------------------------- +Mon Sep 16 21:20:19 UTC 2024 - Dominique Leuenberger + +- Update to version 47.rc+40: + + window/xwayland: Handle arithmetics close to the int limits. + +------------------------------------------------------------------- +Mon Sep 16 20:19:12 UTC 2024 - Michael Gorse + +- Update version requirements to correspond with the source. + +------------------------------------------------------------------- +Mon Sep 16 18:19:54 UTC 2024 - Bjørn Lie + +- Update to version 47.rc (bsc#1223393): + + Add experimental color management protocol support + + Merge Cally into Clutter + + Fix drag and drop between X11 and wayland clients + + Fix drag and drop from grabbing popups + + Fix EGLDevice support + + Improve cursor smoothness under load + + Fix frozen cursor on some hybrid machines + + Fix touch window dragging with pointer lock enabled + + Store the layout mode in monitor config + + Fix keys sometimes getting stuck after using global shortcut + + Fix propagating tablet device removals to clients + + Fix tablet input in maximized windows + + Reduce damage on window movement + + Install mutter tests + + Use libadwaita for server-side decorations on GNOME + + Fix frozen cursor after suspend + + Let scaling-aware Xwayland clients scale themselves + + Add initial PipeWire explicit sync support + + Trace damage reason in sysprof + + Expose new backlight API to gnome-settings-daemon + + Fixed crashes + + Plugged leaks + + Misc. bug fixes and cleanups + + Updated translations. + +------------------------------------------------------------------- +Mon Sep 16 18:17:08 UTC 2024 - Bjørn Lie + +- Update to version 47.beta: + + Fix visibility of Xwayland windows + + Add plumbing for transforming color state + + Build and publish GNOME OS systemd-sysext extensions + + Implement support for tablet tool keybindings and actions + + Add support for tablet tool pressure ranges + + Improve sticky behavior with transient dialogs + + Improve placement and focus logic with always-on-top windows + + Expose Orientationmanager to introspection + + Recover from secondary GPU update failures + + Plugged leaks + + Misc. bug fixes and cleanups. +- Rebase patches with quilt. +- Bump api_major to 15 following upstream changes. + +------------------------------------------------------------------- +Sun Sep 15 12:06:37 UTC 2024 - Bjørn Lie + +- Update to version 45.5: + + Fix drag and drop between X11 and wayland clients + + Fix drag and drop from grabbing popups + + Fix EGLDevice support + + Fix frozen cursor on some hybrid machines + + Fix touch window dragging with pointer lock enabled + + Fix propagating tablet device removals to clients + + Fix tablet input in maximized windows + + Reduce damage on window movement + + Fix frozen cursor after suspend + + Fix using modifiers on multi-GPU setups + + Fixed crashes + + Misc. bug fixes and cleanups + + Updated translations. + +------------------------------------------------------------------- +Fri Aug 9 18:19:48 UTC 2024 - Michael Gorse + +- Fix build if sle_version is defined: Patch3 no longer exists, and + add back Patch4 for SLE builds that was mistakenly removed in + last change. + +------------------------------------------------------------------- +Mon Aug 5 07:02:25 UTC 2024 - Dominique Leuenberger + +- Update to version 46.4: + + Fix nested popovers on wayland. + + Misc. bug fixes and cleanups. + + Updated translations. +- Drop mutter-fix-x11-restart.patch: fixed upstream. + +------------------------------------------------------------------- +Tue Jul 30 19:03:30 UTC 2024 - Michael Gorse + +- Rebase mutter-SLE-relax-some-constraints-on-CSD-windows.patch. + +------------------------------------------------------------------- +Thu Jul 4 05:49:11 UTC 2024 - Bjørn Lie + +- Update to version 46.3.1: + + Fix visibility of Xwayland windows + + Misc. bug fixes + +------------------------------------------------------------------- +Sun Jun 30 08:50:32 UTC 2024 - Bjørn Lie + +- Update to version 46.3: + + Fix performance issues with second virtual monitor + + Fix missing unmap animation of some windows + + Fix placement/resizing regression + + Fix possible out of sync primary selections and clipboard + + Fix ibus support in popups + + Fix hardware accelerated rendering when headless + + Add back support for legacy X11 cursor themes + + Fix preedit offsets + + Use character offsets to specify surrounding text + + Don't force titlebar on screen on all interactive resizes + + Fixed crashes + + Misc. bug fixes and cleanups + + Updated translations. +- Rebase patches with quilt. + +------------------------------------------------------------------- +Mon May 27 07:13:01 UTC 2024 - Dominique Leuenberger + +- Update to version 46.2: + + Fix hardware cursor with non-atomic KMS drivers. + + Fix night light state getting stuck on monitor changes. + + Fix sending preferred buffer transform. + + Fix key press events with immediate release being ignored. + + Fix unsetting clipboard on screen lock. + + Fix wrong input region of undecorated X11 windows. + + Fix windows potentially shrinking unexpectedly on configure. + + Fix popup menus sometimes closing immediately. + + Fixed crashes. + + Misc. bug fixes and cleanups. + + Updated transltions. + +------------------------------------------------------------------- +Fri May 17 03:26:48 UTC 2024 - Alynx Zhou - Add mutter-implement-text-input-v1.patch: This allows input method to work in Chromium/Electron-based apps with Wayland Ozone platform, which only has text-input-v1 support (glgo#GNOME/mutter!3751, bsc#1219505). +------------------------------------------------------------------- +Wed May 1 13:01:02 UTC 2024 - Dominique Leuenberger + +- Update to version 46.1: + + Implement linux-drm-syncobj-v1 (bsc#1219718). + + Fix input lag on X11 nvidia. + + Fix scanout on secondary GPUs. + + Don't apply max-render-time to secondary GPUs. + + Fix reusing single-pixel buffers. + + Improve scanout candidate check. + + Always use logical pixels for. + + Fix modifiers getting stuck during grabs. + + Fix night-light on displays without EDID. + + Fix secondary GPU acceleration with nvidia driver. + + Fix some XWayland clients being partially click-through. + + Fix initial suspended state. + + Fixed crashes. + + Misc. bug fixes and cleanups. + + Updated translations. +- Drop mutter-fix-front-buffer-lock.patch and + 0001-Revert-clutter-stage-Avoid-queueing-stage-updates-wh.patch: + fixed upstream. + ------------------------------------------------------------------- Sun Apr 28 01:22:43 UTC 2024 - Xiaoguang Wang @@ -21,6 +236,135 @@ Sun Apr 28 01:22:43 UTC 2024 - Xiaoguang Wang Reverting commit 261f516a to fix black screen on Xorg when logging in or logging out (glgo#GNOME/mutter#3452 bsc#1222612). +------------------------------------------------------------------- +Mon Apr 8 06:11:23 UTC 2024 - Alynx Zhou + +- Add mutter-fix-front-buffer-lock.patch: Fix front buffer lock + error by an unnecessary ensure_fb_id call + (glgo#gnome/mutter!3674, bsc#1222409). + +------------------------------------------------------------------- +Tue Mar 19 09:30:13 UTC 2024 - Dominique Leuenberger + +- Update to version 46.0: + + Fix duplicate scroll events over libei. + + Fix window menu with mouse button modifier. + + Fix caret offset in accessible event. + + Fix handling of scroll events for mice. + + Use timerfd for clock timing. + + Advertise support for BGRA for all screencast types. + + Add support for preferred_buffer_scale/transform. + + Use memfd to store selection data. + + Fix globally active input focus. + + Call malloc_trim() after loading background image. + + Fix dynamic max render time sometimes getting stuck on constant + framerate. + + Introduce base of new gesture framework. + + Work around windows missing work area changes. + + Fix black screen with some drivers. + + Improve login screen <-> session transition. + + Fixed crashes. + + Misc. bug fixes and cleanups. + + Updated translations. + +------------------------------------------------------------------- +Mon Mar 18 08:01:44 UTC 2024 - Dominique Leuenberger + +- Update to version 46.rc: + + screencast: Renegotiate when DMABUF allocation fails. + + Unify wayland pointer- and keyboard grab mechanisms. + + Add modifier-aware screencasting support. + + Fix synchronization issue on Xorg. + + Send fractional_scale event immediately on window creation. + + wayland/client: Add make_dock() method. + + Fix gray area on top of some X11 fullscreen windows. + + Stick dragged windows to the right anchor point. + + cally/text: Fix emission of `text_caret_moved` signal. + + clutter/text: Fix minimum height calculation. + + Add experimental support for variable refresh rate. + + Expose the minimum refresh rate of monitors through D-Bus. + + Use "default" cursor for moving windows. + + Fixed crashes. + + Misc. bug fixes and cleanups. + + Updated translations. +- Rebase mutter-window-actor-Special-case-shaped-Java-windows.patch + (resync with Fedora). + +------------------------------------------------------------------- +Sun Mar 17 08:00:50 UTC 2024 - Dominique Leuenberger + +- Update to version 46.beta: + + Implement mouse cursor hotspots for KMS atomic. + + Improve project and development documentation. + + Refactor wayland focus management. + + Remove experimental rt-scheduler feature. + + Remove ClutterCanvas. + + Consider reduced blanking with lower pixelclock. + + Fix centering non-modal transients over parent. + + Allow XKB model to be configured. + + Enable KMS deadline timer after a VT switch if it was + inhibited. + + Prepare for variable refresh rate support. + + Restore IM state flushing before handling key events. + + Swap stylus buttons to match traditional order. + + Fix handling of pad ring wrap arounds. + + Support Broadcast RGB/RGB range KMS property. + + Ensure all planes support EGL config format. + + Handle Alt modifier in pad actions. + + Store eraser and stylus tools separately. + + Disambiguate output mapped to tablet with connector name. + + Fix lost keyboard focus after dismissing popups. + + Implement direct scanout for cropped and scaled surfaces. + + Fixed crashes. + + Misc. bug fixes and cleanups. + +------------------------------------------------------------------- +Sat Mar 16 11:42:08 UTC 2024 - Dominique Leuenberger + +- Update to version 46.alpha: + + wayland: Send keyboard modifiers after the enter event. + + wayland/client: Add make_desktop() method. + + Add a target workspace to raise_and_make_recent(). + + clutter: Drop cairo helpers. + + cogl: Port away from CoglObject. + + mtk: Add a Region type. + + Propagate focus appearance to all ancestors. + + Ignore locked modifiers in keybinding machinery. + + Fix disabling check-alive timeout. + + Drop ClutterContainer interface. + + Improve sloppy and mouse focus modes. + + Sync geometry only when window is mapped. + + Improve repick due to transform changes. + + Fix tablets on X11 having the wrong device. + + Disable HW cursor when inhibited by backend. + + screencast: Bring back blitting. + + backends/native: Try 10 bpc formats. + + Fix forcing EGLStream with NVIDIA proprietary driver. + + screencast: Add ability to stop streams. + + Use standard cursor names from CSS specification. + + Avoids over-synchronization due to client reads. + + Add more profiling instrumentation. + + Allow specifyig the layout manager for an actor type. + + Fix handling of relative mode for tablets. + + Dynamically assign hardware planes during configuration. + + Simplify X11 focus management. + + background: Fix background color around image. + + text-input: Use correct offsets in delete_surrounding_text. + + Add wayland shm YCbCr support. + + Set a minimum guessed scale. + + Fix building without native backend. + + Fix occasional artifacts at top of X11 fullscreen windows. + + Add documentation for building, running and debugging. + + Improve tablet pressure curve calculation. + + Fixed crashes. + + Plugged leaks. + + Updated translations. +- Bump api_major to 14 following upstream changes. +- Add pkgconfig(pixman-1) BuildRequires: new dependency. +- Drop pkgconfig(json-glib-1.0) BuildRequires: no longer needed. +- Drop mutter-fix-text-input-delete-surrounding.patch: fixed + upstream. + ------------------------------------------------------------------- Fri Mar 15 07:09:11 UTC 2024 - Alynx Zhou diff --git a/mutter.obsinfo b/mutter.obsinfo index 046fa59..d002fb3 100644 --- a/mutter.obsinfo +++ b/mutter.obsinfo @@ -1,4 +1,4 @@ name: mutter -version: 45.3 -mtime: 1704584095 -commit: 5012d22cb96ba22c4133e2e488ea1f5241fb50e2 +version: 47.1 +mtime: 1729281167 +commit: 7848c15baf2cdad995f9e5dde738072ad43d1b2b diff --git a/mutter.spec b/mutter.spec index 5a8c721..47c8b1b 100644 --- a/mutter.spec +++ b/mutter.spec @@ -18,34 +18,27 @@ %bcond_with profiler -%define api_major 13 +%define api_major 15 %define api_minor 0 %define libmutter libmutter-%{api_major}-%{api_minor} Name: mutter -Version: 45.3 +Version: 47.1 Release: 0 Summary: Window and compositing manager based on Clutter License: GPL-2.0-or-later Group: System/GUI/GNOME URL: https://www.gnome.org Source0: %{name}-%{version}.tar.zst +Source1: gvdb-0.gitmodule.tar.zst # PATCH-FIX-UPSTREAM mutter-disable-cvt-s390x.patch bsc#1158128 fcrozat@suse.com -- Do not search for cvt on s390x, it doesn't exist there Patch1: mutter-disable-cvt-s390x.patch # PATCH-FIX-OPENSUSE mutter-window-actor-Special-case-shaped-Java-windows.patch -- window-actor: Special-case shaped Java windows Patch2: mutter-window-actor-Special-case-shaped-Java-windows.patch -# PATCH-FIX-UPSTREAM mutter-fix-x11-restart.patch glgo#GNOME/gnome-shell#7050 glgo#GNOME/mutter!3329 alynx.zhou@suse.com -- Fix crash on restarting mutter under x11 -Patch3: mutter-fix-x11-restart.patch -# PATCH-FIX-UPSTREAM mutter-fix-text-input-delete-surrounding.patch glgo#GNOME/mutter#2146 glgo#GNOME/mutter!2712 alynx.zhou@suse.com -- Fix delete_surrounding_text of text-input-v3 -Patch4: mutter-fix-text-input-delete-surrounding.patch # PATCH-FIX-OPENSUSE 0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch glgo#GNOME/mutter#3302 bsc#1219546 alynx.zhou@suse.com -- Fix partial update on VT switch -Patch5: 0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch -# PATCH-FIX-UPSTREAM 0001-Revert-clutter-stage-Avoid-queueing-stage-updates-wh.patch glgo#GNOME/mutter#3452 bsc#1222612 xwang@suse.com -- Fix blank screen on Xorg when logging in or logging out -Patch6: 0001-Revert-clutter-stage-Avoid-queueing-stage-updates-wh.patch -# PATCH-FEATURE-OPENSUSE mutter-implement-text-input-v1.patch glgo#GNOME/mutter!3751 bsc#1219505 alynx.zhou@suse.com -- Allow input method to work in Wayland Chromium -Patch7: mutter-implement-text-input-v1.patch -# PATCH-FIX-UPSTREAM mutter-fix-initial-suspended-state.patch glgo#GNOME/mutter!3475 bsc#1223393 alynx.zhou@suse.com -- Fix initial suspended state for some Qt 6.7 window -Patch8: mutter-fix-initial-suspended-state.patch +Patch4: 0001-Revert-clutter-actor-Cache-stage-relative-instead-of.patch +#PATCH-FEATURE-OPENSUSE mutter-implement-text-input-v1.patch glgo#GNOME/mutter!3751 bsc#1219505 alynx.zhou@suse.com -- Allow input method to work in Wayland Chromium +Patch5: mutter-implement-text-input-v1.patch ## SLE-only patches start at 1000 # PATCH-FEATURE-SLE mutter-SLE-bell.patch FATE#316042 bnc#889218 idonmez@suse.com -- make audible bell work out of the box. @@ -58,7 +51,7 @@ BuildRequires: fdupes %ifnarch s390x BuildRequires: (libxcvt if xorg-x11-server > 21) %endif -BuildRequires: meson >= 0.53.0 +BuildRequires: meson >= 1.3.0 BuildRequires: pkgconfig BuildRequires: xorg-x11-server BuildRequires: xvfb-run @@ -66,30 +59,30 @@ BuildRequires: pkgconfig(cairo) >= 1.10.0 BuildRequires: pkgconfig(colord) >= 1.4.5 BuildRequires: pkgconfig(egl) BuildRequires: pkgconfig(fribidi) >= 1.0.0 -BuildRequires: pkgconfig(gbm) >= 17.3 +BuildRequires: pkgconfig(gbm) >= 21.3 BuildRequires: pkgconfig(gio-unix-2.0) >= 2.69.0 BuildRequires: pkgconfig(glesv2) -BuildRequires: pkgconfig(glib-2.0) >= 2.69.0 +BuildRequires: pkgconfig(glib-2.0) >= 2.81.1 BuildRequires: pkgconfig(gnome-desktop-4) BuildRequires: pkgconfig(gnome-settings-daemon) BuildRequires: pkgconfig(gobject-introspection-1.0) >= 0.9.5 BuildRequires: pkgconfig(graphene-gobject-1.0) -BuildRequires: pkgconfig(gsettings-desktop-schemas) >= 3.37.2 +BuildRequires: pkgconfig(gsettings-desktop-schemas) >= 47.beta BuildRequires: pkgconfig(gtk4) BuildRequires: pkgconfig(gudev-1.0) >= 232 -BuildRequires: pkgconfig(json-glib-1.0) >= 0.12.0 BuildRequires: pkgconfig(lcms2) >= 2.6 BuildRequires: pkgconfig(libcanberra-gtk3) >= 0.26 BuildRequires: pkgconfig(libdisplay-info) -BuildRequires: pkgconfig(libdrm) >= 2.4.83 -BuildRequires: pkgconfig(libeis-1.0) -BuildRequires: pkgconfig(libinput) >= 1.15.0 -BuildRequires: pkgconfig(libpipewire-0.3) >= 0.3.21 +BuildRequires: pkgconfig(libdrm) >= 2.4.118 +BuildRequires: pkgconfig(libeis-1.0) >= 1.0.901 +BuildRequires: pkgconfig(libinput) >= 1.26.0 +BuildRequires: pkgconfig(libpipewire-0.3) >= 1.2.0 BuildRequires: pkgconfig(libstartup-notification-1.0) >= 0.7 BuildRequires: pkgconfig(libsystemd) -BuildRequires: pkgconfig(libudev) >= 136 +BuildRequires: pkgconfig(libudev) >= 228 BuildRequires: pkgconfig(libwacom) >= 0.13 -BuildRequires: pkgconfig(pango) >= 1.2.0 +BuildRequires: pkgconfig(pango) >= 1.46.0 +BuildRequires: pkgconfig(pixman-1) >= 0.42 BuildRequires: pkgconfig(sm) %if %{with profiler} BuildRequires: pkgconfig(sysprof-6) @@ -98,8 +91,8 @@ BuildRequires: pkgconfig(sysprof-capture-4) >= 3.37.2 BuildRequires: pkgconfig(udev) BuildRequires: pkgconfig(upower-glib) >= 0.99.0 BuildRequires: pkgconfig(wayland-eglstream) -BuildRequires: pkgconfig(wayland-protocols) >= 1.21 -BuildRequires: pkgconfig(wayland-server) >= 1.13.0 +BuildRequires: pkgconfig(wayland-protocols) >= 1.36 +BuildRequires: pkgconfig(wayland-server) >= 1.23 BuildRequires: pkgconfig(x11) BuildRequires: pkgconfig(x11-xcb) BuildRequires: pkgconfig(xau) @@ -150,17 +143,17 @@ applications that want to make use of the mutter library. %prep %autosetup -N +pushd subprojects +tar xf %{SOURCE1} +mv gvdb-0.gitmodule gvdb +popd %if !0%{?sle_version} %autopatch -p1 -M 999 %else %patch -P 1 -p1 %patch -P 2 -p1 -%patch -P 3 -p1 %patch -P 4 -p1 %patch -P 5 -p1 -%patch -P 6 -p1 -%patch -P 7 -p1 -%patch -P 8 -p1 %endif # SLE-only patches and translations. %if 0%{?sle_version} @@ -174,7 +167,7 @@ applications that want to make use of the mutter library. -Dwayland_eglstream=true \ -Dcogl_tests=false \ -Dclutter_tests=false \ - -Dtests=false \ + -Dtests=disabled \ -Dinstalled_tests=false \ -Dxwayland_initfd=auto \ -Dlibdisplay_info=true \ @@ -210,7 +203,6 @@ applications that want to make use of the mutter library. %{_libdir}/mutter-%{api_major}/plugins/libdefault.so # These typelibs are not split out since they are private to mutter -%{_libdir}/mutter-%{api_major}/Cally-%{api_major}.typelib %{_libdir}/mutter-%{api_major}/Clutter-%{api_major}.typelib %{_libdir}/mutter-%{api_major}/Cogl-%{api_major}.typelib %{_libdir}/mutter-%{api_major}/CoglPango-%{api_major}.typelib @@ -236,7 +228,6 @@ applications that want to make use of the mutter library. %files devel %{_includedir}/mutter-%{api_major}/ %{_libdir}/mutter-%{api_major}/Meta-%{api_major}.gir -%{_libdir}/mutter-%{api_major}/Cally-%{api_major}.gir %{_libdir}/mutter-%{api_major}/Clutter-%{api_major}.gir %{_libdir}/mutter-%{api_major}/Cogl-%{api_major}.gir %{_libdir}/mutter-%{api_major}/CoglPango-%{api_major}.gir