Continued porting the web browser. QtWebEngine

Wed, 16 Mar 2016 19:51:00 +0100

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Wed, 16 Mar 2016 19:51:00 +0100
branch
QtWebEngine
changeset 4863
9d86824898e1
parent 4862
210f6ea6b9c3
child 4864
00a215a67f25

Continued porting the web browser.

- refactored the JavaScript bridge stuff

WebBrowser/JavaScript/ExternalJsObject.py file | annotate | diff | comparison | revisions
WebBrowser/JavaScript/PasswordManagerJsObject.py file | annotate | diff | comparison | revisions
WebBrowser/JavaScript/StartPageJsObject.py file | annotate | diff | comparison | revisions
WebBrowser/Tools/Scripts.py file | annotate | diff | comparison | revisions
WebBrowser/data/html/startPage.html file | annotate | diff | comparison | revisions
WebBrowser/data/html_rc.py file | annotate | diff | comparison | revisions
eric6.e4p file | annotate | diff | comparison | revisions
--- a/WebBrowser/JavaScript/ExternalJsObject.py	Wed Mar 16 19:08:48 2016 +0100
+++ b/WebBrowser/JavaScript/ExternalJsObject.py	Wed Mar 16 19:51:00 2016 +0100
@@ -15,10 +15,13 @@
 
 from __future__ import unicode_literals
 
-from PyQt5.QtCore import pyqtSlot, QObject, QUrl, QByteArray
+from PyQt5.QtCore import pyqtSlot, pyqtProperty, QObject, QUrl
 
 import WebBrowser.WebBrowserWindow
 
+from .StartPageJsObject import StartPageJsObject
+from .PasswordManagerJsObject import PasswordManagerJsObject
+
 
 class ExternalJsObject(QObject):
     """
@@ -34,6 +37,9 @@
         super(ExternalJsObject, self).__init__(page)
         
         self.__page = page
+        
+        self.__startPage = None
+        self.__passwordManager = None
     
     def page(self):
         """
@@ -44,7 +50,21 @@
         """
         return self.__page
     
-    @pyqtSlot(result=QObject)
+    @pyqtProperty(QObject, constant=True)
+    def passwordManager(self):
+        """
+        Public method to get a reference to the password manager JavaScript
+        object.
+        
+        @return reference to the password manager JavaScript object
+        @rtype StartPageJsObject
+        """
+        if self.__passwordManager is None:
+            self.__passwordManager = PasswordManagerJsObject(self)
+        
+        return self.__passwordManager
+    
+    @pyqtProperty(QObject, constant=True)
     def speedDial(self):
         """
         Public method returning a reference to a speed dial object.
@@ -59,55 +79,15 @@
 ##        return WebBrowser.WebBrowserWindow.WebBrowserWindow.speedDial()
         return None
     
-    @pyqtSlot(str)
-    def AddSearchProvider(self, engineUrl):
-        """
-        Public slot to add a search provider.
-        
-        @param engineUrl engineUrl of the XML file defining the search provider
-        @type str
-        """
-        WebBrowser.WebBrowserWindow.WebBrowserWindow.openSearchManager()\
-        .addEngine(QUrl(engineUrl))
-    
-    @pyqtSlot(str, str, str, QByteArray)
-    def formSubmitted(self, urlStr, userName, password, data):
-        """
-        Public slot passing form data to the password manager.
-        
-        @param urlStr form submission URL
-        @type str
-        @param userName name of the user
-        @type str
-        @param password user password
-        @type str
-        @param data data to be submitted
-        @type QByteArray
+    @pyqtProperty(QObject, constant=True)
+    def startPage(self):
         """
-        import WebBrowser.WebBrowserWindow
-        WebBrowser.WebBrowserWindow.WebBrowserWindow.passwordManager()\
-        .formSubmitted(urlStr, userName, password, data,
-                       self.page())
-    
-    @pyqtSlot(result=str)
-    def providerString(self):
-        """
-        Public method to get a string for the search provider.
+        Public method to get a reference to the start page JavaScript object.
         
-        @return string for the search provider (string)
+        @return reference to the start page JavaScript object
+        @rtype StartPageJsObject
         """
