20 lines
682 B
Diff
20 lines
682 B
Diff
--- a/qtpy/QtWebEngineWidgets.py
|
|
+++ b/qtpy/QtWebEngineWidgets.py
|
|
@@ -32,11 +32,11 @@
|
|
QWebEngineSettings,
|
|
QWebEngineView,
|
|
)
|
|
- except ModuleNotFoundError as error:
|
|
- raise QtModuleNotInstalledError(
|
|
- name="QtWebEngineWidgets",
|
|
- missing_package="PyQtWebEngine",
|
|
- ) from error
|
|
+ except ImportError:
|
|
+ from PyQt5.QtWebKitWidgets import QWebPage as QWebEnginePage
|
|
+ from PyQt5.QtWebKitWidgets import QWebView as QWebEngineView
|
|
+ from PyQt5.QtWebKit import QWebSettings as QWebEngineSettings
|
|
+ WEBENGINE = False
|
|
elif PYQT6:
|
|
try:
|
|
from PyQt6.QtWebEngineCore import (
|