-
-
Notifications
You must be signed in to change notification settings - Fork 169
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1615 make it possible to disable touchpad or pointer uinput virtual …
…devices via env var git-svn-id: https://xpra.org/svn/Xpra/trunk@18928 3bb7dfac-3a0b-4e04-842a-767bc560f471
- Loading branch information
Showing
1 changed file
with
6 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,12 @@ | ||
# This file is part of Xpra. | ||
# Copyright (C) 2017 Antoine Martin <[email protected]> | ||
# Copyright (C) 2017-2018 Antoine Martin <[email protected]> | ||
# Xpra is released under the terms of the GNU GPL v2, or, at your option, any | ||
# later version. See the file COPYING for details. | ||
|
||
import sys | ||
import os.path | ||
|
||
from xpra.util import envbool | ||
from xpra.os_util import OSX, POSIX, shellsub, getuid, getgid, get_util_logger, osexpand | ||
from xpra.platform.dotxpra import norm_makepath | ||
from xpra.scripts.config import InitException | ||
|
@@ -342,6 +343,8 @@ def create_uinput_device(uuid, uid, events, name): | |
return name, device, dev_path | ||
|
||
def create_uinput_pointer_device(uuid, uid): | ||
if not envbool("XPRA_UINPUT_POINTER", True): | ||
return | ||
import uinput | ||
events = ( | ||
uinput.REL_X, | ||
|
@@ -361,6 +364,8 @@ def create_uinput_pointer_device(uuid, uid): | |
return create_uinput_device(uuid, uid, events, name) | ||
|
||
def create_uinput_touchpad_device(uuid, uid): | ||
if not envbool("XPRA_UINPUT_TOUCHPAD", True): | ||
return | ||
import uinput | ||
events = ( | ||
uinput.BTN_TOUCH, | ||
|