mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-09 05:12:35 +02:00
Preserve the set of selected books in the library view when a device is connected
This commit is contained in:
parent
90bec1f133
commit
f86b414c47
1 changed files with 6 additions and 5 deletions
|
|
@ -850,15 +850,16 @@ def metadata_downloaded(self, job):
|
|||
self.refresh_ondevice()
|
||||
device_signals.device_metadata_available.emit()
|
||||
|
||||
def refresh_ondevice(self, reset_only = False):
|
||||
def refresh_ondevice(self, reset_only=False):
|
||||
'''
|
||||
Force the library view to refresh, taking into consideration new
|
||||
device books information
|
||||
'''
|
||||
self.book_on_device(None, reset=True)
|
||||
if reset_only:
|
||||
return
|
||||
self.library_view.model().refresh_ondevice()
|
||||
with self.library_view.preserve_selected_books:
|
||||
self.book_on_device(None, reset=True)
|
||||
if reset_only:
|
||||
return
|
||||
self.library_view.model().refresh_ondevice()
|
||||
|
||||
# }}}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue