mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
LCS Complete
This commit is contained in:
1 parent
510bee115b
commit
02c597d109
11 files changed
+157
-261
No files matched your search
@@ -45,13 +45,13 @@ class SetDataCommand(QUndoCommand):
|
||||
if self._column == 0:
|
||||
self._data._data[self._index] = (self._old,self._data._data[self._index][1])
|
||||
else:
|
||||
self._data._data[self._index] = (self._data._data[self._index][1], self._old)
|
||||
self._data._data[self._index] = (self._data._data[self._index][0], self._old)
|
||||
|
||||
def redo(self):
|
||||
if self._column == 0:
|
||||
self._data._data[self._index] = (self._new,self._data._data[self._index][1])
|
||||
else:
|
||||
self._data._data[self._index] = (self._data._data[self._index][1], self._new)
|
||||
self._data._data[self._index] = (self._data._data[self._index][0], self._new)
|
||||
|
||||
class AddCommand(QUndoCommand):
|
||||
def __init__(self, data, index):
|
||||
@@ -84,7 +84,7 @@ class DelCommand(QUndoCommand):
|
||||
|
||||
def undo(self):
|
||||
for row, el in self._bc:
|
||||
self._data.insert(row, el)
|
||||
self._data._data.insert(row, el)
|
||||
|
||||
def redo(self):
|
||||
for row in self._rows:
|
||||
|
||||
Reference in new issue
Block a user