mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-13 00:03:09 -04:00
[processing] correctly handle editable and non-editable fixed tables (fix #11602)
This commit is contained in:
parent
4c24666c87
commit
5e6f4c2fae
@ -58,7 +58,7 @@ class FixedTableDialog(QDialog, Ui_DlgFixedTable):
|
||||
self.btnRemove.clicked.connect(lambda: self.removeRows())
|
||||
self.btnRemoveAll.clicked.connect(lambda: self.removeRows(True))
|
||||
|
||||
if self.param.fixedNumOfRows:
|
||||
if not self.param.fixedNumOfRows:
|
||||
self.btnAdd.setEnabled(False)
|
||||
self.btnRemove.setEnabled(False)
|
||||
self.btnRemoveAll.setEnabled(False)
|
||||
@ -106,5 +106,5 @@ class FixedTableDialog(QDialog, Ui_DlgFixedTable):
|
||||
self.tblView.setUpdatesEnabled(True)
|
||||
|
||||
def addRow(self):
|
||||
items = [QStandardItem('') for i in xrange(self.tblView.model().columnCount())]
|
||||
items = [QStandardItem('0') for i in xrange(self.tblView.model().columnCount())]
|
||||
self.tblView.model().appendRow(items)
|
||||
|
Loading…
x
Reference in New Issue
Block a user