summaryrefslogtreecommitdiffstats
path: root/src/core/user_script.h
diff options
context:
space:
mode:
authorSzabolcs David <davidsz@inf.u-szeged.hu>2016-06-03 02:41:21 -0700
committerSzabolcs David <davidsz@inf.u-szeged.hu>2016-07-07 08:41:35 +0000
commit9bb9076c50048913075f11692f784ebb959d63cf (patch)
tree4a27e9eb3c7bd767963505f14ac0c703c811338c /src/core/user_script.h
parent800365f6faad962a4dd2e71173527d285a3f62b5 (diff)
Parse metadata block in user scripts
This allows WebEngine to build up user script objects from the metadata section of their source code. It also implements @include, @exclude and @match rules for restricting script injection to given URL patterns. Change-Id: Ic7b3023c0143643bfbf71adbfa25a8022b223fcf Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/core/user_script.h')
-rw-r--r--src/core/user_script.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/user_script.h b/src/core/user_script.h
index 9d7d66a58..e44efd3e9 100644
--- a/src/core/user_script.h
+++ b/src/core/user_script.h
@@ -85,9 +85,12 @@ public:
bool operator==(const UserScript &) const;
+ static int validUserScriptSchemes();
+
private:
void initData();
UserScriptData &data() const;
+ void parseMetadataHeader();
friend class UserResourceControllerHost;
QScopedPointer<UserScriptData> scriptData;