View Single Post
Old 12-15-2020, 08:50 AM   #13
thiago.eec
Wizard
thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.thiago.eec ought to be getting tired of karma fortunes by now.
 
Posts: 1,233
Karma: 1419583
Join Date: Dec 2016
Location: Goiânia - Brazil
Device: iPad, Kindle Paperwhite, Kindle Oasis
Quote:
Originally Posted by kovidgoyal View Post
The canonical way to refresh the GUI after adding books, is the way calibre does it itself, which is:

Code:
self.gui.iactions['Add Books'].refresh_gui(num_of_books_added)
Thanks!

But this raised another question for me. When I use the refresh_ids method (with current_row argument), the last added book gets selected and everything is refreshed for that book (including Quick View, by using qv.refresh_quickview(current)).

But when I use the canonical way, after all books are added, the current book is still the same as before the adding action. Also, Quick View does not update*, even if a new book that affects it was added).

* To refresh it, I have to click on another book and then go back to the previously selected book.
thiago.eec is offline   Reply With Quote