diff options
author | Simon Rettberg | 2018-08-31 14:49:01 +0200 |
---|---|---|
committer | Simon Rettberg | 2018-08-31 14:49:01 +0200 |
commit | 9657258945b63ab3dd16ec124563cd80b7bc3ac6 (patch) | |
tree | bc934fd4782d1a0fd9f6c53bfa8421335e7c69f0 /sample_configuration | |
parent | [server] Fix snap to grid for call with ignored frame param (diff) | |
download | pvs2-9657258945b63ab3dd16ec124563cd80b7bc3ac6.tar.gz pvs2-9657258945b63ab3dd16ec124563cd80b7bc3ac6.tar.xz pvs2-9657258945b63ab3dd16ec124563cd80b7bc3ac6.zip |
[pvs2] Disable/Enable X input devices in parallel
On some machines, locking is painfully slow for reasons unknown.
Try to make it a little better.
Diffstat (limited to 'sample_configuration')
-rwxr-xr-x | sample_configuration/kb-lock.sh | 4 | ||||
-rwxr-xr-x | sample_configuration/kb-unlock.sh | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/sample_configuration/kb-lock.sh b/sample_configuration/kb-lock.sh index 36a84c8..27db6da 100755 --- a/sample_configuration/kb-lock.sh +++ b/sample_configuration/kb-lock.sh @@ -6,5 +6,7 @@ keyboards=$(xinput --list | grep -E "slave.*(keyboard|pointer)" | cut -f2 | cut for id in $keyboards; do echo "disabling device #$id" - xinput --set-prop $id "Device Enabled" 0 + xinput --set-prop $id "Device Enabled" 0 & done + +wait diff --git a/sample_configuration/kb-unlock.sh b/sample_configuration/kb-unlock.sh index 09dc270..c123414 100755 --- a/sample_configuration/kb-unlock.sh +++ b/sample_configuration/kb-unlock.sh @@ -5,5 +5,8 @@ keyboards=$(xinput --list | grep -E "slave.*(keyboard|pointer)" | cut -f2 | cut for id in $keyboards; do echo "enabling device #$id" - xinput --set-prop $id "Device Enabled" 1 + xinput --set-prop $id "Device Enabled" 1 & done + +wait + |