From 480aeee9de869176b2c093d65d0571fc457ef7bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Pierret=20=28fepitre=29?= Date: Sun, 30 Aug 2020 23:27:17 +0200 Subject: [PATCH] gui: trigger services start for ps2 devices --- qubes/ext/gui.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/qubes/ext/gui.py b/qubes/ext/gui.py index 3dab8ceb..b6de4a4d 100644 --- a/qubes/ext/gui.py +++ b/qubes/ext/gui.py @@ -21,6 +21,7 @@ # License along with this library; if not, see . # +import asyncio import qubes.config import qubes.ext import qubes.exc @@ -110,12 +111,16 @@ class GUI(qubes.ext.Extension): oldvalue=oldvalue) @qubes.ext.handler('domain-start') + @asyncio.coroutine def on_domain_start(self, vm, event, **kwargs): attached_vms = [domain for domain in self.attached_vms(vm) if domain.is_running()] for attached_vm in attached_vms: attached_vm.untrusted_qdb.write('/qubes-gui-domain-xid', str(vm.xid)) + if vm.features.get('input-proxy-ps2', None) == '1': + yield from asyncio.create_subprocess_exec( + '/usr/bin/qubes-input-trigger-ps2') @qubes.ext.handler('property-reset:keyboard_layout') def on_keyboard_reset(self, vm, event, name, oldvalue=None):