[mutter/wip/carlosg/drop-device-idle-monitors: 3/4] core: Do not update idle times for slave devices
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/carlosg/drop-device-idle-monitors: 3/4] core: Do not update idle times for slave devices
- Date: Wed, 12 Feb 2020 22:08:25 +0000 (UTC)
commit f7646af8100291249a18b6c735a5145684815413
Author: Carlos Garnacho <carlosg gnome org>
Date: Wed Feb 5 16:42:26 2020 +0100
core: Do not update idle times for slave devices
Those go nowhere, so just avoid doing this.
https://gitlab.gnome.org/GNOME/mutter/merge_requests/1039
src/core/events.c | 16 ++--------------
1 file changed, 2 insertions(+), 14 deletions(-)
---
diff --git a/src/core/events.c b/src/core/events.c
index 6b57f4f5f..eedb04a01 100644
--- a/src/core/events.c
+++ b/src/core/events.c
@@ -101,11 +101,9 @@ get_window_for_event (MetaDisplay *display,
static void
handle_idletime_for_event (const ClutterEvent *event)
{
- ClutterInputDevice *device, *source_device;
- MetaIdleMonitor *core_monitor, *device_monitor;
+ MetaIdleMonitor *core_monitor;
- device = clutter_event_get_device (event);
- if (device == NULL)
+ if (clutter_event_get_device (event) == NULL)
return;
if (event->any.flags & CLUTTER_EVENT_FLAG_SYNTHETIC ||
@@ -118,17 +116,7 @@ handle_idletime_for_event (const ClutterEvent *event)
return;
core_monitor = meta_idle_monitor_get_core ();
- device_monitor = meta_idle_monitor_get_for_device (device);
-
meta_idle_monitor_reset_idletime (core_monitor);
- meta_idle_monitor_reset_idletime (device_monitor);
-
- source_device = clutter_event_get_source_device (event);
- if (source_device != device)
- {
- device_monitor = meta_idle_monitor_get_for_device (source_device);
- meta_idle_monitor_reset_idletime (device_monitor);
- }
}
static gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]