Re-enabled the QtWebEngine related views on Windows as well. eric7

Fri, 24 Sep 2021 17:37:38 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 24 Sep 2021 17:37:38 +0200
branch
eric7
changeset 8631
b2c4c2f3fda7
parent 8630
5464b9c31cf9
child 8632
f25cd4b94eb0

Re-enabled the QtWebEngine related views on Windows as well.

eric7/EricNetwork/EricSslInfoWidget.py file | annotate | diff | comparison | revisions
eric7/UI/CodeDocumentationViewer.py file | annotate | diff | comparison | revisions
eric7/UI/Previewers/PreviewerHTML.py file | annotate | diff | comparison | revisions
eric7/eric7.py file | annotate | diff | comparison | revisions
eric7/eric7_browser.py file | annotate | diff | comparison | revisions
--- a/eric7/EricNetwork/EricSslInfoWidget.py	Fri Sep 24 16:34:46 2021 +0200
+++ b/eric7/EricNetwork/EricSslInfoWidget.py	Fri Sep 24 17:37:38 2021 +0200
@@ -164,14 +164,26 @@
             
             label = QLabel(self)
             label.setWordWrap(True)
-            label.setText(self.tr(
-                "It is encrypted using {0} at {1} bits, "
-                "with {2} for message authentication and "
-                "{3} as key exchange mechanism.\n\n").format(
-                cipher.encryptionMethod(),
-                cipher.usedBits(),
-                cipher.authenticationMethod(),
-                cipher.keyExchangeMethod()))
+            if (
+                not cipher.encryptionMethod() or
+                not cipher.usedBits() or
+                not cipher.authenticationMethod() or
+                not cipher.keyExchangeMethod()
+            ):
+                label.setText(self.tr(
+                    "The cipher data is incomplete or not known."
+                ))
+            else:
+                label.setText(self.tr(
+                    "It is encrypted using {0} at {1} bits, "
+                    "with {2} for message authentication and "
+                    "{3} as key exchange mechanism.\n\n").format(
+                    cipher.encryptionMethod(),
+                    cipher.usedBits(),
+                    cipher.authenticationMethod(),
+                    cipher.keyExchangeMethod()
+                    )
+                )
             layout.addWidget(label, rows, 1)
             rows += 1
     
--- a/eric7/UI/CodeDocumentationViewer.py	Fri Sep 24 16:34:46 2021 +0200
+++ b/eric7/UI/CodeDocumentationViewer.py	Fri Sep 24 17:37:38 2021 +0200
@@ -81,12 +81,6 @@
         self.__verticalLayout.setContentsMargins(0, 0, 0, 0)
         
         try:
-            # TODO: remove this workaround once rc0 issue is fixed
-            # Workaround for a bug in Qt 6.2.0 rc0 on non-Linux
-            import sys
-            if not sys.platform.startswith("linux"):
-                raise ImportError
-            
             from PyQt6.QtWebEngineCore import QWebEngineSettings
             from PyQt6.QtWebEngineWidgets import QWebEngineView
             self.__contents = QWebEngineView(self)
--- a/eric7/UI/Previewers/PreviewerHTML.py	Fri Sep 24 16:34:46 2021 +0200
+++ b/eric7/UI/Previewers/PreviewerHTML.py	Fri Sep 24 17:37:38 2021 +0200
@@ -51,11 +51,6 @@
         self.__previewAvailable = True
         
         try:
-            # TODO: remove this workaround once rc0 issue is fixed
-            # Workaround for a bug in Qt 6.2.0 rc0 on non-Linux
-            if not sys.platform.startswith("linux"):
-                raise ImportError
-            
             from PyQt6.QtWebEngineWidgets import QWebEngineView
             self.previewView = QWebEngineView(self)
             self.previewView.page().linkHovered.connect(self.__showLink)
--- a/eric7/eric7.py	Fri Sep 24 16:34:46 2021 +0200
+++ b/eric7/eric7.py	Fri Sep 24 17:37:38 2021 +0200
@@ -42,12 +42,9 @@
         " it is installed and accessible.")
     sys.exit(100)
 
-# TODO: remove this workaround once rc0 issue is fixed
-# Workaround for a bug in Qt 6.2.0 rc0 on non-Linux
-if sys.platform.startswith("linux"):
-    with contextlib.suppress(ImportError):
-        from PyQt6 import QtWebEngineWidgets
-        # __IGNORE_WARNING__ __IGNORE_EXCEPTION__
+with contextlib.suppress(ImportError):
+    from PyQt6 import QtWebEngineWidgets
+    # __IGNORE_WARNING__ __IGNORE_EXCEPTION__
 
 # some global variables needed to start the application
 args = None
--- a/eric7/eric7_browser.py	Fri Sep 24 16:34:46 2021 +0200
+++ b/eric7/eric7_browser.py	Fri Sep 24 17:37:38 2021 +0200
@@ -36,11 +36,6 @@
         sys.argv.remove(arg)
 
 try:
-    # TODO: remove this workaround once rc0 issue is fixed
-    # Workaround for a bug in Qt 6.2.0 rc0 on non-Linux
-    if not sys.platform.startswith("linux"):
-        raise ImportError
-    
     from PyQt6 import QtWebEngineWidgets    # __IGNORE_WARNING__
 except ImportError:
     if "--quiet" not in sys.argv:

eric ide

mercurial