Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1479)

Unified Diff: chrome/browser/extensions/api/declarative_content/content_action.cc

Issue 491913003: Add Reapply() to declarative action interface. This is needed for RequestContentScript to work corr… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase again Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/api/declarative_content/content_action.cc
diff --git a/chrome/browser/extensions/api/declarative_content/content_action.cc b/chrome/browser/extensions/api/declarative_content/content_action.cc
index 157f2aa963f074f8edf01996dd429e6dd8357017..4cc5fbe412d5ade4068e9ac083482bba66cb5fb8 100644
--- a/chrome/browser/extensions/api/declarative_content/content_action.cc
+++ b/chrome/browser/extensions/api/declarative_content/content_action.cc
@@ -70,6 +70,10 @@ class ShowPageAction : public ContentAction {
ExtensionActionAPI::Get(apply_info->profile)->NotifyChange(
action, apply_info->tab, apply_info->profile);
}
+ // The page action is already showing, so nothing needs to be done here.
+ virtual void Reapply(const std::string& extension_id,
+ const base::Time& extension_install_time,
+ ApplyInfo* apply_info) const OVERRIDE {}
virtual void Revert(const std::string& extension_id,
const base::Time& extension_install_time,
ApplyInfo* apply_info) const OVERRIDE {
@@ -125,6 +129,13 @@ class RequestContentScript : public ContentAction {
// load new user script.
}
+ virtual void Reapply(const std::string& extension_id,
+ const base::Time& extension_install_time,
+ ApplyInfo* apply_info) const OVERRIDE {
+ // TODO(markdittmer): Invoke UserScriptMaster declarative script loader:
+ // load new user script.
+ }
+
virtual void Revert(const std::string& extension_id,
const base::Time& extension_install_time,
ApplyInfo* apply_info) const OVERRIDE {

Powered by Google App Engine
This is Rietveld 408576698