diff --git a/qt/aqt/profiles.py b/qt/aqt/profiles.py index 8c5ee1018..50bc6a3a6 100644 --- a/qt/aqt/profiles.py +++ b/qt/aqt/profiles.py @@ -668,9 +668,6 @@ create table if not exists profiles def set_recording_driver(self, driver: RecordingDriver) -> None: self.profile["recordingDriver"] = driver.value - def sidebar_left_click_modifiers(self) -> bool: - return self.profile.get("sidebarLeftClick", False) - ###################################################################### def apply_profile_options(self) -> None: diff --git a/qt/aqt/sidebar.py b/qt/aqt/sidebar.py index e3ddb63e1..331019f8d 100644 --- a/qt/aqt/sidebar.py +++ b/qt/aqt/sidebar.py @@ -315,10 +315,9 @@ class SidebarTreeView(QTreeView): self.setHeaderHidden(True) self.setIndentation(15) self.setAutoExpandDelay(600) - if not self.mw.pm.sidebar_left_click_modifiers(): - # pylint: disable=no-member - mode = QAbstractItemView.SelectionMode.ExtendedSelection # type: ignore - self.setSelectionMode(mode) + # pylint: disable=no-member + mode = QAbstractItemView.SelectionMode.ExtendedSelection # type: ignore + self.setSelectionMode(mode) self.setDragDropMode(QAbstractItemView.InternalMove) self.setDragDropOverwriteMode(False) @@ -434,10 +433,7 @@ class SidebarTreeView(QTreeView): def mouseReleaseEvent(self, event: QMouseEvent) -> None: super().mouseReleaseEvent(event) if event.button() == Qt.LeftButton: - if ( - not self._keyboard_modified_pressed() - or self.mw.pm.sidebar_left_click_modifiers() - ): + if not self._keyboard_modified_pressed(): self._on_click_current() elif event.button() == Qt.RightButton: if self._keyboard_modified_pressed():