mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Clear caches on book load
This commit is contained in:
parent
390c83bf3d
commit
07d5f721d4
@ -372,6 +372,7 @@ class EbookViewer(MainWindow):
|
|||||||
|
|
||||||
def load_finished(self, ok, data):
|
def load_finished(self, ok, data):
|
||||||
open_at, self.pending_open_at = self.pending_open_at, None
|
open_at, self.pending_open_at = self.pending_open_at, None
|
||||||
|
self.web_view.clear_caches()
|
||||||
if not ok:
|
if not ok:
|
||||||
self.setWindowTitle(self.base_window_title)
|
self.setWindowTitle(self.base_window_title)
|
||||||
tb = data['tb'].strip()
|
tb = data['tb'].strip()
|
||||||
|
@ -607,6 +607,9 @@ class WebView(RestartingWebEngineView):
|
|||||||
def clear_history(self):
|
def clear_history(self):
|
||||||
self._page.history().clear()
|
self._page.history().clear()
|
||||||
|
|
||||||
|
def clear_caches(self):
|
||||||
|
self._page.profile().clearHttpCache()
|
||||||
|
|
||||||
def trigger_shortcut(self, which):
|
def trigger_shortcut(self, which):
|
||||||
self.execute_when_ready('trigger_shortcut', which)
|
self.execute_when_ready('trigger_shortcut', which)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user