Continued porting the web browser. QtWebEngine

Mon, 29 Feb 2016 19:43:46 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Mon, 29 Feb 2016 19:43:46 +0100
branch
QtWebEngine
changeset 4791
a1e53a9ffcf3
parent 4790
deeea3d64858
child 4792
f55fa7eb3cf3

Continued porting the web browser.

- changed reload to reload bypassing cache

WebBrowser/WebBrowserView.py file | annotate | diff | comparison | revisions
WebBrowser/WebBrowserWindow.py file | annotate | diff | comparison | revisions
--- a/WebBrowser/WebBrowserView.py	Mon Feb 29 19:30:13 2016 +0100
+++ b/WebBrowser/WebBrowserView.py	Mon Feb 29 19:43:46 2016 +0100
@@ -287,7 +287,6 @@
             name.setUrl(Preferences.getWebBrowser("DefaultScheme") +
                         name.toString())
         
-        # TODO: move some of this to web page
         if len(name.scheme()) == 1 or \
            name.scheme() == "file":
             # name is a local file
@@ -394,6 +393,12 @@
         """
         self.triggerPageAction(QWebEnginePage.Reload)
     
+    def reloadBypassingCache(self):
+        """
+        Public slot to reload the current page bypassing the cache.
+        """
+        self.triggerPageAction(QWebEnginePage.ReloadAndBypassCache)
+    
     def copy(self):
         """
         Public slot to copy the selected text.
--- a/WebBrowser/WebBrowserWindow.py	Mon Feb 29 19:30:13 2016 +0100
+++ b/WebBrowser/WebBrowserWindow.py	Mon Feb 29 19:43:46 2016 +0100
@@ -671,7 +671,7 @@
                 bookmarksManager.exportBookmarks)
         self.__actions.append(self.exportBookmarksAct)
         
-        # TODO: print stuff
+        # TODO: Print
 ##        self.printAct = E5Action(
 ##            self.tr('Print'),
 ##            UI.PixmapCache.getIcon("print.png"),
@@ -834,7 +834,6 @@
         if not self.__initShortcutsOnly:
             self.reloadAct.triggered.connect(self.__reload)
         self.__actions.append(self.reloadAct)
-        # TODO: add 'Reload bypassing cache' or use that for above
         
         self.stopAct = E5Action(
             self.tr('Stop'),
@@ -2568,7 +2567,8 @@
         """
         Private slot called to handle the reload action.
         """
-        self.currentBrowser().reload()
+##        self.currentBrowser().reload()
+        self.currentBrowser().reloadBypassingCache()
     
     def __stopLoading(self):
         """

eric ide

mercurial