-        return (self.tr("Search results provided by {0}")
-            .format(self.__page.view().mainWindow().openSearchManager()
-            .currentEngineName()))
-    
-    @pyqtSlot(str, result=str)
-    def searchUrl(self, searchStr):
-        """
-        Public method to get the search URL for the given search term.
+        if self.__startPage is None:
+            self.__startPage = StartPageJsObject(self)
         
-        @param searchStr search term (string)
-        @return search URL (string)
-        """
-        return bytes(
-            self.__page.view().mainWindow().openSearchManager().currentEngine()
-            .searchUrl(searchStr).toEncoded()).decode()
+        return self.__startPage
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/WebBrowser/JavaScript/PasswordManagerJsObject.py	Wed Mar 16 19:51:00 2016 +0100
@@ -0,0 +1,46 @@
+# -*- coding: utf-8 -*-
+
+# Copyright (c) 2016 Detlev Offenbach <detlev@die-offenbachs.de>
+#
+
+"""
+Module implementing the Python side for calling the password manager.
+"""
+
+from __future__ import unicode_literals
+
+from PyQt5.QtCore import pyqtSlot, QObject, QByteArray
+
+
+class PasswordManagerJsObject(QObject):
+    """
+    Class implementing the Python side for calling the password manager.
+    """
+    def __init__(self, parent=None):
+        """
+        Constructor
+        
+        @param parent reference to the parent object
+        @type ExternalJsObject
+        """
+        super(PasswordManagerJsObject, self).__init__(parent)
+        
+        self.__external = parent
+    
+    @pyqtSlot(str, str, str, QByteArray)
+    def formSubmitted(self, urlStr, userName, password, data):
+        """
+        Public slot passing form data to the password manager.
+        
+        @param urlStr form submission URL
+        @type str
+        @param userName name of the user
+        @type str
+        @param password user password
+        @type str
+        @param data data to be submitted
+        @type QByteArray
+        """
+        from WebBrowser.WebBrowserWindow import WebBrowserWindow
+        WebBrowserWindow.passwordManager().formSubmitted(
+            urlStr, userName, password, data, self.__external.page())
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/WebBrowser/JavaScript/StartPageJsObject.py	Wed Mar 16 19:51:00 2016 +0100
@@ -0,0 +1,51 @@
+# -*- coding: utf-8 -*-
+
+# Copyright (c) 2016 Detlev Offenbach <detlev@die-offenbachs.de>
+#
+
+"""
+Module implementing the Python side of the eric home page.
+"""
+
+from __future__ import unicode_literals
+
+from PyQt5.QtCore import pyqtSlot, QObject
+
+
+class StartPageJsObject(QObject):
+    """
+    Class implementing the Python side of the eric home page.
+    """
+    def __init__(self, parent=None):
+        """
+        Constructor
+        
+        @param parent reference to the parent object
+        @type ExternalJsObject
+        """
+        super(StartPageJsObject, self).__init__(parent)
+        
+        self.__external = parent
+    
+    @pyqtSlot(result=str)
+    def providerString(self):
+        """
+        Public method to get a string for the search provider.
+        
+        @return string for the search provider (string)
+        """
+        return (self.tr("Search results provided by {0}")
+            .format(self.__external.page().view().mainWindow()
+            .openSearchManager().currentEngineName()))
+    
+    @pyqtSlot(str, result=str)
+    def searchUrl(self, searchStr):
+        """
+        Public method to get the search URL for the given search term.
+        
+        @param searchStr search term (string)
+        @return search URL (string)
+        """
+        return bytes(
+            self.__external.page().view().mainWindow().openSearchManager()
+            .currentEngine().searchUrl(searchStr).toEncoded()).decode()
--- a/WebBrowser/Tools/Scripts.py	Wed Mar 16 19:08:48 2016 +0100
+++ b/WebBrowser/Tools/Scripts.py	Wed Mar 16 19:51:00 2016 +0100
@@ -320,7 +320,8 @@
                     data = data.substring(0, data.length - 1);
                     var url = window.location.href;
                     var username = findUsername(inputs);
