summaryrefslogtreecommitdiffstats
path: root/src/core/web_engine_context.cpp
diff options
context:
space:
mode:
authorMichael BrĂ¼ning <michael.bruning@qt.io>2020-07-24 10:30:54 +0200
committerMichael BrĂ¼ning <michael.bruning@qt.io>2020-07-24 15:23:10 +0200
commit54b84e14589b3e51f2f2e7980e2af2559601efe2 (patch)
treeeafef9f5b854cd90f6fa8e1ae5ab9e161a424aa3 /src/core/web_engine_context.cpp
parent27332664b2745d7d322b8afbc1a41dc0fbfc763a (diff)
parenta2a19a6965601ced75e3e48b2bf618ba2bdbd29e (diff)
Merge remote-tracking branch 'origin/5.15' into dev
Conflicts: src/core/compositor/delegated_frame_node.cpp src/core/core_chromium.pri src/core/render_widget_host_view_qt.cpp Change-Id: I9387151e9647c87fc387095e7b6d8d66560cdf71
Diffstat (limited to 'src/core/web_engine_context.cpp')
-rw-r--r--src/core/web_engine_context.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/core/web_engine_context.cpp b/src/core/web_engine_context.cpp
index 5b0e9d0c1..bfb34c484 100644
--- a/src/core/web_engine_context.cpp
+++ b/src/core/web_engine_context.cpp
@@ -173,9 +173,9 @@ bool usingDefaultSGBackend()
}
if (device.isEmpty())
- device = QString::fromLocal8Bit(qgetenv("QT_QUICK_BACKEND"));
+ device = qEnvironmentVariable("QT_QUICK_BACKEND");
if (device.isEmpty())
- device = QString::fromLocal8Bit(qgetenv("QMLSCENE_DEVICE"));
+ device = qEnvironmentVariable("QMLSCENE_DEVICE");
return device.isEmpty();
}
@@ -326,7 +326,7 @@ void WebEngineContext::addProfileAdapter(ProfileAdapter *profileAdapter)
{
Q_ASSERT(!m_profileAdapters.contains(profileAdapter));
const QString path = profileAdapter->dataPath();
- if (!path.isEmpty()) {
+ if (!profileAdapter->isOffTheRecord() && !profileAdapter->storageName().isEmpty()) {
for (auto profileAdapter : m_profileAdapters) {
if (profileAdapter->dataPath() == path) {
// QTBUG-66068
@@ -579,6 +579,8 @@ WebEngineContext::WebEngineContext()
setupProxyPac(parsedCommandLine);
parsedCommandLine->AppendSwitchPath(switches::kBrowserSubprocessPath, WebEngineLibraryInfo::getPath(content::CHILD_PROCESS_EXE));
+ parsedCommandLine->AppendSwitchASCII(service_manager::switches::kApplicationName, QCoreApplication::applicationName().toStdString());
+
// Enable sandboxing on OS X and Linux (Desktop / Embedded) by default.
bool disable_sandbox = qEnvironmentVariableIsSet(kDisableSandboxEnv);
if (!disable_sandbox) {
@@ -854,7 +856,7 @@ base::CommandLine* WebEngineContext::commandLine() {
QStringList appArgs = QCoreApplication::arguments();
if (qEnvironmentVariableIsSet(kChromiumFlagsEnv)) {
appArgs = appArgs.mid(0, 1); // Take application name and drop the rest
- appArgs.append(parseEnvCommandLine(QString::fromLocal8Bit(qgetenv(kChromiumFlagsEnv))));
+ appArgs.append(parseEnvCommandLine(qEnvironmentVariable(kChromiumFlagsEnv)));
}
#ifdef Q_OS_WIN
appArgs.removeAll(QStringLiteral("--enable-webgl-software-rendering"));