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

Side by Side Diff: ui/views/style/platform_style.h

Issue 2358913006: views: remove PlatformStyle::CreateLabelButtonBorder (Closed)
Patch Set: Created 4 years, 2 months 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 unified diff | Download patch
OLDNEW
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 #ifndef UI_VIEWS_STYLE_PLATFORM_STYLE_H_ 5 #ifndef UI_VIEWS_STYLE_PLATFORM_STYLE_H_
6 #define UI_VIEWS_STYLE_PLATFORM_STYLE_H_ 6 #define UI_VIEWS_STYLE_PLATFORM_STYLE_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 static gfx::ImageSkia CreateComboboxArrow(bool is_enabled, 63 static gfx::ImageSkia CreateComboboxArrow(bool is_enabled,
64 Combobox::Style style); 64 Combobox::Style style);
65 65
66 // Creates the appropriate border for a focusable Combobox. 66 // Creates the appropriate border for a focusable Combobox.
67 static std::unique_ptr<FocusableBorder> CreateComboboxBorder(); 67 static std::unique_ptr<FocusableBorder> CreateComboboxBorder();
68 68
69 // Creates the appropriate background for a Combobox. 69 // Creates the appropriate background for a Combobox.
70 static std::unique_ptr<Background> CreateComboboxBackground( 70 static std::unique_ptr<Background> CreateComboboxBackground(
71 int shoulder_width); 71 int shoulder_width);
72 72
73 // Creates the default label button border for the given |style|. Used when a
74 // custom default border is not provided for a particular LabelButton class.
75 static std::unique_ptr<LabelButtonBorder> CreateLabelButtonBorder(
sky 2016/09/23 15:47:39 Is there any includes/forward declarations no long
76 Button::ButtonStyle style);
77
78 // Creates the default scrollbar for the given orientation. 73 // Creates the default scrollbar for the given orientation.
79 static std::unique_ptr<ScrollBar> CreateScrollBar(bool is_horizontal); 74 static std::unique_ptr<ScrollBar> CreateScrollBar(bool is_horizontal);
80 75
81 // Returns the current text color for the current button state. 76 // Returns the current text color for the current button state.
82 static SkColor TextColorForButton(const ButtonColorByState& color_by_state, 77 static SkColor TextColorForButton(const ButtonColorByState& color_by_state,
83 const LabelButton& button); 78 const LabelButton& button);
84 79
85 // Applies platform styles to |label| and fills |color_by_state| with the text 80 // Applies platform styles to |label| and fills |color_by_state| with the text
86 // colors for normal, pressed, hovered, and disabled states, if the colors for 81 // colors for normal, pressed, hovered, and disabled states, if the colors for
87 // Button::STYLE_BUTTON buttons differ from those provided by ui::NativeTheme. 82 // Button::STYLE_BUTTON buttons differ from those provided by ui::NativeTheme.
88 static void ApplyLabelButtonTextStyle(Label* label, 83 static void ApplyLabelButtonTextStyle(Label* label,
89 ButtonColorByState* color_by_state); 84 ButtonColorByState* color_by_state);
90 85
91 // Applies the current system theme to the default border created by |button|. 86 // Applies the current system theme to the default border created by |button|.
92 static std::unique_ptr<Border> CreateThemedLabelButtonBorder( 87 static std::unique_ptr<Border> CreateThemedLabelButtonBorder(
93 LabelButton* button); 88 LabelButton* button);
94 89
95 // Called whenever a textfield keypress is unhandled for any reason. Gives 90 // Called whenever a textfield keypress is unhandled for any reason. Gives
96 // visual/audio feedback about the unhandled key if platform-appropriate. 91 // visual/audio feedback about the unhandled key if platform-appropriate.
97 static void OnTextfieldKeypressUnhandled(); 92 static void OnTextfieldKeypressUnhandled();
98 93
99 private: 94 private:
100 DISALLOW_IMPLICIT_CONSTRUCTORS(PlatformStyle); 95 DISALLOW_IMPLICIT_CONSTRUCTORS(PlatformStyle);
101 }; 96 };
102 97
103 } // namespace views 98 } // namespace views
104 99
105 #endif // UI_VIEWS_STYLE_PLATFORM_STYLE_H_ 100 #endif // UI_VIEWS_STYLE_PLATFORM_STYLE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698