summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
Diffstat (limited to 'app')
-rw-r--r--app/resource_bundle_linux.cc13
-rw-r--r--app/resource_bundle_mac.mm10
2 files changed, 10 insertions, 13 deletions
diff --git a/app/resource_bundle_linux.cc b/app/resource_bundle_linux.cc
index 10d5caa..1fe4cb6 100644
--- a/app/resource_bundle_linux.cc
+++ b/app/resource_bundle_linux.cc
@@ -67,10 +67,9 @@ ResourceBundle::~ResourceBundle() {
delete locale_resources_data_;
locale_resources_data_ = NULL;
- delete theme_data_;
- theme_data_ = NULL;
delete resources_data_;
resources_data_ = NULL;
+ theme_data_ = NULL;
}
void ResourceBundle::LoadResources(const std::wstring& pref_locale) {
@@ -109,12 +108,10 @@ FilePath ResourceBundle::GetLocaleFilePath(const std::wstring& pref_locale) {
}
void ResourceBundle::LoadThemeResources() {
- FilePath theme_data_path;
- PathService::Get(app::DIR_THEMES, &theme_data_path);
- theme_data_path = theme_data_path.Append(FILE_PATH_LITERAL("default.pak"));
- theme_data_ = new base::DataPack;
- bool success = theme_data_->Load(theme_data_path);
- DCHECK(success) << "failed to load theme data";
+ // The data has been merged with chrome.pak so just set the pointer to be
+ // the same file.
+ DCHECK(resources_data_);
+ theme_data_ = resources_data_;
}
// static
diff --git a/app/resource_bundle_mac.mm b/app/resource_bundle_mac.mm
index 0bde757..7a6139f 100644
--- a/app/resource_bundle_mac.mm
+++ b/app/resource_bundle_mac.mm
@@ -24,10 +24,9 @@ ResourceBundle::~ResourceBundle() {
delete locale_resources_data_;
locale_resources_data_ = NULL;
- delete theme_data_;
- theme_data_ = NULL;
delete resources_data_;
resources_data_ = NULL;
+ theme_data_ = NULL;
}
namespace {
@@ -66,9 +65,10 @@ void ResourceBundle::LoadResources(const std::wstring& pref_locale) {
}
void ResourceBundle::LoadThemeResources() {
- DCHECK(theme_data_ == NULL) << "theme data already loaded!";
- theme_data_ = LoadResourceDataPack(@"theme");
- DCHECK(theme_data_) << "failed to load theme.pak";
+ // The data has been merged with chrome.pak so just set the pointer to be
+ // the same file.
+ DCHECK(resources_data_);
+ theme_data_ = resources_data_;
}
// static