Move and Document Dissable Sandbox

- Set Dissable Sandbox in app.py
- Include explanation comment
- Remove Dissable Sandbox from appimage specific script.
This commit is contained in:
jackson
2022-06-28 11:25:59 -05:00
parent dda0d47845
commit 5f06f16172
3 changed files with 5 additions and 6 deletions

View File

@@ -32,11 +32,6 @@ export LD_LIBRARY_PATH="${HERE}"
# Set some environment variables
export QT_PLUGIN_PATH="${HERE}"
# Disable sandbox support for QtWebEngine (required on some Linux distros
# for the QtWebEngineWidgets to be rendered, otherwise no timeline is visible).
# https://doc.qt.io/qt-5/qtwebengine-platform-notes.html#sandboxing-support
export QTWEBENGINE_DISABLE_SANDBOX="1"
# For Debian-based systems with newer openssl, see:
# https://github.com/OpenShot/openshot-qt/issues/3242
# https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=918727

View File

@@ -37,6 +37,11 @@ import json
from PyQt5.QtCore import PYQT_VERSION_STR, QT_VERSION_STR, pyqtSlot
from PyQt5.QtWidgets import QApplication, QStyleFactory, QMessageBox
# Disable sandbox support for QtWebEngine (required on some Linux distros
# for the QtWebEngineWidgets to be rendered, otherwise no timeline is visible).
# https://doc.qt.io/qt-5/qtwebengine-platform-notes.html#sandboxing-support
os.environ["QTWEBENGINE_DISABLE_SANDBOX"] = "1"
def get_app():
""" Get the current QApplication instance of OpenShot """

View File

@@ -47,7 +47,6 @@ class LoggingWebEnginePage(QWebEnginePage):
'%s@L%d: %s', os.path.basename(source), line, msg)
def __init__(self, parent=None):
os.environ["QTWEBENGINE_DISABLE_SANDBOX"] = "1"
super().__init__(parent=parent)
self.setObjectName("LoggingWebEnginePage")
self.levels = [logging.INFO, logging.WARNING, logging.ERROR]