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

Unified Diff: chrome/browser/automation/testing_automation_provider.cc

Issue 10911300: Move ExtensionAction from common/ to browser/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: proof of concept Created 8 years, 3 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/automation/testing_automation_provider.cc
diff --git a/chrome/browser/automation/testing_automation_provider.cc b/chrome/browser/automation/testing_automation_provider.cc
index 50bef18bddfce965da92c969e777a0fbbba1e8f2..16735255bedde285c9e9ab1d969590bdd0c2198e 100644
--- a/chrome/browser/automation/testing_automation_provider.cc
+++ b/chrome/browser/automation/testing_automation_provider.cc
@@ -50,6 +50,7 @@
#include "chrome/browser/download/save_package_file_picker.h"
#include "chrome/browser/extensions/browser_action_test_util.h"
#include "chrome/browser/extensions/crx_installer.h"
+#include "chrome/browser/extensions/extension_action.h"
#include "chrome/browser/extensions/extension_host.h"
#include "chrome/browser/extensions/extension_process_manager.h"
#include "chrome/browser/extensions/extension_service.h"
@@ -123,7 +124,6 @@
#include "chrome/common/chrome_paths.h"
#include "chrome/common/chrome_switches.h"
#include "chrome/common/extensions/extension.h"
-#include "chrome/common/extensions/extension_action.h"
#include "chrome/common/extensions/permissions/permission_set.h"
#include "chrome/common/extensions/url_pattern.h"
#include "chrome/common/extensions/url_pattern_set.h"
@@ -3985,7 +3985,7 @@ void TestingAutomationProvider::TriggerPageActionById(
AutomationJSONReply(this, reply_message).SendError(error);
return;
}
- ExtensionAction* page_action = extension->page_action();
+ ExtensionAction* page_action = GetPageAction(browser->profile(), *extension);
if (!page_action) {
AutomationJSONReply(this, reply_message).SendError(
"Extension doesn't have any page action.");
@@ -4038,7 +4038,7 @@ void TestingAutomationProvider::TriggerBrowserActionById(
AutomationJSONReply(this, reply_message).SendError(error);
return;
}
- ExtensionAction* action = extension->browser_action();
+ ExtensionAction* action = GetBrowserAction(browser->profile(), *extension);
if (!action) {
AutomationJSONReply(this, reply_message).SendError(
"Extension doesn't have any browser action.");
@@ -6317,7 +6317,7 @@ void TestingAutomationProvider::IsPageActionVisible(
reply.SendError(error);
return;
}
- ExtensionAction* page_action = extension->page_action();
+ ExtensionAction* page_action = GetPageAction(browser->profile(), *extension);
if (!page_action) {
reply.SendError("Extension doesn't have any page action");
return;

Powered by Google App Engine
This is Rietveld 408576698