| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/themes/theme_service.h" | 5 #include "chrome/browser/themes/theme_service.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 | 10 |
| (...skipping 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 427 // older ones if they are missing. | 427 // older ones if they are missing. |
| 428 const int kNtpText = ThemeProperties::COLOR_NTP_TEXT; | 428 const int kNtpText = ThemeProperties::COLOR_NTP_TEXT; |
| 429 const int kLabelBackground = | 429 const int kLabelBackground = |
| 430 ThemeProperties::COLOR_SUPERVISED_USER_LABEL_BACKGROUND; | 430 ThemeProperties::COLOR_SUPERVISED_USER_LABEL_BACKGROUND; |
| 431 switch (id) { | 431 switch (id) { |
| 432 case ThemeProperties::COLOR_TOOLBAR_BUTTON_ICON: | 432 case ThemeProperties::COLOR_TOOLBAR_BUTTON_ICON: |
| 433 return color_utils::HSLShift( | 433 return color_utils::HSLShift( |
| 434 gfx::kChromeIconGrey, | 434 gfx::kChromeIconGrey, |
| 435 GetTint(ThemeProperties::TINT_BUTTONS, incognito)); | 435 GetTint(ThemeProperties::TINT_BUTTONS, incognito)); |
| 436 case ThemeProperties::COLOR_TOOLBAR_BUTTON_ICON_INACTIVE: | 436 case ThemeProperties::COLOR_TOOLBAR_BUTTON_ICON_INACTIVE: |
| 437 // The active color is overridden in Gtk2UI. | 437 // The active color is overridden in GtkUi. |
| 438 return SkColorSetA( | 438 return SkColorSetA( |
| 439 GetColor(ThemeProperties::COLOR_TOOLBAR_BUTTON_ICON, incognito), | 439 GetColor(ThemeProperties::COLOR_TOOLBAR_BUTTON_ICON, incognito), |
| 440 0x33); | 440 0x33); |
| 441 case ThemeProperties::COLOR_TOOLBAR_TOP_SEPARATOR: | 441 case ThemeProperties::COLOR_TOOLBAR_TOP_SEPARATOR: |
| 442 case ThemeProperties::COLOR_TOOLBAR_TOP_SEPARATOR_INACTIVE: { | 442 case ThemeProperties::COLOR_TOOLBAR_TOP_SEPARATOR_INACTIVE: { |
| 443 const SkColor tab_color = | 443 const SkColor tab_color = |
| 444 GetColor(ThemeProperties::COLOR_TOOLBAR, incognito); | 444 GetColor(ThemeProperties::COLOR_TOOLBAR, incognito); |
| 445 const int frame_id = (id == ThemeProperties::COLOR_TOOLBAR_TOP_SEPARATOR) | 445 const int frame_id = (id == ThemeProperties::COLOR_TOOLBAR_TOP_SEPARATOR) |
| 446 ? ThemeProperties::COLOR_FRAME | 446 ? ThemeProperties::COLOR_FRAME |
| 447 : ThemeProperties::COLOR_FRAME_INACTIVE; | 447 : ThemeProperties::COLOR_FRAME_INACTIVE; |
| (...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 875 | 875 |
| 876 #if BUILDFLAG(ENABLE_SUPERVISED_USERS) | 876 #if BUILDFLAG(ENABLE_SUPERVISED_USERS) |
| 877 bool ThemeService::IsSupervisedUser() const { | 877 bool ThemeService::IsSupervisedUser() const { |
| 878 return profile_->IsSupervised(); | 878 return profile_->IsSupervised(); |
| 879 } | 879 } |
| 880 | 880 |
| 881 void ThemeService::SetSupervisedUserTheme() { | 881 void ThemeService::SetSupervisedUserTheme() { |
| 882 SetCustomDefaultTheme(new SupervisedUserTheme); | 882 SetCustomDefaultTheme(new SupervisedUserTheme); |
| 883 } | 883 } |
| 884 #endif | 884 #endif |
| OLD | NEW |