summaryrefslogtreecommitdiffstats
path: root/src/core/browser_context_adapter.h
diff options
context:
space:
mode:
authorPierre Rossi <pierre.rossi@digia.com>2014-11-18 16:08:20 +0100
committerAndras Becsi <andras.becsi@theqtcompany.com>2015-02-21 21:38:57 +0000
commit4ed187a54e6d2a06bbe272e1429757b6572dc6b6 (patch)
tree2b1d0485a780904f544623dff96be9dd270988bc /src/core/browser_context_adapter.h
parent88ca68c1b3ceff005f6a3a33fc8fc0d551c53a70 (diff)
Introduce a user scripts mechanism
Allowing programmatic injection of JavaScript to accomplish all sorts of tasks on the render process side. This API gives control over the point during the loading phase at which the script is run, whether it is run on sub-frames or not, as well as the JavaScript world it is run in (either the page's main world, or an arbitrary isolated world). This only has the Widgets API. The Quick API, tests and docs are coming in separate patches Change-Id: Ia1c79f68f8dfd4d964281d9723d09062ed7abe46 Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
Diffstat (limited to 'src/core/browser_context_adapter.h')
-rw-r--r--src/core/browser_context_adapter.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/browser_context_adapter.h b/src/core/browser_context_adapter.h
index 6389d666c..2a7c3465f 100644
--- a/src/core/browser_context_adapter.h
+++ b/src/core/browser_context_adapter.h
@@ -48,6 +48,7 @@ class BrowserContextAdapterClient;
class BrowserContextQt;
class CustomUrlSchemeHandler;
class DownloadManagerDelegateQt;
+class UserScriptControllerHost;
class WebEngineVisitedLinksManager;
class QWEBENGINE_EXPORT BrowserContextAdapter : public QSharedData
@@ -123,6 +124,7 @@ public:
QVector<CustomUrlSchemeHandler*> &customUrlSchemeHandlers();
void updateCustomUrlSchemeHandlers();
+ UserScriptControllerHost *userScriptController();
private:
QString m_name;
@@ -130,6 +132,8 @@ private:
QScopedPointer<BrowserContextQt> m_browserContext;
QScopedPointer<WebEngineVisitedLinksManager> m_visitedLinksManager;
QScopedPointer<DownloadManagerDelegateQt> m_downloadManagerDelegate;
+ QScopedPointer<UserScriptControllerHost> m_userScriptController;
+
QString m_dataPath;
QString m_cachePath;
QString m_httpUserAgent;