| Index: extensions/browser/api/declarative/declarative_rule.h
|
| diff --git a/extensions/browser/api/declarative/declarative_rule.h b/extensions/browser/api/declarative/declarative_rule.h
|
| index b612f271d6407864c99400abb174e6b551bf8971..8dd3837d6bb0f5e49fcb648f394a8ff16768b57f 100644
|
| --- a/extensions/browser/api/declarative/declarative_rule.h
|
| +++ b/extensions/browser/api/declarative/declarative_rule.h
|
| @@ -23,6 +23,7 @@
|
| #include "components/url_matcher/url_matcher.h"
|
| #include "extensions/common/api/events.h"
|
| #include "extensions/common/extension.h"
|
| +#include "extensions/common/host_id.h"
|
|
|
| namespace base {
|
| class Time;
|
| @@ -152,6 +153,7 @@
|
| // the extension API.
|
| static scoped_ptr<DeclarativeActionSet> Create(
|
| content::BrowserContext* browser_context,
|
| + const HostID& host_id,
|
| const Extension* extension,
|
| const AnyVector& actions,
|
| std::string* error,
|
| @@ -230,6 +232,7 @@
|
| static scoped_ptr<DeclarativeRule> Create(
|
| url_matcher::URLMatcherConditionFactory* url_matcher_condition_factory,
|
| content::BrowserContext* browser_context,
|
| + const HostID& host_id,
|
| const Extension* extension,
|
| base::Time extension_installation_time,
|
| linked_ptr<JsonRule> rule,
|
| @@ -366,6 +369,7 @@
|
| scoped_ptr<DeclarativeActionSet<ActionT> >
|
| DeclarativeActionSet<ActionT>::Create(
|
| content::BrowserContext* browser_context,
|
| + const HostID& host_id,
|
| const Extension* extension,
|
| const AnyVector& actions,
|
| std::string* error,
|
| @@ -378,7 +382,8 @@
|
| i != actions.end(); ++i) {
|
| CHECK(i->get());
|
| scoped_refptr<const ActionT> action =
|
| - ActionT::Create(browser_context, extension, **i, error, bad_message);
|
| + ActionT::Create(
|
| + browser_context, host_id, extension, **i, error, bad_message);
|
| if (!error->empty() || *bad_message)
|
| return scoped_ptr<DeclarativeActionSet>();
|
| result.push_back(action);
|
| @@ -455,6 +460,7 @@
|
| DeclarativeRule<ConditionT, ActionT>::Create(
|
| url_matcher::URLMatcherConditionFactory* url_matcher_condition_factory,
|
| content::BrowserContext* browser_context,
|
| + const HostID& host_id,
|
| const Extension* extension,
|
| base::Time extension_installation_time,
|
| linked_ptr<JsonRule> rule,
|
| @@ -470,8 +476,8 @@
|
|
|
| bool bad_message = false;
|
| scoped_ptr<ActionSet> actions =
|
| - ActionSet::Create(
|
| - browser_context, extension, rule->actions, error, &bad_message);
|
| + ActionSet::Create(browser_context, host_id, extension,
|
| + rule->actions, error, &bad_message);
|
| if (bad_message) {
|
| // TODO(battre) Export concept of bad_message to caller, the extension
|
| // should be killed in case it is true.
|
|
|