mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Book details panel: While clicking tags/authors/etc. holding down the Ctrl+Shift modifier keys now add the tag to the current search with
"AND" instead of "OR" when using only Ctrl. Fixes #1943521 [Ctrl-clicking on tag browser & book details ignores "match all items."](https://bugs.launchpad.net/calibre/+bug/1943521)
This commit is contained in:
parent
752aaab533
commit
27b06b16b1
@ -1031,8 +1031,9 @@ class BookDetails(QWidget): # {{{
|
||||
|
||||
def search_term(field, val):
|
||||
append = ''
|
||||
if QApplication.instance().keyboardModifiers() & Qt.KeyboardModifier.ControlModifier:
|
||||
append = 'OR'
|
||||
mods = QApplication.instance().keyboardModifiers()
|
||||
if mods & Qt.KeyboardModifier.ControlModifier:
|
||||
append = 'AND' if mods & Qt.KeyboardModifier.ShiftModifier else 'OR'
|
||||
|
||||
self.search_requested.emit(
|
||||
'{}:"={}"'.format(field, val.replace('"', '\\"')),
|
||||
|
Loading…
x
Reference in New Issue
Block a user