| 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 "ui/base/native_theme/native_theme_aura.h" | 5 #include "ui/base/native_theme/native_theme_aura.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "grit/ui_resources.h" | 8 #include "grit/ui_resources.h" |
| 9 #include "ui/base/layout.h" | 9 #include "ui/base/layout.h" |
| 10 #include "ui/base/resource/resource_bundle.h" | 10 #include "ui/base/resource/resource_bundle.h" |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 46 SkColorSetARGB(0x54, 0x60, 0xA8, 0xEB); | 46 SkColorSetARGB(0x54, 0x60, 0xA8, 0xEB); |
| 47 const SkColor kTextfieldSelectionBackgroundUnfocused = SK_ColorLTGRAY; | 47 const SkColor kTextfieldSelectionBackgroundUnfocused = SK_ColorLTGRAY; |
| 48 const SkColor kTextfieldSelectionColor = | 48 const SkColor kTextfieldSelectionColor = |
| 49 color_utils::AlphaBlend(SK_ColorBLACK, | 49 color_utils::AlphaBlend(SK_ColorBLACK, |
| 50 kTextfieldSelectionBackgroundFocused, 0xdd); | 50 kTextfieldSelectionBackgroundFocused, 0xdd); |
| 51 | 51 |
| 52 } // namespace | 52 } // namespace |
| 53 | 53 |
| 54 namespace ui { | 54 namespace ui { |
| 55 | 55 |
| 56 #if !defined(OS_WIN) | |
| 57 // static | 56 // static |
| 58 NativeTheme* NativeTheme::instance() { | 57 NativeTheme* NativeTheme::instance() { |
| 59 return NativeThemeAura::instance(); | 58 return NativeThemeAura::instance(); |
| 60 } | 59 } |
| 61 #endif | |
| 62 | 60 |
| 63 // static | 61 // static |
| 64 NativeThemeAura* NativeThemeAura::instance() { | 62 NativeThemeAura* NativeThemeAura::instance() { |
| 65 CR_DEFINE_STATIC_LOCAL(NativeThemeAura, s_native_theme, ()); | 63 CR_DEFINE_STATIC_LOCAL(NativeThemeAura, s_native_theme, ()); |
| 66 return &s_native_theme; | 64 return &s_native_theme; |
| 67 } | 65 } |
| 68 | 66 |
| 69 NativeThemeAura::NativeThemeAura() { | 67 NativeThemeAura::NativeThemeAura() { |
| 70 // We don't draw scrollbar buttons. | 68 // We don't draw scrollbar buttons. |
| 71 set_scrollbar_button_length(0); | 69 set_scrollbar_button_length(0); |
| (...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 289 DrawTiledImage(canvas, *center, | 287 DrawTiledImage(canvas, *center, |
| 290 0, 0, 1.0, 1.0, | 288 0, 0, 1.0, 1.0, |
| 291 rect.x() + left->width(), rect.y(), | 289 rect.x() + left->width(), rect.y(), |
| 292 rect.width() - left->width() - right->width(), | 290 rect.width() - left->width() - right->width(), |
| 293 center->height()); | 291 center->height()); |
| 294 } | 292 } |
| 295 } | 293 } |
| 296 } | 294 } |
| 297 | 295 |
| 298 } // namespace ui | 296 } // namespace ui |
| OLD | NEW |