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

Unified Diff: app/resource_bundle.cc

Issue 348033: Remove themes/default.dll and merge the resources into chrome.dll. (Closed)
Patch Set: update comments Created 11 years, 1 month 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 | « app/resource_bundle.h ('k') | app/resource_bundle_linux.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: app/resource_bundle.cc
diff --git a/app/resource_bundle.cc b/app/resource_bundle.cc
index a2ebdf0e5c589e6d320430313048f852322875b9..6d8829d4409e78261848d6bd779d1ffc0034cbe8 100644
--- a/app/resource_bundle.cc
+++ b/app/resource_bundle.cc
@@ -55,8 +55,7 @@ ResourceBundle& ResourceBundle::GetSharedInstance() {
ResourceBundle::ResourceBundle()
: resources_data_(NULL),
- locale_resources_data_(NULL),
- theme_data_(NULL) {
+ locale_resources_data_(NULL) {
}
void ResourceBundle::FreeImages() {
@@ -89,7 +88,7 @@ std::string ResourceBundle::GetDataResource(int resource_id) {
RefCountedStaticMemory* ResourceBundle::LoadImageResourceBytes(
int resource_id) {
- return LoadResourceBytes(theme_data_, resource_id);
+ return LoadResourceBytes(resources_data_, resource_id);
}
RefCountedStaticMemory* ResourceBundle::LoadDataResourceBytes(
@@ -108,15 +107,10 @@ SkBitmap* ResourceBundle::GetBitmapNamed(int resource_id) {
scoped_ptr<SkBitmap> bitmap;
- if (theme_data_)
- bitmap.reset(LoadBitmap(theme_data_, resource_id));
-
- // If we did not find the bitmap in the theme DLL, try the current one.
- if (!bitmap.get())
- bitmap.reset(LoadBitmap(resources_data_, resource_id));
+ bitmap.reset(LoadBitmap(resources_data_, resource_id));
- // We loaded successfully. Cache the Skia version of the bitmap.
if (bitmap.get()) {
+ // We loaded successfully. Cache the Skia version of the bitmap.
AutoLock lock_scope(lock_);
// Another thread raced us, and has already cached the skia image.
« no previous file with comments | « app/resource_bundle.h ('k') | app/resource_bundle_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698