mirror of
https://github.com/ankitects/anki.git
synced 2025-09-20 06:52:21 -04:00
Clicking the expander icon should not trigger click event
Expander icon does not change currentIndex
This commit is contained in:
parent
c3b0589bb4
commit
38ae2f2b06
1 changed files with 2 additions and 1 deletions
|
@ -443,7 +443,8 @@ class SidebarTreeView(QTreeView):
|
|||
super().mouseReleaseEvent(event)
|
||||
if event.button() == Qt.LeftButton:
|
||||
idx = self.indexAt(event.pos())
|
||||
self._on_click_index(idx)
|
||||
if idx == self.currentIndex():
|
||||
self._on_click_index(idx)
|
||||
|
||||
def keyPressEvent(self, event: QKeyEvent) -> None:
|
||||
if event.key() in (Qt.Key_Return, Qt.Key_Enter):
|
||||
|
|
Loading…
Reference in a new issue