mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Also activate parent window when clicking in the category view
This commit is contained in:
parent
6c8f462778
commit
d6fd1f8293
@ -732,6 +732,7 @@ class CharSelect(Dialog):
|
||||
|
||||
self.category_view = CategoryView(self)
|
||||
self.category_view.setFocusPolicy(Qt.FocusPolicy.NoFocus)
|
||||
self.category_view.clicked.connect(self.category_view_clicked)
|
||||
l.addWidget(s, 1, 0, 1, 3)
|
||||
self.char_view = CharView(self)
|
||||
self.char_view.setFocusPolicy(Qt.FocusPolicy.NoFocus)
|
||||
@ -760,6 +761,11 @@ class CharSelect(Dialog):
|
||||
l.addLayout(h, 4, 0, 1, 3)
|
||||
self.char_view.setFocus(Qt.FocusReason.OtherFocusReason)
|
||||
|
||||
def category_view_clicked(self):
|
||||
p = self.parent()
|
||||
if p is not None and p.focusWidget() is not None:
|
||||
p.activateWindow()
|
||||
|
||||
def do_search(self):
|
||||
text = str(self.search.text()).strip()
|
||||
if not text:
|
||||
|
Loading…
x
Reference in New Issue
Block a user