OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/views/style/platform_style.h" | 5 #include "ui/views/style/platform_style.h" |
6 | 6 |
7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
9 #include "ui/base/material_design/material_design_controller.h" | 9 #include "ui/base/material_design/material_design_controller.h" |
10 #include "ui/base/resource/resource_bundle.h" | 10 #include "ui/base/resource/resource_bundle.h" |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 return base::MakeUnique<NativeScrollBar>(is_horizontal); | 82 return base::MakeUnique<NativeScrollBar>(is_horizontal); |
83 } | 83 } |
84 | 84 |
85 // static | 85 // static |
86 SkColor PlatformStyle::TextColorForButton( | 86 SkColor PlatformStyle::TextColorForButton( |
87 const ButtonColorByState& color_by_state, | 87 const ButtonColorByState& color_by_state, |
88 const LabelButton& button) { | 88 const LabelButton& button) { |
89 return color_by_state[button.state()]; | 89 return color_by_state[button.state()]; |
90 } | 90 } |
91 | 91 |
| 92 // static |
| 93 void PlatformStyle::OnTextfieldKeypressUnhandled() {} |
| 94 |
92 #endif // OS_MACOSX | 95 #endif // OS_MACOSX |
93 | 96 |
94 #if !defined(DESKTOP_LINUX) && !defined(OS_MACOSX) | 97 #if !defined(DESKTOP_LINUX) && !defined(OS_MACOSX) |
95 // static | 98 // static |
96 void PlatformStyle::ApplyLabelButtonTextStyle( | 99 void PlatformStyle::ApplyLabelButtonTextStyle( |
97 Label* label, | 100 Label* label, |
98 ButtonColorByState* color_by_state) { | 101 ButtonColorByState* color_by_state) { |
99 ButtonColorByState& colors = *color_by_state; | 102 ButtonColorByState& colors = *color_by_state; |
100 colors[Button::STATE_NORMAL] = kStyleButtonTextColor; | 103 colors[Button::STATE_NORMAL] = kStyleButtonTextColor; |
101 colors[Button::STATE_HOVERED] = kStyleButtonTextColor; | 104 colors[Button::STATE_HOVERED] = kStyleButtonTextColor; |
(...skipping 10 matching lines...) Expand all Loading... |
112 | 115 |
113 #if !defined(DESKTOP_LINUX) | 116 #if !defined(DESKTOP_LINUX) |
114 // static | 117 // static |
115 std::unique_ptr<Border> PlatformStyle::CreateThemedLabelButtonBorder( | 118 std::unique_ptr<Border> PlatformStyle::CreateThemedLabelButtonBorder( |
116 LabelButton* button) { | 119 LabelButton* button) { |
117 return button->CreateDefaultBorder(); | 120 return button->CreateDefaultBorder(); |
118 } | 121 } |
119 #endif | 122 #endif |
120 | 123 |
121 } // namespace views | 124 } // namespace views |
OLD | NEW |