mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
Network: Minor change.
This commit is contained in:
1 parent
ddf5941288
commit
a7945eea9a
1 file changed
+2
-6
@@ -127,12 +127,10 @@ class GraphTableModel(QAbstractTableModel):
|
||||
return self.rows[index.row()][self.headers[index.column()]]
|
||||
|
||||
def headerData(self, section, orientation, role):
|
||||
if role == Qt.ItemDataRole.DisplayRole and orientation == Qt.Orientation.Horizontal:
|
||||
if (role == Qt.ItemDataRole.DisplayRole and
|
||||
orientation == Qt.Orientation.Horizontal):
|
||||
return self.headers[section].capitalize()
|
||||
|
||||
# if role == Qt.ItemDataRole.DisplayRole and orientation == Qt.Orientation.Vertical:
|
||||
# return section
|
||||
|
||||
return QVariant()
|
||||
|
||||
@pyqtSlot()
|
||||
@@ -150,7 +148,6 @@ class GraphTableModel(QAbstractTableModel):
|
||||
node
|
||||
)
|
||||
)
|
||||
# self.rows[index.row()][self.headers[index.column()]] = node
|
||||
elif self.headers[index.column()] == "enable":
|
||||
self._undo.push(
|
||||
EnableEdgeCommand(
|
||||
@@ -165,7 +162,6 @@ class GraphTableModel(QAbstractTableModel):
|
||||
value
|
||||
)
|
||||
)
|
||||
# self.rows[index.row()][self.headers[index.column()]] = value
|
||||
|
||||
self.dataChanged.emit(index, index, [Qt.DisplayRole])
|
||||
self.layoutChanged.emit()
|
||||
|
||||
Reference in new issue
Block a user