Fix main()
This commit is contained in:
parent
f1f80556dc
commit
be39ec86f9
@ -24,6 +24,7 @@ from . import ui_bootfromdevice # pylint: disable=no-name-in-module
|
|||||||
from PyQt5 import QtWidgets, QtGui # pylint: disable=import-error
|
from PyQt5 import QtWidgets, QtGui # pylint: disable=import-error
|
||||||
from qubesadmin import tools
|
from qubesadmin import tools
|
||||||
from qubesadmin import exc
|
from qubesadmin import exc
|
||||||
|
from qubesadmin.tools import qvm_start
|
||||||
|
|
||||||
|
|
||||||
class VMBootFromDeviceWindow(ui_bootfromdevice.Ui_BootDialog,
|
class VMBootFromDeviceWindow(ui_bootfromdevice.Ui_BootDialog,
|
||||||
@ -168,8 +169,8 @@ def main(args=None):
|
|||||||
args = parser.parse_args(args)
|
args = parser.parse_args(args)
|
||||||
vm = args.domains.pop()
|
vm = args.domains.pop()
|
||||||
|
|
||||||
utils.run_synchronous(functools.partial(VMBootFromDeviceWindow, vm))
|
window = utils.run_synchronous(functools.partial(VMBootFromDeviceWindow, vm))
|
||||||
|
qvm_start.main(['--cdrom', window.cdrom_location, vm.name])
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
|
@ -564,3 +564,5 @@ def run_synchronous(window_class):
|
|||||||
|
|
||||||
qt_app.exec_()
|
qt_app.exec_()
|
||||||
qt_app.exit()
|
qt_app.exit()
|
||||||
|
|
||||||
|
return window
|
||||||
|
Loading…
Reference in New Issue
Block a user