mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
pep8: Some modifications to respect pep8 standard code.
This commit is contained in:
1 parent
8544dd1144
commit
fa2454d079
152 files changed
+1626
-1277
No files matched your search
@@ -45,6 +45,7 @@ from View.LateralContribution.Edit.Plot import Plot
|
||||
|
||||
_translate = QCoreApplication.translate
|
||||
|
||||
|
||||
class EditLateralContributionWindow(PamhyrWindow):
|
||||
_pamhyr_ui = "EditLateralContribution"
|
||||
_pamhyr_name = "Edit lateral contribution"
|
||||
@@ -67,11 +68,11 @@ class EditLateralContributionWindow(PamhyrWindow):
|
||||
)
|
||||
|
||||
super(EditLateralContributionWindow, self).__init__(
|
||||
title = name,
|
||||
study = study,
|
||||
config = config,
|
||||
trad = trad,
|
||||
parent = parent
|
||||
title=name,
|
||||
study=study,
|
||||
config=config,
|
||||
trad=trad,
|
||||
parent=parent
|
||||
)
|
||||
|
||||
self.setup_table()
|
||||
@@ -80,9 +81,9 @@ class EditLateralContributionWindow(PamhyrWindow):
|
||||
|
||||
def setup_table(self):
|
||||
self._delegate_time = PamhyrExTimeDelegate(
|
||||
data = self._data,
|
||||
mode = self._study.time_system,
|
||||
parent = self
|
||||
data=self._data,
|
||||
mode=self._study.time_system,
|
||||
parent=self
|
||||
)
|
||||
|
||||
headers = {}
|
||||
@@ -92,16 +93,16 @@ class EditLateralContributionWindow(PamhyrWindow):
|
||||
|
||||
table = self.find(QTableView, "tableView")
|
||||
self._table = TableModel(
|
||||
table_view = table,
|
||||
table_headers = headers,
|
||||
editable_headers = self._data.header,
|
||||
delegates = {
|
||||
table_view=table,
|
||||
table_headers=headers,
|
||||
editable_headers=self._data.header,
|
||||
delegates={
|
||||
"time": self._delegate_time,
|
||||
},
|
||||
data = self._data,
|
||||
undo = self._undo_stack,
|
||||
trad = self._trad,
|
||||
opt_data = self._study.time_system
|
||||
data=self._data,
|
||||
undo=self._undo_stack,
|
||||
trad=self._trad,
|
||||
opt_data=self._study.time_system
|
||||
)
|
||||
|
||||
table.setModel(self._table)
|
||||
@@ -119,12 +120,12 @@ class EditLateralContributionWindow(PamhyrWindow):
|
||||
self.verticalLayout.addWidget(self.canvas)
|
||||
|
||||
self.plot = Plot(
|
||||
canvas = self.canvas,
|
||||
data = self._data,
|
||||
mode = self._study.time_system,
|
||||
toolbar = self.toolbar,
|
||||
trad = self._trad,
|
||||
parent = self
|
||||
canvas=self.canvas,
|
||||
data=self._data,
|
||||
mode=self._study.time_system,
|
||||
toolbar=self.toolbar,
|
||||
trad=self._trad,
|
||||
parent=self
|
||||
)
|
||||
self.plot.draw()
|
||||
|
||||
@@ -156,7 +157,6 @@ class EditLateralContributionWindow(PamhyrWindow):
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
def add(self):
|
||||
rows = self.index_selected_rows()
|
||||
if len(self._data) == 0 or len(rows) == 0:
|
||||
|
||||
Reference in new issue
Block a user