// Get handles for the views.
webEngineViewPointer = browserViewUi.webEngineView;
+ // Create an off-the-record profile (the default when no profile name is specified).
+ webEngineProfilePointer = new QWebEngineProfile(QStringLiteral(""));
+
+ // Create a WebEngine page.
+ QWebEnginePage *webEnginePagePointer = new QWebEnginePage(webEngineProfilePointer);
+
+ // Set the WebEngine page.
+ webEngineViewPointer->setPage(webEnginePagePointer);
+
// Get handles for the aspects of the WebEngine.
- QWebEnginePage *webEnginePagePointer = webEngineViewPointer->page();
webEngineHistoryPointer = webEnginePagePointer->history();
- webEngineProfilePointer = webEnginePagePointer->profile();
webEngineSettingsPointer = webEngineViewPointer->settings();
// Update the URL line edit when the URL changes.
// Reapply the domain settings when the host changes.
connect(urlRequestInterceptorPointer, SIGNAL(applyDomainSettings(QString)), this, SLOT(applyDomainSettingsWithoutReloading(QString)));
- // Disable the cache.
- webEngineProfilePointer->setHttpCacheType(QWebEngineProfile::NoCache);
-
// Don't allow JavaScript to open windows.
webEngineSettingsPointer->setAttribute(QWebEngineSettings::JavascriptCanOpenWindows, false);