mirror of
https://github.com/X11Libre/xserver.git
synced 2026-10-15 00:13:28 +00:00
dix: Add IsFloating(device) wrapper.
Simplifies check for floating devices. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Benjamin Tissoires <tissoire@cena.fr>
This commit is contained in:
parent
77af45ebc3
commit
703baece7e
2 changed files with 8 additions and 0 deletions
|
|
@ -328,6 +328,13 @@ IsMaster(DeviceIntPtr dev)
|
|||
return dev->type == MASTER_POINTER || dev->type == MASTER_KEYBOARD;
|
||||
}
|
||||
|
||||
Bool
|
||||
IsFloating(DeviceIntPtr dev)
|
||||
{
|
||||
return GetMaster(dev, MASTER_KEYBOARD) == NULL;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Max event opcode.
|
||||
*/
|
||||
|
|
|
|||
Loading…
Reference in a new issue