add copy/paste in pollutant BC + debug

This commit is contained in:
Theophile Terraz committed 2025-02-17 09:43:02 +01:00
1 parent e3315c8f81
commit 4b976d3b5f
6 files changed
+98 -2

No files matched your search

@@ -200,6 +200,22 @@ class EditBoundaryConditionWindow(PamhyrWindow):
self.copyTableIntoClipboard(table)
def _paste(self):
header, data = self.parseClipboardTable()
logger.debug(f"paste: h:{header}, d:{data}")
if len(data) == 0:
return
row = 0
rows = self.index_selected_rows()
if len(rows) != 0:
row = rows[0]
self._table.paste(row, header, data)
self.plot.update()
def _undo(self):
self._table.undo()
self.plot.update()