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

Side by Side Diff: ui/views/style/platform_style_mac.mm

Issue 2411693002: views: add focus ring to TreeView (Closed)
Patch Set: rebase 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.cc ('k') | no next file » | 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 "ui/base/resource/resource_bundle.h" 8 #include "ui/base/resource/resource_bundle.h"
9 #include "ui/gfx/color_utils.h" 9 #include "ui/gfx/color_utils.h"
10 #include "ui/gfx/paint_vector_icon.h" 10 #include "ui/gfx/paint_vector_icon.h"
11 #include "ui/gfx/vector_icons_public.h" 11 #include "ui/gfx/vector_icons_public.h"
12 #include "ui/resources/grit/ui_resources.h" 12 #include "ui/resources/grit/ui_resources.h"
13 #include "ui/views/controls/button/label_button.h" 13 #include "ui/views/controls/button/label_button.h"
14 #import "ui/views/controls/scrollbar/cocoa_scroll_bar.h" 14 #import "ui/views/controls/scrollbar/cocoa_scroll_bar.h"
15 15
16 #import <Cocoa/Cocoa.h> 16 #import <Cocoa/Cocoa.h>
17 17
18 namespace views { 18 namespace views {
19 19
20 const int PlatformStyle::kComboboxNormalArrowPadding = 0; 20 const int PlatformStyle::kComboboxNormalArrowPadding = 0;
21 const int PlatformStyle::kMinLabelButtonWidth = 32; 21 const int PlatformStyle::kMinLabelButtonWidth = 32;
22 const int PlatformStyle::kMinLabelButtonHeight = 30; 22 const int PlatformStyle::kMinLabelButtonHeight = 30;
23 const bool PlatformStyle::kDefaultLabelButtonHasBoldFont = false; 23 const bool PlatformStyle::kDefaultLabelButtonHasBoldFont = false;
24 const bool PlatformStyle::kDialogDefaultButtonCanBeCancel = false; 24 const bool PlatformStyle::kDialogDefaultButtonCanBeCancel = false;
25 const bool PlatformStyle::kTextfieldDragVerticallyDragsToEnd = true; 25 const bool PlatformStyle::kTextfieldDragVerticallyDragsToEnd = true;
26 const bool PlatformStyle::kTreeViewHasFocusRing = true;
26 const bool PlatformStyle::kTreeViewSelectionPaintsEntireRow = true; 27 const bool PlatformStyle::kTreeViewSelectionPaintsEntireRow = true;
27 const bool PlatformStyle::kUseRipples = false; 28 const bool PlatformStyle::kUseRipples = false;
28 29
29 const CustomButton::NotifyAction PlatformStyle::kMenuNotifyActivationAction = 30 const CustomButton::NotifyAction PlatformStyle::kMenuNotifyActivationAction =
30 CustomButton::NOTIFY_ON_PRESS; 31 CustomButton::NOTIFY_ON_PRESS;
31 32
32 // static 33 // static
33 gfx::ImageSkia PlatformStyle::CreateComboboxArrow(bool is_enabled, 34 gfx::ImageSkia PlatformStyle::CreateComboboxArrow(bool is_enabled,
34 Combobox::Style style) { 35 Combobox::Style style) {
35 // TODO(ellyjones): IDR_MENU_DROPARROW is a cross-platform image that doesn't 36 // TODO(ellyjones): IDR_MENU_DROPARROW is a cross-platform image that doesn't
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 ButtonColorByState& colors = *color_by_state; 71 ButtonColorByState& colors = *color_by_state;
71 colors[Button::STATE_PRESSED] = SK_ColorWHITE; 72 colors[Button::STATE_PRESSED] = SK_ColorWHITE;
72 } 73 }
73 74
74 // static 75 // static
75 void PlatformStyle::OnTextfieldEditFailed() { 76 void PlatformStyle::OnTextfieldEditFailed() {
76 NSBeep(); 77 NSBeep();
77 } 78 }
78 79
79 } // namespace views 80 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/style/platform_style.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698