| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "chrome/browser/extensions/page_action_controller.h" | 5 #include "chrome/browser/extensions/page_action_controller.h" |
| 6 | 6 |
| 7 #include "chrome/browser/chrome_notification_types.h" | 7 #include "chrome/browser/chrome_notification_types.h" |
| 8 #include "chrome/browser/extensions/api/extension_action/extension_action_api.h" | 8 #include "chrome/browser/extensions/api/extension_action/extension_action_api.h" |
| 9 #include "chrome/browser/extensions/component_loader.h" | 9 #include "chrome/browser/extensions/component_loader.h" |
| 10 #include "chrome/browser/extensions/extension_action.h" | 10 #include "chrome/browser/extensions/extension_action.h" |
| 11 #include "chrome/browser/extensions/extension_action_manager.h" | 11 #include "chrome/browser/extensions/extension_action_manager.h" |
| 12 #include "chrome/browser/extensions/extension_service.h" | 12 #include "chrome/browser/extensions/extension_service.h" |
| 13 #include "chrome/browser/extensions/extension_system.h" | 13 #include "chrome/browser/extensions/extension_system.h" |
| 14 #include "chrome/browser/extensions/extension_tab_util.h" | 14 #include "chrome/browser/extensions/extension_tab_util.h" |
| 15 #include "chrome/browser/extensions/tab_helper.h" | 15 #include "chrome/browser/extensions/tab_helper.h" |
| 16 #include "chrome/browser/profiles/profile.h" | 16 #include "chrome/browser/profiles/profile.h" |
| 17 #include "chrome/browser/sessions/session_id.h" | 17 #include "chrome/browser/sessions/session_id.h" |
| 18 #include "chrome/common/extensions/extension_set.h" | |
| 19 #include "content/public/browser/invalidate_type.h" | 18 #include "content/public/browser/invalidate_type.h" |
| 20 #include "content/public/browser/navigation_details.h" | 19 #include "content/public/browser/navigation_details.h" |
| 21 #include "content/public/browser/notification_service.h" | 20 #include "content/public/browser/notification_service.h" |
| 22 #include "content/public/browser/web_contents.h" | 21 #include "content/public/browser/web_contents.h" |
| 22 #include "extensions/common/extension_set.h" |
| 23 | 23 |
| 24 namespace extensions { | 24 namespace extensions { |
| 25 | 25 |
| 26 PageActionController::PageActionController(content::WebContents* web_contents) | 26 PageActionController::PageActionController(content::WebContents* web_contents) |
| 27 : content::WebContentsObserver(web_contents) {} | 27 : content::WebContentsObserver(web_contents) {} |
| 28 | 28 |
| 29 PageActionController::~PageActionController() {} | 29 PageActionController::~PageActionController() {} |
| 30 | 30 |
| 31 std::vector<ExtensionAction*> PageActionController::GetCurrentActions() const { | 31 std::vector<ExtensionAction*> PageActionController::GetCurrentActions() const { |
| 32 ExtensionService* service = GetExtensionService(); | 32 ExtensionService* service = GetExtensionService(); |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 | 119 |
| 120 ExtensionService* PageActionController::GetExtensionService() const { | 120 ExtensionService* PageActionController::GetExtensionService() const { |
| 121 Profile* profile = this->profile(); | 121 Profile* profile = this->profile(); |
| 122 if (profile) | 122 if (profile) |
| 123 return ExtensionSystem::Get(profile)->extension_service(); | 123 return ExtensionSystem::Get(profile)->extension_service(); |
| 124 | 124 |
| 125 return NULL; | 125 return NULL; |
| 126 } | 126 } |
| 127 | 127 |
| 128 } // namespace extensions | 128 } // namespace extensions |
| OLD | NEW |