summaryrefslogtreecommitdiffstats
path: root/WebCore/page/PageGroup.h
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/page/PageGroup.h')
-rw-r--r--WebCore/page/PageGroup.h27
1 files changed, 23 insertions, 4 deletions
diff --git a/WebCore/page/PageGroup.h b/WebCore/page/PageGroup.h
index 8c842b9..7ea2967 100644
--- a/WebCore/page/PageGroup.h
+++ b/WebCore/page/PageGroup.h
@@ -30,6 +30,8 @@
#include <wtf/Noncopyable.h>
#include "LinkHash.h"
#include "StringHash.h"
+#include "UserScript.h"
+#include "UserStyleSheet.h"
namespace WebCore {
@@ -41,10 +43,11 @@ namespace WebCore {
public:
PageGroup(const String& name);
PageGroup(Page*);
+ ~PageGroup();
static PageGroup* pageGroup(const String& groupName);
static void closeLocalStorage();
-
+
const HashSet<Page*>& pages() const { return m_pages; }
void addPage(Page*);
@@ -64,13 +67,26 @@ namespace WebCore {
#if ENABLE(DOM_STORAGE)
StorageNamespace* localStorage();
+ bool hasLocalStorage() { return m_localStorage; }
#endif
+ void addUserScript(const String& source, const KURL&,
+ PassOwnPtr<Vector<String> > whitelist, PassOwnPtr<Vector<String> > blacklist,
+ unsigned worldID, UserScriptInjectionTime);
+ const UserScriptMap* userScripts() const { return m_userScripts.get(); }
+
+ void addUserStyleSheet(const String& source, const KURL&,
+ PassOwnPtr<Vector<String> > whitelist, PassOwnPtr<Vector<String> > blacklist,
+ unsigned worldID);
+ const UserStyleSheetMap* userStyleSheets() const { return m_userStyleSheets.get(); }
+
+ void removeUserContentForWorld(unsigned);
+ void removeUserContentWithURLForWorld(const KURL&, unsigned);
+ void removeAllUserContent();
+
private:
void addVisitedLink(LinkHash stringHash);
-#if ENABLE(DOM_STORAGE)
- bool hasLocalStorage() { return m_localStorage; }
-#endif
+
String m_name;
HashSet<Page*> m_pages;
@@ -82,6 +98,9 @@ namespace WebCore {
#if ENABLE(DOM_STORAGE)
RefPtr<StorageNamespace> m_localStorage;
#endif
+
+ OwnPtr<UserScriptMap> m_userScripts;
+ OwnPtr<UserStyleSheetMap> m_userStyleSheets;
};
} // namespace WebCore