-                    external.formSubmitted(url, username, password, data);
+                    external.passwordManager.formSubmitted(
+                        url, username, password, data);
                 }, true);
             }
             
--- a/WebBrowser/data/html/startPage.html	Wed Mar 16 19:08:48 2016 +0100
+++ b/WebBrowser/data/html/startPage.html	Wed Mar 16 19:51:00 2016 +0100
@@ -82,7 +82,7 @@
     <script type="text/javascript">
         function update()
         {
-            window.external.providerString(function(provider) {
+            external.startPage.providerString(function(provider) {
                 document.getElementById('footer').innerHTML = 
                     provider
                     + ' | <a href="http://eric-ide.python-projects.org/">'
@@ -107,7 +107,7 @@
             if (string.length == 0)
                 return;
 
-            window.external.searchUrl(string, function(url) {
+            external.startPage.searchUrl(string, function(url) {
                 window.location.href = url;
             });
         }
--- a/WebBrowser/data/html_rc.py	Wed Mar 16 19:08:48 2016 +0100
+++ b/WebBrowser/data/html_rc.py	Wed Mar 16 19:51:00 2016 +0100
@@ -9,7 +9,7 @@
 from PyQt5 import QtCore
 
 qt_resource_data = b"\
-\x00\x00\x0c\x81\
+\x00\x00\x0c\x87\
 \x3c\
 \x21\x44\x4f\x43\x54\x59\x50\x45\x20\x68\x74\x6d\x6c\x3e\x0a\x3c\
 \x68\x74\x6d\x6c\x3e\x0a\x3c\x68\x65\x61\x64\x3e\x0a\x3c\x6d\x65\
@@ -106,112 +106,112 @@
 \x73\x63\x72\x69\x70\x74\x22\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\
 \x20\x66\x75\x6e\x63\x74\x69\x6f\x6e\x20\x75\x70\x64\x61\x74\x65\
 \x28\x29\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x7b\x0a\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x77\x69\x6e\x64\x6f\x77\x2e\
-\x65\x78\x74\x65\x72\x6e\x61\x6c\x2e\x70\x72\x6f\x76\x69\x64\x65\
-\x72\x53\x74\x72\x69\x6e\x67\x28\x66\x75\x6e\x63\x74\x69\x6f\x6e\
-\x28\x70\x72\x6f\x76\x69\x64\x65\x72\x29\x20\x7b\x0a\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x64\x6f\x63\
-\x75\x6d\x65\x6e\x74\x2e\x67\x65\x74\x45\x6c\x65\x6d\x65\x6e\x74\
-\x42\x79\x49\x64\x28\x27\x66\x6f\x6f\x74\x65\x72\x27\x29\x2e\x69\
-\x6e\x6e\x65\x72\x48\x54\x4d\x4c\x20\x3d\x20\x0a\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x65\x78\x74\x65\x72\x6e\x61\
+\x6c\x2e\x73\x74\x61\x72\x74\x50\x61\x67\x65\x2e\x70\x72\x6f\x76\
+\x69\x64\x65\x72\x53\x74\x72\x69\x6e\x67\x28\x66\x75\x6e\x63\x74\
+\x69\x6f\x6e\x28\x70\x72\x6f\x76\x69\x64\x65\x72\x29\x20\x7b\x0a\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\x67\x65\x74\x45\x6c\x65\x6d\
+\x65\x6e\x74\x42\x79\x49\x64\x28\x27\x66\x6f\x6f\x74\x65\x72\x27\
+\x29\x2e\x69\x6e\x6e\x65\x72\x48\x54\x4d\x4c\x20\x3d\x20\x0a\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x20\x70\x72\x6f\x76\x69\x64\x65\x72\x0a\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x2b\x20\x27\x20\x7c\x20\x3c\x61\x20\x68\x72\x65\x66\x3d\x22\x68\
+\x74\x74\x70\x3a\x2f\x2f\x65\x72\x69\x63\x2d\x69\x64\x65\x2e\x70\
+\x79\x74\x68\x6f\x6e\x2d\x70\x72\x6f\x6a\x65\x63\x74\x73\x2e\x6f\
+\x72\x67\x2f\x22\x3e\x27\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2b\x20\x27\x40\x45\
+\x52\x49\x43\x5f\x4c\x49\x4e\x4b\x40\x3c\x2f\x61\x3e\x27\x3b\x0a\
 \x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
-\x70\x72\x6f\x76\x69\x64\x65\x72\x0a\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2b\x20\x27\
-\x20\x7c\x20\x3c\x61\x20\x68\x72\x65\x66\x3d\x22\x68\x74\x74\x70\
-\x3a\x2f\x2f\x65\x72\x69\x63\x2d\x69\x64\x65\x2e\x70\x79\x74\x68\
-\x6f\x6e\x2d\x70\x72\x6f\x6a\x65\x63\x74\x73\x2e\x6f\x72\x67\x2f\
-\x22\x3e\x27\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x2b\x20\x27\x40\x45\x52\x49\x43\
-\x5f\x4c\x49\x4e\x4b\x40\x3c\x2f\x61\x3e\x27\x3b\x0a\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x64\x6f\x63\
-\x75\x6d\x65\x6e\x74\x2e\x67\x65\x74\x45\x6c\x65\x6d\x65\x6e\x74\
-\x42\x79\x49\x64\x28\x27\x6c\x69\x6e\x65\x45\x64\x69\x74\x27\x29\
-\x2e\x70\x6c\x61\x63\x65\x68\x6f\x6c\x64\x65\x72\x20\x3d\x20\x70\
-\x72\x6f\x76\x69\x64\x65\x72\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x7d\x29\x3b\x0a\x0a\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x2f\x2f\x20\x54\x72\x79\x20\x74\x6f\x20\
-\x63\x68\x61\x6e\x67\x65\x20\x74\x68\x65\x20\x64\x69\x72\x65\x63\
-\x74\x69\x6f\x6e\x20\x6f\x66\x20\x74\x68\x65\x20\x70\x61\x67\x65\
-\x3a\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x76\
-\x61\x72\x20\x6e\x65\x77\x44\x69\x72\x20\x3d\x20\x27\x40\x51\x54\
-\x5f\x4c\x41\x59\x4f\x55\x54\x5f\x44\x49\x52\x45\x43\x54\x49\x4f\
-\x4e\x40\x27\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x6e\x65\x77\x44\x69\x72\x20\x3d\x20\x6e\x65\x77\x44\x69\x72\
-\x2e\x74\x6f\x4c\x6f\x77\x65\x72\x43\x61\x73\x65\x28\x29\x3b\x0a\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x69\x66\x20\x28\
-\x28\x6e\x65\x77\x44\x69\x72\x20\x21\x3d\x20\x27\x6c\x74\x72\x27\
-\x29\x20\x26\x26\x20\x28\x6e\x65\x77\x44\x69\x72\x20\x21\x3d\x20\
-\x27\x72\x74\x6c\x27\x29\x29\x0a\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x6e\x65\x77\x44\x69\x72\x20\x3d\
-\x20\x27\x6c\x74\x72\x27\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\x67\x65\x74\
-\x45\x6c\x65\x6d\x65\x6e\x74\x73\x42\x79\x54\x61\x67\x4e\x61\x6d\
-\x65\x28\x27\x62\x6f\x64\x79\x27\x29\x5b\x30\x5d\x2e\x73\x65\x74\
-\x41\x74\x74\x72\x69\x62\x75\x74\x65\x28\x0a\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x27\x64\x69\x72\x27\
-\x2c\x20\x6e\x65\x77\x44\x69\x72\x29\x3b\x0a\x20\x20\x20\x20\x20\
-\x20\x20\x20\x7d\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x66\x75\
-\x6e\x63\x74\x69\x6f\x6e\x20\x66\x6f\x72\x6d\x53\x75\x62\x6d\x69\
-\x74\x74\x65\x64\x28\x29\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x7b\
-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x76\x61\x72\
-\x20\x73\x74\x72\x69\x6e\x67\x20\x3d\x20\x6c\x69\x6e\x65\x45\x64\
-\x69\x74\x2e\x76\x61\x6c\x75\x65\x3b\x0a\x0a\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x69\x66\x20\x28\x73\x74\x72\x69\x6e\
-\x67\x2e\x6c\x65\x6e\x67\x74\x68\x20\x3d\x3d\x20\x30\x29\x0a\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x72\
-\x65\x74\x75\x72\x6e\x3b\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x77\x69\x6e\x64\x6f\x77\x2e\x65\x78\x74\x65\x72\
-\x6e\x61\x6c\x2e\x73\x65\x61\x72\x63\x68\x55\x72\x6c\x28\x73\x74\
-\x72\x69\x6e\x67\x2c\x20\x66\x75\x6e\x63\x74\x69\x6f\x6e\x28\x75\
-\x72\x6c\x29\x20\x7b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x77\x69\x6e\x64\x6f\x77\x2e\x6c\x6f\x63\
-\x61\x74\x69\x6f\x6e\x2e\x68\x72\x65\x66\x20\x3d\x20\x75\x72\x6c\
-\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x7d\x29\
-\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x7d\x0a\x20\x20\x20\x20\
-\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x2f\x2f\x20\
-\x49\x6e\x69\x74\x69\x61\x6c\x69\x7a\x65\x0a\x20\x20\x20\x20\x20\
-\x20\x20\x20\x69\x66\x20\x28\x77\x69\x6e\x64\x6f\x77\x2e\x65\x78\
-\x74\x65\x72\x6e\x61\x6c\x29\x20\x7b\x0a\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x75\x70\x64\x61\x74\x65\x28\x29\x3b\x0a\
-\x20\x20\x20\x20\x20\x20\x20\x20\x7d\x20\x65\x6c\x73\x65\x20\x7b\
-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x64\x6f\x63\
-\x75\x6d\x65\x6e\x74\x2e\x61\x64\x64\x45\x76\x65\x6e\x74\x4c\x69\
-\x73\x74\x65\x6e\x65\x72\x28\x27\x5f\x65\x72\x69\x63\x5f\x65\x78\
-\x74\x65\x72\x6e\x61\x6c\x5f\x63\x72\x65\x61\x74\x65\x64\x27\x2c\
-\x20\x75\x70\x64\x61\x74\x65\x29\x3b\x0a\x20\x20\x20\x20\x20\x20\
-\x20\x20\x7d\x0a\x20\x20\x20\x20\x3c\x2f\x73\x63\x72\x69\x70\x74\
-\x3e\x0a\x3c\x2f\x68\x65\x61\x64\x3e\x0a\x3c\x62\x6f\x64\x79\x20\
-\x6f\x6e\x6c\x6f\x61\x64\x3d\x22\x64\x6f\x63\x75\x6d\x65\x6e\x74\
-\x2e\x66\x6f\x72\x6d\x73\x5b\x30\x5d\x2e\x6c\x69\x6e\x65\x45\x64\
-\x69\x74\x2e\x73\x65\x6c\x65\x63\x74\x28\x29\x3b\x22\x3e\x0a\x20\
-\x20\x20\x20\x3c\x64\x69\x76\x20\x69\x64\x3d\x22\x68\x65\x61\x64\
-\x65\x72\x22\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x68\x31\
-\x3e\x40\x48\x45\x41\x44\x45\x52\x5f\x54\x49\x54\x4c\x45\x40\x3c\
-\x2f\x68\x31\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x69\x6d\
-\x67\x20\x73\x72\x63\x3d\x22\x40\x49\x4d\x41\x47\x45\x40\x22\x20\
-\x77\x69\x64\x74\x68\x3d\x22\x33\x32\x22\x20\x68\x65\x69\x67\x68\
-\x74\x3d\x22\x33\x32\x22\x2f\x3e\x0a\x20\x20\x20\x20\x3c\x2f\x64\
-\x69\x76\x3e\x0a\x20\x20\x20\x20\x3c\x64\x69\x76\x20\x69\x64\x3d\
-\x22\x73\x65\x61\x72\x63\x68\x22\x3e\x0a\x20\x20\x20\x20\x20\x20\
-\x20\x20\x3c\x66\x6f\x72\x6d\x20\x61\x63\x74\x69\x6f\x6e\x3d\x22\
-\x6a\x61\x76\x61\x73\x63\x72\x69\x70\x74\x3a\x66\x6f\x72\x6d\x53\
-\x75\x62\x6d\x69\x74\x74\x65\x64\x28\x29\x3b\x22\x3e\x0a\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x66\x69\x65\x6c\x64\
-\x73\x65\x74\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x3c\x69\x6e\x70\x75\x74\x20\x69\x64\x3d\x22\
-\x6c\x69\x6e\x65\x45\x64\x69\x74\x22\x20\x6e\x61\x6d\x65\x3d\x22\
-\x6c\x69\x6e\x65\x45\x64\x69\x74\x22\x20\x74\x79\x70\x65\x3d\x22\
-\x74\x65\x78\x74\x22\x20\x2f\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\
-\x20\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x69\x6e\x70\x75\x74\x20\
-\x74\x79\x70\x65\x3d\x22\x73\x75\x62\x6d\x69\x74\x22\x20\x76\x61\
-\x6c\x75\x65\x3d\x22\x40\x53\x55\x42\x4d\x49\x54\x40\x22\x2f\x3e\
-\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x2f\x66\
-\x69\x65\x6c\x64\x73\x65\x74\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\
-\x20\x3c\x2f\x66\x6f\x72\x6d\x3e\x0a\x20\x20\x20\x20\x3c\x2f\x64\
-\x69\x76\x3e\x0a\x20\x20\x20\x20\x3c\x64\x69\x76\x20\x69\x64\x3d\
-\x22\x66\x6f\x6f\x74\x65\x72\x22\x3e\x3c\x2f\x64\x69\x76\x3e\x0a\
-\x3c\x2f\x62\x6f\x64\x79\x3e\x0a\x3c\x2f\x68\x74\x6d\x6c\x3e\x0a\
-\
+\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\x67\x65\x74\x45\x6c\x65\x6d\
+\x65\x6e\x74\x42\x79\x49\x64\x28\x27\x6c\x69\x6e\x65\x45\x64\x69\
+\x74\x27\x29\x2e\x70\x6c\x61\x63\x65\x68\x6f\x6c\x64\x65\x72\x20\
+\x3d\x20\x70\x72\x6f\x76\x69\x64\x65\x72\x3b\x0a\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x7d\x29\x3b\x0a\x0a\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x2f\x2f\x20\x54\x72\x79\x20\
+\x74\x6f\x20\x63\x68\x61\x6e\x67\x65\x20\x74\x68\x65\x20\x64\x69\
+\x72\x65\x63\x74\x69\x6f\x6e\x20\x6f\x66\x20\x74\x68\x65\x20\x70\
+\x61\x67\x65\x3a\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x76\x61\x72\x20\x6e\x65\x77\x44\x69\x72\x20\x3d\x20\x27\
+\x40\x51\x54\x5f\x4c\x41\x59\x4f\x55\x54\x5f\x44\x49\x52\x45\x43\
+\x54\x49\x4f\x4e\x40\x27\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x6e\x65\x77\x44\x69\x72\x20\x3d\x20\x6e\x65\x77\
+\x44\x69\x72\x2e\x74\x6f\x4c\x6f\x77\x65\x72\x43\x61\x73\x65\x28\
+\x29\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x69\
+\x66\x20\x28\x28\x6e\x65\x77\x44\x69\x72\x20\x21\x3d\x20\x27\x6c\
+\x74\x72\x27\x29\x20\x26\x26\x20\x28\x6e\x65\x77\x44\x69\x72\x20\
+\x21\x3d\x20\x27\x72\x74\x6c\x27\x29\x29\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x6e\x65\x77\x44\x69\
+\x72\x20\x3d\x20\x27\x6c\x74\x72\x27\x3b\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\
+\x67\x65\x74\x45\x6c\x65\x6d\x65\x6e\x74\x73\x42\x79\x54\x61\x67\
+\x4e\x61\x6d\x65\x28\x27\x62\x6f\x64\x79\x27\x29\x5b\x30\x5d\x2e\
+\x73\x65\x74\x41\x74\x74\x72\x69\x62\x75\x74\x65\x28\x0a\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x27\x64\
+\x69\x72\x27\x2c\x20\x6e\x65\x77\x44\x69\x72\x29\x3b\x0a\x20\x20\
+\x20\x20\x20\x20\x20\x20\x7d\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\
+\x20\x66\x75\x6e\x63\x74\x69\x6f\x6e\x20\x66\x6f\x72\x6d\x53\x75\
+\x62\x6d\x69\x74\x74\x65\x64\x28\x29\x0a\x20\x20\x20\x20\x20\x20\
+\x20\x20\x7b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x76\x61\x72\x20\x73\x74\x72\x69\x6e\x67\x20\x3d\x20\x6c\x69\x6e\
+\x65\x45\x64\x69\x74\x2e\x76\x61\x6c\x75\x65\x3b\x0a\x0a\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x69\x66\x20\x28\x73\x74\
+\x72\x69\x6e\x67\x2e\x6c\x65\x6e\x67\x74\x68\x20\x3d\x3d\x20\x30\
+\x29\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x72\x65\x74\x75\x72\x6e\x3b\x0a\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x65\x78\x74\x65\x72\x6e\x61\x6c\x2e\
+\x73\x74\x61\x72\x74\x50\x61\x67\x65\x2e\x73\x65\x61\x72\x63\x68\
+\x55\x72\x6c\x28\x73\x74\x72\x69\x6e\x67\x2c\x20\x66\x75\x6e\x63\
+\x74\x69\x6f\x6e\x28\x75\x72\x6c\x29\x20\x7b\x0a\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x77\x69\x6e\x64\
+\x6f\x77\x2e\x6c\x6f\x63\x61\x74\x69\x6f\x6e\x2e\x68\x72\x65\x66\
+\x20\x3d\x20\x75\x72\x6c\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x7d\x29\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\
+\x7d\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x2f\x2f\x20\x49\x6e\x69\x74\x69\x61\x6c\x69\x7a\x65\
+\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x69\x66\x20\x28\x77\x69\x6e\
+\x64\x6f\x77\x2e\x65\x78\x74\x65\x72\x6e\x61\x6c\x29\x20\x7b\x0a\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x75\x70\x64\x61\
+\x74\x65\x28\x29\x3b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x7d\x20\
+\x65\x6c\x73\x65\x20\x7b\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x20\x64\x6f\x63\x75\x6d\x65\x6e\x74\x2e\x61\x64\x64\x45\
+\x76\x65\x6e\x74\x4c\x69\x73\x74\x65\x6e\x65\x72\x28\x27\x5f\x65\
+\x72\x69\x63\x5f\x65\x78\x74\x65\x72\x6e\x61\x6c\x5f\x63\x72\x65\
+\x61\x74\x65\x64\x27\x2c\x20\x75\x70\x64\x61\x74\x65\x29\x3b\x0a\
+\x20\x20\x20\x20\x20\x20\x20\x20\x7d\x0a\x20\x20\x20\x20\x3c\x2f\
+\x73\x63\x72\x69\x70\x74\x3e\x0a\x3c\x2f\x68\x65\x61\x64\x3e\x0a\
+\x3c\x62\x6f\x64\x79\x20\x6f\x6e\x6c\x6f\x61\x64\x3d\x22\x64\x6f\
+\x63\x75\x6d\x65\x6e\x74\x2e\x66\x6f\x72\x6d\x73\x5b\x30\x5d\x2e\
+\x6c\x69\x6e\x65\x45\x64\x69\x74\x2e\x73\x65\x6c\x65\x63\x74\x28\
+\x29\x3b\x22\x3e\x0a\x20\x20\x20\x20\x3c\x64\x69\x76\x20\x69\x64\
+\x3d\x22\x68\x65\x61\x64\x65\x72\x22\x3e\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x3c\x68\x31\x3e\x40\x48\x45\x41\x44\x45\x52\x5f\x54\
+\x49\x54\x4c\x45\x40\x3c\x2f\x68\x31\x3e\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x3c\x69\x6d\x67\x20\x73\x72\x63\x3d\x22\x40\x49\x4d\
+\x41\x47\x45\x40\x22\x20\x77\x69\x64\x74\x68\x3d\x22\x33\x32\x22\
+\x20\x68\x65\x69\x67\x68\x74\x3d\x22\x33\x32\x22\x2f\x3e\x0a\x20\
+\x20\x20\x20\x3c\x2f\x64\x69\x76\x3e\x0a\x20\x20\x20\x20\x3c\x64\
+\x69\x76\x20\x69\x64\x3d\x22\x73\x65\x61\x72\x63\x68\x22\x3e\x0a\
+\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x66\x6f\x72\x6d\x20\x61\x63\
+\x74\x69\x6f\x6e\x3d\x22\x6a\x61\x76\x61\x73\x63\x72\x69\x70\x74\
+\x3a\x66\x6f\x72\x6d\x53\x75\x62\x6d\x69\x74\x74\x65\x64\x28\x29\
+\x3b\x22\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x3c\x66\x69\x65\x6c\x64\x73\x65\x74\x3e\x0a\x20\x20\x20\x20\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x3c\x69\x6e\x70\x75\
+\x74\x20\x69\x64\x3d\x22\x6c\x69\x6e\x65\x45\x64\x69\x74\x22\x20\
+\x6e\x61\x6d\x65\x3d\x22\x6c\x69\x6e\x65\x45\x64\x69\x74\x22\x20\
+\x74\x79\x70\x65\x3d\x22\x74\x65\x78\x74\x22\x20\x2f\x3e\x0a\x20\
+\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x3c\
+\x69\x6e\x70\x75\x74\x20\x74\x79\x70\x65\x3d\x22\x73\x75\x62\x6d\
+\x69\x74\x22\x20\x76\x61\x6c\x75\x65\x3d\x22\x40\x53\x55\x42\x4d\
+\x49\x54\x40\x22\x2f\x3e\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\
+\x20\x20\x20\x3c\x2f\x66\x69\x65\x6c\x64\x73\x65\x74\x3e\x0a\x20\
+\x20\x20\x20\x20\x20\x20\x20\x3c\x2f\x66\x6f\x72\x6d\x3e\x0a\x20\
+\x20\x20\x20\x3c\x2f\x64\x69\x76\x3e\x0a\x20\x20\x20\x20\x3c\x64\
+\x69\x76\x20\x69\x64\x3d\x22\x66\x6f\x6f\x74\x65\x72\x22\x3e\x3c\
+\x2f\x64\x69\x76\x3e\x0a\x3c\x2f\x62\x6f\x64\x79\x3e\x0a\x3c\x2f\
+\x68\x74\x6d\x6c\x3e\x0a\
 \x00\x00\x03\x7c\
 \x3c\
 \x21\x44\x4f\x43\x54\x59\x50\x45\x20\x68\x74\x6d\x6c\x3e\x0a\x3c\
@@ -291,7 +291,7 @@
 \x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
 \x00\x00\x00\x00\x00\x02\x00\x00\x00\x02\x00\x00\x00\x02\
 \x00\x00\x00\x0e\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
-\x00\x00\x00\x30\x00\x00\x00\x00\x00\x01\x00\x00\x0c\x85\
+\x00\x00\x00\x30\x00\x00\x00\x00\x00\x01\x00\x00\x0c\x8b\
 "
 
 def qInitResources():
--- a/eric6.e4p	Wed Mar 16 19:08:48 2016 +0100
+++ b/eric6.e4p	Wed Mar 16 19:51:00 2016 +0100
@@ -1351,6 +1351,8 @@
     <Source>WebBrowser/History/HistoryTreeModel.py</Source>
     <Source>WebBrowser/History/__init__.py</Source>
     <Source>WebBrowser/JavaScript/ExternalJsObject.py</Source>
+    <Source>WebBrowser/JavaScript/PasswordManagerJsObject.py</Source>
+    <Source>WebBrowser/JavaScript/StartPageJsObject.py</Source>
     <Source>WebBrowser/JavaScript/__init__.py</Source>
     <Source>WebBrowser/Network/EricSchemeHandler.py</Source>
     <Source>WebBrowser/Network/FollowRedirectReply.py</Source>

eric ide

mercurial