From e25c9937c7550a33b2b55ee16776dc64e4c09a40 Mon Sep 17 00:00:00 2001 From: Tim Bentley Date: Fri, 2 Oct 2009 15:19:36 +0100 Subject: [PATCH] Update UI --- openlp/core/ui/plugindialoglistform.py | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/openlp/core/ui/plugindialoglistform.py b/openlp/core/ui/plugindialoglistform.py index b9a27b632..5826578f9 100644 --- a/openlp/core/ui/plugindialoglistform.py +++ b/openlp/core/ui/plugindialoglistform.py @@ -89,18 +89,22 @@ class PluginForm(QtGui.QDialog): item2 = QtGui.QTableWidgetItem(plugin.version) item2.setTextAlignment(QtCore.Qt.AlignVCenter) item2.setFlags(QtCore.Qt.ItemIsSelectable) - if plugin.status == PluginStatus.Active: - item3 = QtGui.QTableWidgetItem( - translate(u'PluginForm', u'Active')) - else: - item3 = QtGui.QTableWidgetItem( - translate(u'PluginForm', u'Inactive')) - item3.setTextAlignment(QtCore.Qt.AlignVCenter) - item3.setFlags(QtCore.Qt.ItemIsSelectable) self.PluginViewList.setItem(row, 0, item1) self.PluginViewList.setItem(row, 1, item2) - self.PluginViewList.setItem(row, 2, item3) - self.PluginViewList.setRowHeight(row, 15) + if plugin.can_be_disabled(): + combo = QtGui.QComboBox() + self.PluginViewList.setCellWidget(row, 2, combo) + combo.addItem(translate(u'PluginForm', u'Active')) + combo.addItem(translate(u'PluginForm', u'Inactive')) +# if plugin.status == PluginStatus.Active: + self.PluginViewList.setRowHeight(row, 25) + else: + item3 = QtGui.QTableWidgetItem( + translate(u'PluginForm', u'Active')) + item3.setTextAlignment(QtCore.Qt.AlignVCenter) + item3.setFlags(QtCore.Qt.ItemIsSelectable) + self.PluginViewList.setItem(row, 2, item3) + self.PluginViewList.setRowHeight(row, 15) def displayAbout(self, item): if item is None: