diff --git a/qubesdbus/domain.py b/qubesdbus/domain.py index b898e41..afd6da9 100644 --- a/qubesdbus/domain.py +++ b/qubesdbus/domain.py @@ -1,4 +1,4 @@ -# -*- encoding: utf8 -*- +# -*- encoding: utf-8 -*- # pylint: disable=invalid-name # # The Qubes OS Project, https://www.qubes-os.org/ diff --git a/qubesdbus/domain_manager.py b/qubesdbus/domain_manager.py index b59b5a2..fc4f91f 100644 --- a/qubesdbus/domain_manager.py +++ b/qubesdbus/domain_manager.py @@ -1,4 +1,4 @@ -# -*- encoding: utf8 -*- +# -*- coding: utf-8 -*- # pylint: disable=invalid-name # # The Qubes OS Project, https://www.qubes-os.org/ diff --git a/qubesdbus/proxy.py b/qubesdbus/proxy.py index 0742875..d1ba4b6 100644 --- a/qubesdbus/proxy.py +++ b/qubesdbus/proxy.py @@ -1,3 +1,4 @@ +# -*- encoding: utf-8 -*- # # The Qubes OS Project, https://www.qubes-os.org/ # @@ -101,6 +102,9 @@ def forward_vm_event(self, vm, event, *args, **kwargs): log.error('Could not add vm via to dbus DomainManager') log.info('Added VM %s', data) self.new_vm.remove(vm) + elif event in ('domain-spawn', 'domain-pre-shutdown'): + proxy = vm_proxy(vm.qid) + property_set(proxy, 'state', 'Transient') elif event == 'domain-start': proxy = vm_proxy(vm.qid) property_set(proxy, 'state', 'Running')