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

Unified Diff: chrome/common/extensions/extension.cc

Issue 13473013: Move ThemeHandler from c/c/e/api; move GetBrowserImages() out of Extension class (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Latest master Created 7 years, 8 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
« no previous file with comments | « chrome/common/extensions/extension.h ('k') | chrome/common/extensions/extension_file_util.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/extension.cc
diff --git a/chrome/common/extensions/extension.cc b/chrome/common/extensions/extension.cc
index 606d043e26188bc298a2e2377220fda53e25b5db..c4c1d9a2914762c2dfff9c6ff2a10224d6c1403f 100644
--- a/chrome/common/extensions/extension.cc
+++ b/chrome/common/extensions/extension.cc
@@ -28,9 +28,7 @@
// part of crbug.com/159265.
#include "chrome/common/extensions/api/extension_action/action_info.h"
#include "chrome/common/extensions/api/plugins/plugins_handler.h"
-#include "chrome/common/extensions/api/themes/theme_handler.h"
#include "chrome/common/extensions/background_info.h"
-#include "chrome/common/extensions/extension_icon_set.h"
#include "chrome/common/extensions/extension_manifest_constants.h"
#include "chrome/common/extensions/feature_switch.h"
#include "chrome/common/extensions/features/base_feature_provider.h"
@@ -665,55 +663,6 @@ bool Extension::ShowConfigureContextMenus() const {
return location() != Manifest::COMPONENT;
}
-std::set<base::FilePath> Extension::GetBrowserImages() const {
- std::set<base::FilePath> image_paths;
- // TODO(viettrungluu): These |FilePath::FromWStringHack(UTF8ToWide())|
- // indicate that we're doing something wrong.
-
- // Extension icons.
- for (ExtensionIconSet::IconMap::const_iterator iter =
- IconsInfo::GetIcons(this).map().begin();
- iter != IconsInfo::GetIcons(this).map().end(); ++iter) {
- image_paths.insert(
- base::FilePath::FromWStringHack(UTF8ToWide(iter->second)));
- }
-
- // Theme images.
- DictionaryValue* theme_images = ThemeInfo::GetThemeImages(this);
- if (theme_images) {
- for (DictionaryValue::Iterator it(*theme_images); !it.IsAtEnd();
- it.Advance()) {
- std::string val;
- if (it.value().GetAsString(&val))
- image_paths.insert(base::FilePath::FromWStringHack(UTF8ToWide(val)));
- }
- }
-
- const ActionInfo* page_action_info = ActionInfo::GetPageActionInfo(this);
- if (page_action_info && !page_action_info->default_icon.empty()) {
- for (ExtensionIconSet::IconMap::const_iterator iter =
- page_action_info->default_icon.map().begin();
- iter != page_action_info->default_icon.map().end();
- ++iter) {
- image_paths.insert(
- base::FilePath::FromWStringHack(UTF8ToWide(iter->second)));
- }
- }
-
- const ActionInfo* browser_action = ActionInfo::GetBrowserActionInfo(this);
- if (browser_action && !browser_action->default_icon.empty()) {
- for (ExtensionIconSet::IconMap::const_iterator iter =
- browser_action->default_icon.map().begin();
- iter != browser_action->default_icon.map().end();
- ++iter) {
- image_paths.insert(
- base::FilePath::FromWStringHack(UTF8ToWide(iter->second)));
- }
- }
-
- return image_paths;
-}
-
GURL Extension::GetFullLaunchURL() const {
return launch_local_path().empty() ? GURL(launch_web_url()) :
url().Resolve(launch_local_path());
« no previous file with comments | « chrome/common/extensions/extension.h ('k') | chrome/common/extensions/extension_file_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698