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

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

Issue 2391393002: Harmony - Use FocusableBorder for comboboxes on Mac (Closed)
Patch Set: fix mac 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
« no previous file with comments | « ui/views/style/platform_style.h ('k') | ui/views/style/platform_style_mac.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #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 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 const bool PlatformStyle::kUseRipples = true; 46 const bool PlatformStyle::kUseRipples = true;
47 47
48 // static 48 // static
49 gfx::ImageSkia PlatformStyle::CreateComboboxArrow(bool is_enabled, 49 gfx::ImageSkia PlatformStyle::CreateComboboxArrow(bool is_enabled,
50 Combobox::Style style) { 50 Combobox::Style style) {
51 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); 51 ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance();
52 return *rb.GetImageSkiaNamed(IDR_MENU_DROPARROW); 52 return *rb.GetImageSkiaNamed(IDR_MENU_DROPARROW);
53 } 53 }
54 54
55 // static 55 // static
56 std::unique_ptr<FocusableBorder> PlatformStyle::CreateComboboxBorder() {
57 return base::MakeUnique<FocusableBorder>();
58 }
59
60 // static
61 std::unique_ptr<Background> PlatformStyle::CreateComboboxBackground(
62 int shoulder_width) {
63 return nullptr;
64 }
65
66 // static
67 std::unique_ptr<ScrollBar> PlatformStyle::CreateScrollBar(bool is_horizontal) { 56 std::unique_ptr<ScrollBar> PlatformStyle::CreateScrollBar(bool is_horizontal) {
68 return base::MakeUnique<NativeScrollBar>(is_horizontal); 57 return base::MakeUnique<NativeScrollBar>(is_horizontal);
69 } 58 }
70 59
71 // static 60 // static
72 SkColor PlatformStyle::TextColorForButton( 61 SkColor PlatformStyle::TextColorForButton(
73 const ButtonColorByState& color_by_state, 62 const ButtonColorByState& color_by_state,
74 const LabelButton& button) { 63 const LabelButton& button) {
75 return color_by_state[button.state()]; 64 return color_by_state[button.state()];
76 } 65 }
(...skipping 20 matching lines...) Expand all
97 86
98 #if !defined(DESKTOP_LINUX) 87 #if !defined(DESKTOP_LINUX)
99 // static 88 // static
100 std::unique_ptr<Border> PlatformStyle::CreateThemedLabelButtonBorder( 89 std::unique_ptr<Border> PlatformStyle::CreateThemedLabelButtonBorder(
101 LabelButton* button) { 90 LabelButton* button) {
102 return button->CreateDefaultBorder(); 91 return button->CreateDefaultBorder();
103 } 92 }
104 #endif 93 #endif
105 94
106 } // namespace views 95 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/style/platform_style.h ('k') | ui/views/style/platform_style_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698