From 131f08139165c8e6701a7330ae7b3b2e71cf590b Mon Sep 17 00:00:00 2001 From: Eddy Pedroni Date: Sat, 1 Jan 2022 15:49:23 +0100 Subject: Fixed Qt interface problems --- solo_tool_qt.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'solo_tool_qt.py') diff --git a/solo_tool_qt.py b/solo_tool_qt.py index bca71d0..8edd886 100644 --- a/solo_tool_qt.py +++ b/solo_tool_qt.py @@ -30,11 +30,11 @@ class ABListModel(QAbstractListModel): def data(self, index, role): if role == Qt.DisplayRole: - ab = self.soloTool.getAbLimits()[index.row()] + ab = self.soloTool.getStoredAbLimits()[index.row()] return f"{ab[0]} - {ab[1]}" def rowCount(self, index): - return len(self.soloTool.getAbLimits()) + return len(self.soloTool.getStoredAbLimits()) class MainWindow(QMainWindow, Ui_MainWindow): def __init__(self, *args, **kwargs): @@ -145,7 +145,7 @@ class MainWindow(QMainWindow, Ui_MainWindow): def abListSelectionChanged(self, i): if i is not None and not i.isEmpty(): index = i.indexes()[0].row() - ab = self.soloTool.getAbLimits()[index] + ab = self.soloTool.getStoredAbLimits()[index] self.soloTool.loadAbLimits(index) self.aSlider.setValue(int(ab[0] * POSITION_FACTOR)) self.bSlider.setValue(int(ab[1] * POSITION_FACTOR)) -- cgit v1.2.3