Fix very unlikely case when user right clicks the VM in the exact moment he
deletes it.
This commit is contained in:
parent
cb5bc16948
commit
b8cb0f625b
@ -1219,6 +1219,7 @@ class VmManagerWindow(ui_qubemanager.Ui_VmManagerWindow, QtGui.QMainWindow):
|
||||
|
||||
@QtCore.pyqtSlot('const QPoint&')
|
||||
def open_context_menu(self, point):
|
||||
try:
|
||||
vm = self.get_selected_vm()
|
||||
|
||||
# logs menu
|
||||
@ -1244,6 +1245,8 @@ class VmManagerWindow(ui_qubemanager.Ui_VmManagerWindow, QtGui.QMainWindow):
|
||||
|
||||
self.logs_menu.setEnabled(not menu_empty)
|
||||
self.context_menu.exec_(self.table.mapToGlobal(point))
|
||||
except exc.QubesPropertyAccessError:
|
||||
pass
|
||||
|
||||
@QtCore.pyqtSlot('QAction *')
|
||||
def show_log(self, action):
|
||||
|
Loading…
Reference in New Issue
Block a user