mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
5cd4b3930f
commit
a59f657a69
@ -88,7 +88,7 @@ class SearchBox2(QComboBox): # {{{
|
||||
c.activated[str].connect(self.history_selected)
|
||||
|
||||
self.line_edit.key_pressed.connect(self.key_pressed, type=Qt.DirectConnection)
|
||||
self.activated.connect(self.history_selected)
|
||||
self.activated[str].connect(self.history_selected)
|
||||
self.setEditable(True)
|
||||
self.as_you_type = True
|
||||
self.timer = QTimer()
|
||||
@ -226,7 +226,7 @@ class SearchBox2(QComboBox): # {{{
|
||||
|
||||
def set_search_string(self, txt, store_in_history=False, emit_changed=True):
|
||||
if not store_in_history:
|
||||
self.activated.disconnect()
|
||||
self.activated[str].disconnect()
|
||||
try:
|
||||
self.setFocus(Qt.OtherFocusReason)
|
||||
if not txt:
|
||||
@ -245,7 +245,7 @@ class SearchBox2(QComboBox): # {{{
|
||||
self.focus_to_library.emit()
|
||||
finally:
|
||||
if not store_in_history:
|
||||
self.activated.connect(self.history_selected)
|
||||
self.activated[str].connect(self.history_selected)
|
||||
|
||||
def search_as_you_type(self, enabled):
|
||||
self.as_you_type = enabled
|
||||
|
Loading…
x
Reference in New Issue
Block a user