Chromium Code Reviews| 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 a4ef26b44a8068f4d447908c5e552d279cf41d65..f7185f99df0c8cd03153d0a3217df7b1b76ad750 100644 |
| --- a/chrome/browser/extensions/api/declarative/rules_registry.h |
| +++ b/chrome/browser/extensions/api/declarative/rules_registry.h |
| @@ -120,9 +120,11 @@ class RulesRegistry : public base::RefCountedThreadSafe<RulesRegistry> { |
| void GetAllRules(const std::string& extension_id, |
| std::vector<linked_ptr<RulesRegistry::Rule> >* out); |
| - // Called to notify the RulesRegistry that an extension has been unloaded |
| - // and all rules of this extension need to be removed. |
| + // Called to notify the RulesRegistry that the extension availability has |
| + // changed, so that the registry can update which rules are active. |
| void OnExtensionUnloaded(const std::string& extension_id); |
| + void OnExtensionUninstalled(const std::string& extension_id); |
| + void OnExtensionLoaded(const std::string& extension_id); |
| // Returns the number of entries in used_rule_identifiers_ for leak detection. |
| // Every ExtensionId counts as one entry, even if it contains no rules. |
| @@ -213,6 +215,13 @@ class RulesRegistry : public base::RefCountedThreadSafe<RulesRegistry> { |
| void DeserializeAndAddRules(const std::string& extension_id, |
| scoped_ptr<base::Value> rules); |
| + // These functions are responsible for removing rules from RulesRegistry |
| + // storage (as opposed to the storage of the inheriting registries, handled by |
|
Jeffrey Yasskin
2013/11/20 05:55:28
This isn't clear. Maybe "These functions remove ru
vabr (Chromium)
2013/11/20 17:46:07
I was also unhappy about the naming.
However, fol
|
| + // Remove(All)RulesImpl). |
| + void CommitRemoveRules(const std::string& extension_id, |
| + const std::vector<std::string>& rule_identifiers); |
| + void CommitRemoveAllRules(const std::string& extension_id); |
| + |
| // The profile to which this rules registry belongs. |
| Profile* profile_; |