| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/browser_theme_provider.h" | 5 #include "chrome/browser/browser_theme_provider.h" |
| 6 | 6 |
| 7 #include "app/resource_bundle.h" | 7 #include "app/resource_bundle.h" |
| 8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
| 9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
| 10 #include "chrome/browser/browser_theme_pack.h" | 10 #include "chrome/browser/browser_theme_pack.h" |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 // The image resources that will be tinted by the 'button' tint value. | 139 // The image resources that will be tinted by the 'button' tint value. |
| 140 // If you change this list, you must increment the version number in | 140 // If you change this list, you must increment the version number in |
| 141 // browser_theme_pack.cc, and you should assign persistent IDs to the | 141 // browser_theme_pack.cc, and you should assign persistent IDs to the |
| 142 // data table at the start of said file or else tinted versions of | 142 // data table at the start of said file or else tinted versions of |
| 143 // these resources will not be created. | 143 // these resources will not be created. |
| 144 const int kToolbarButtonIDs[] = { | 144 const int kToolbarButtonIDs[] = { |
| 145 IDR_BACK, IDR_BACK_D, IDR_BACK_H, IDR_BACK_P, | 145 IDR_BACK, IDR_BACK_D, IDR_BACK_H, IDR_BACK_P, |
| 146 IDR_FORWARD, IDR_FORWARD_D, IDR_FORWARD_H, IDR_FORWARD_P, | 146 IDR_FORWARD, IDR_FORWARD_D, IDR_FORWARD_H, IDR_FORWARD_P, |
| 147 IDR_HOME, IDR_HOME_H, IDR_HOME_P, | 147 IDR_HOME, IDR_HOME_H, IDR_HOME_P, |
| 148 IDR_RELOAD, IDR_RELOAD_H, IDR_RELOAD_P, | 148 IDR_RELOAD, IDR_RELOAD_H, IDR_RELOAD_P, |
| 149 IDR_STOP, IDR_STOP_H, IDR_STOP_P, | 149 IDR_STOP, IDR_STOP_D, IDR_STOP_H, IDR_STOP_P, |
| 150 IDR_LOCATIONBG_C, IDR_LOCATIONBG_L, IDR_LOCATIONBG_R, | 150 IDR_LOCATIONBG_C, IDR_LOCATIONBG_L, IDR_LOCATIONBG_R, |
| 151 IDR_BROWSER_ACTIONS_OVERFLOW, IDR_BROWSER_ACTIONS_OVERFLOW_H, | 151 IDR_BROWSER_ACTIONS_OVERFLOW, IDR_BROWSER_ACTIONS_OVERFLOW_H, |
| 152 IDR_BROWSER_ACTIONS_OVERFLOW_P, | 152 IDR_BROWSER_ACTIONS_OVERFLOW_P, |
| 153 IDR_TOOLS, IDR_TOOLS_H, IDR_TOOLS_P, | 153 IDR_TOOLS, IDR_TOOLS_H, IDR_TOOLS_P, |
| 154 IDR_MENU_DROPARROW, | 154 IDR_MENU_DROPARROW, |
| 155 IDR_THROBBER, IDR_THROBBER_WAITING, IDR_THROBBER_LIGHT, | 155 IDR_THROBBER, IDR_THROBBER_WAITING, IDR_THROBBER_LIGHT, |
| 156 }; | 156 }; |
| 157 | 157 |
| 158 // Writes the theme pack to disk on a separate thread. | 158 // Writes the theme pack to disk on a separate thread. |
| 159 class WritePackToDiskTask : public Task { | 159 class WritePackToDiskTask : public Task { |
| (...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 600 void BrowserThemeProvider::OnInfobarDisplayed() { | 600 void BrowserThemeProvider::OnInfobarDisplayed() { |
| 601 number_of_infobars_++; | 601 number_of_infobars_++; |
| 602 } | 602 } |
| 603 | 603 |
| 604 void BrowserThemeProvider::OnInfobarDestroyed() { | 604 void BrowserThemeProvider::OnInfobarDestroyed() { |
| 605 number_of_infobars_--; | 605 number_of_infobars_--; |
| 606 | 606 |
| 607 if (number_of_infobars_ == 0) | 607 if (number_of_infobars_ == 0) |
| 608 RemoveUnusedThemes(); | 608 RemoveUnusedThemes(); |
| 609 } | 609 } |
| OLD | NEW |