mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
AdisTT: short correction on paste function in edit windows for WeatherParam
This commit is contained in:
1 parent
bc87d6add1
commit
6d58c09104
1 file changed
+6
-4
@@ -139,15 +139,17 @@ class PasteCommand(QUndoCommand):
|
||||
|
||||
self._data = data
|
||||
self._row = row
|
||||
self._wps = wps
|
||||
self._wps = list(wps)
|
||||
self._wps.reverse()
|
||||
|
||||
def undo(self):
|
||||
self._data.delete(self._wps)
|
||||
self._data.delete_i(
|
||||
range(self._row, self._row + len(self._wps))
|
||||
)
|
||||
|
||||
def redo(self):
|
||||
for bc in self._wps:
|
||||
self._data.insert(self._row, bc)
|
||||
for wp in self._wps:
|
||||
self._data.insert(self._row, wp)
|
||||
|
||||
|
||||
class DuplicateCommand(QUndoCommand):
|
||||
|
||||
Reference in new issue
Block a user