diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2012-03-12 16:36:31 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2012-03-22 13:12:56 +1000 |
commit | d645edd11e7482f98c8b7e0d6c8693285c484907 (patch) | |
tree | a70bc2534b0f26f64a580cfd7f7fa630eb9383bc /Xext/syncsrv.h | |
parent | 6aef209ebc2e54f5465da505a780f7b4cc273ee0 (diff) |
Xext: Add per-device SyncCounters
Previously, we only had one idle alarm that was triggered for all devices,
whenever the user used any device, came back from suspend, etc.
Add system SyncCounters for each device (named "DEVICEIDLETIME x", with x
being the device id) that trigger on that device only. This allows for
enabling/disabling devices based on interaction with other devices.
Popular use-case: disable the touchpad when the keyboard just above the
touchpad stops being idle.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
Reviewed-by: Jamey Sharp <jamey@minilop.net>
Reviewed-by: James Jones <jajones@nvidia.com>
Diffstat (limited to 'Xext/syncsrv.h')
-rw-r--r-- | Xext/syncsrv.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Xext/syncsrv.h b/Xext/syncsrv.h index d29c361cc..dbed476f2 100644 --- a/Xext/syncsrv.h +++ b/Xext/syncsrv.h @@ -135,4 +135,7 @@ extern void SyncChangeCounter(SyncCounter *pCounter, extern void SyncDestroySystemCounter(pointer pCounter); extern void SyncExtensionInit(void); + +extern SyncCounter *SyncInitDeviceIdleTime(DeviceIntPtr dev); +extern void SyncRemoveDeviceIdleTime(SyncCounter *counter); #endif /* _SYNCSRV_H_ */ |