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

Unified Diff: chrome/browser/themes/theme_properties.cc

Issue 747013003: Various optimizations to reduce the number of temporary allocations. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed two calls to string::reserve(). Created 6 years 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/themes/theme_properties.cc
diff --git a/chrome/browser/themes/theme_properties.cc b/chrome/browser/themes/theme_properties.cc
index caafb1cd89a7ad3beb8bbda1cc73ddce38aa44f8..0b14eb46e163a0b209307df71bdfab89321d410a 100644
--- a/chrome/browser/themes/theme_properties.cc
+++ b/chrome/browser/themes/theme_properties.cc
@@ -203,9 +203,7 @@ std::string ThemeProperties::TilingToString(int tiling) {
// static
bool ThemeProperties::IsThemeableImage(int id) {
Peter Kasting 2014/12/03 21:21:03 Can we eliminate this method and have consumers ca
Georges Khalil 2014/12/03 21:58:32 Sounds good. Done.
// TODO(pkotwicz): Cache results to improve lookup speed.
- std::set<int> themeable_idrs;
- BrowserThemePack::GetThemeableImageIDRs(&themeable_idrs);
- return themeable_idrs.find(id) != themeable_idrs.end();
+ return BrowserThemePack::IsThemeableImageIDRs(id);
}
// static

Powered by Google App Engine
This is Rietveld 408576698