| Index: chrome/browser/extensions/api/declarative/rules_registry.h
|
| diff --git a/chrome/browser/extensions/api/declarative/rules_registry.h b/chrome/browser/extensions/api/declarative/rules_registry.h
|
| index f877a656dfb5587cd172fd546f7862ecefd436f9..d1758e18e625aaed5e9f8205250270d16a32f770 100644
|
| --- a/chrome/browser/extensions/api/declarative/rules_registry.h
|
| +++ b/chrome/browser/extensions/api/declarative/rules_registry.h
|
| @@ -40,6 +40,7 @@ class RulesCacheDelegate;
|
| class RulesRegistry : public base::RefCountedThreadSafe<RulesRegistry> {
|
| public:
|
| typedef extensions::api::events::Rule Rule;
|
| + typedef std::pair<int, int> WebViewKey;
|
|
|
| enum Defaults { DEFAULT_PRIORITY = 100 };
|
| // After the RulesCacheDelegate object (the part of the registry which runs on
|
| @@ -50,7 +51,8 @@ class RulesRegistry : public base::RefCountedThreadSafe<RulesRegistry> {
|
| RulesRegistry(Profile* profile,
|
| const std::string& event_name,
|
| content::BrowserThread::ID owner_thread,
|
| - RulesCacheDelegate* cache_delegate);
|
| + RulesCacheDelegate* cache_delegate,
|
| + const WebViewKey& webview_key);
|
|
|
| const OneShotEvent& ready() const {
|
| return ready_;
|
| @@ -130,6 +132,11 @@ class RulesRegistry : public base::RefCountedThreadSafe<RulesRegistry> {
|
| // The name of the event with which rules are registered.
|
| const std::string& event_name() const { return event_name_; }
|
|
|
| + // The key that identifies the webview (or tabs) in which these rules apply.
|
| + const WebViewKey& webview_key() const {
|
| + return webview_key_;
|
| + }
|
| +
|
| protected:
|
| virtual ~RulesRegistry();
|
|
|
| @@ -192,6 +199,9 @@ class RulesRegistry : public base::RefCountedThreadSafe<RulesRegistry> {
|
| // The name of the event with which rules are registered.
|
| const std::string event_name_;
|
|
|
| + // The key that identifies the context in which these rules apply.
|
| + WebViewKey webview_key_;
|
| +
|
| RulesDictionary rules_;
|
|
|
| // Signaled when we have finished reading from storage for all extensions that
|
|
|