QTableWidget items not editable any more
This commit is contained in:
parent
f98107d0ed
commit
0a03903b1d
@ -170,7 +170,7 @@ class VmLabelWidget(VmIconWidget):
|
|||||||
class VmNameItem (QTableWidgetItem):
|
class VmNameItem (QTableWidgetItem):
|
||||||
def __init__(self, vm):
|
def __init__(self, vm):
|
||||||
super(VmNameItem, self).__init__()
|
super(VmNameItem, self).__init__()
|
||||||
|
self.setFlags(Qt.ItemIsSelectable|Qt.ItemIsEnabled)
|
||||||
self.setText(vm.name)
|
self.setText(vm.name)
|
||||||
self.setTextAlignment(Qt.AlignVCenter)
|
self.setTextAlignment(Qt.AlignVCenter)
|
||||||
self.qid = vm.qid
|
self.qid = vm.qid
|
||||||
@ -259,7 +259,8 @@ class VmInfoWidget (QWidget):
|
|||||||
class VmTemplateItem (QTableWidgetItem):
|
class VmTemplateItem (QTableWidgetItem):
|
||||||
def __init__(self, vm):
|
def __init__(self, vm):
|
||||||
super(VmTemplateItem, self).__init__()
|
super(VmTemplateItem, self).__init__()
|
||||||
|
self.setFlags(Qt.ItemIsSelectable|Qt.ItemIsEnabled)
|
||||||
|
|
||||||
if vm.template is not None:
|
if vm.template is not None:
|
||||||
self.setText(vm.template.name)
|
self.setText(vm.template.name)
|
||||||
else:
|
else:
|
||||||
@ -285,6 +286,7 @@ class VmTemplateItem (QTableWidgetItem):
|
|||||||
class VmNetvmItem (QTableWidgetItem):
|
class VmNetvmItem (QTableWidgetItem):
|
||||||
def __init__(self, vm):
|
def __init__(self, vm):
|
||||||
super(VmNetvmItem, self).__init__()
|
super(VmNetvmItem, self).__init__()
|
||||||
|
self.setFlags(Qt.ItemIsSelectable|Qt.ItemIsEnabled)
|
||||||
|
|
||||||
if vm.is_netvm() and not vm.is_proxyvm():
|
if vm.is_netvm() and not vm.is_proxyvm():
|
||||||
self.setText("n/a")
|
self.setText("n/a")
|
||||||
@ -535,6 +537,7 @@ class VmUpdateInfoWidget(QWidget):
|
|||||||
class VmSizeOnDiskItem (QTableWidgetItem):
|
class VmSizeOnDiskItem (QTableWidgetItem):
|
||||||
def __init__(self, vm):
|
def __init__(self, vm):
|
||||||
super(VmSizeOnDiskItem, self).__init__()
|
super(VmSizeOnDiskItem, self).__init__()
|
||||||
|
self.setFlags(Qt.ItemIsSelectable|Qt.ItemIsEnabled)
|
||||||
|
|
||||||
self.vm = vm
|
self.vm = vm
|
||||||
self.value = 0
|
self.value = 0
|
||||||
|
Loading…
Reference in New Issue
Block a user