[mutter/wip/rstrode/rhel-8.0.0: 82/117] cursor-tracker: Emit `cursor-changed` after renderer was updated
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/rstrode/rhel-8.0.0: 82/117] cursor-tracker: Emit `cursor-changed` after renderer was updated
- Date: Sun, 17 Feb 2019 17:29:43 +0000 (UTC)
commit ffa30f50f265f0b114e7d644efd4ee1bd0fe96bc
Author: Jonas Ã…dahl <jadahl gmail com>
Date: Thu Jan 3 16:40:42 2019 +0100
cursor-tracker: Emit `cursor-changed` after renderer was updated
Otherwise the cursor retrieved via meta_cursor_renderer_get_cursor() is
out of date.
https://gitlab.gnome.org/GNOME/mutter/merge_requests/357
src/backends/meta-cursor-tracker.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/src/backends/meta-cursor-tracker.c b/src/backends/meta-cursor-tracker.c
index 060b6af3b..97e7f8cb4 100644
--- a/src/backends/meta-cursor-tracker.c
+++ b/src/backends/meta-cursor-tracker.c
@@ -118,11 +118,15 @@ change_cursor_renderer (MetaCursorTracker *tracker)
static void
sync_cursor (MetaCursorTracker *tracker)
{
- if (update_displayed_cursor (tracker))
- g_signal_emit (tracker, signals[CURSOR_CHANGED], 0);
+ gboolean cursor_changed = FALSE;
+
+ cursor_changed = update_displayed_cursor (tracker);
if (update_effective_cursor (tracker))
change_cursor_renderer (tracker);
+
+ if (cursor_changed)
+ g_signal_emit (tracker, signals[CURSOR_CHANGED], 0);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]