OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #include "ash/common/system/tray/tray_constants.h" | |
6 | |
7 #include "base/logging.h" | |
8 #include "third_party/skia/include/core/SkColor.h" | |
9 #include "ui/gfx/color_palette.h" | |
10 | |
11 namespace ash { | |
12 | |
13 const int kPaddingFromRightEdgeOfScreenBottomAlignment = 7; | |
14 const int kPaddingFromBottomOfScreenBottomAlignment = 7; | |
15 const int kPaddingFromOuterEdgeOfLauncherVerticalAlignment = 8; | |
16 const int kPaddingFromInnerEdgeOfLauncherVerticalAlignment = 9; | |
17 const int kPaddingFromBottomOfScreenVerticalAlignment = 10; | |
18 | |
19 // Padding used to position the system menu relative to the status area. | |
20 const int kBubblePaddingHorizontalBottom = 6; | |
21 const int kBubblePaddingHorizontalSide = 10; | |
22 const int kBubblePaddingVerticalBottom = 3; | |
23 const int kBubblePaddingVerticalSide = 15; | |
24 | |
25 // Top inset of system tray bubble for bottom anchor alignment. | |
26 const int kTrayBubbleAnchorTopInsetBottomAnchor = 3; | |
27 | |
28 const int kTrayImageItemHorizontalPaddingVerticalAlignment = 1; | |
29 | |
30 // Size of tray items on the primary axis. | |
31 const int kTrayItemSize = 32; | |
32 | |
33 const int kTrayImageItemPadding = 3; | |
34 | |
35 const int kTrayLabelItemHorizontalPaddingBottomAlignment = 7; | |
36 | |
37 // Vertical padding between status tray items when the shelf is vertical. | |
38 const int kTrayLabelItemVerticalPaddingVerticalAlignment = 4; | |
39 | |
40 const int kTrayMenuBottomRowPadding = 3; | |
41 const int kTrayMenuBottomRowPaddingBetweenItems = -1; | |
42 const int kTrayMenuMinimumWidth = 300; | |
43 const int kTrayMenuMinimumWidthMd = 352; | |
44 | |
45 const int kTrayPopupAutoCloseDelayInSeconds = 2; | |
46 const int kTrayPopupAutoCloseDelayForTextInSeconds = 5; | |
47 const int kTrayPopupPaddingHorizontal = 18; | |
48 const int kTrayPopupPaddingBetweenItems = 10; | |
49 const int kTrayPopupButtonEndMargin = 10; | |
50 const int kTrayPopupLabelHorizontalPadding = 4; | |
51 const int kTrayPopupItemMinHeight = 48; | |
52 const int kTrayPopupItemMinStartWidth = 48; | |
53 const int kTrayPopupItemMinEndWidth = | |
54 kMenuIconSize + 2 * kTrayPopupButtonEndMargin; | |
55 | |
56 const int kTrayDetailedViewTransitionDelayMs = 100; | |
57 | |
58 const int kTrayPopupLabelRightPadding = 8; | |
59 | |
60 const int kTrayPopupDetailsIconWidth = 25; | |
61 const int kTrayPopupDetailsLabelExtraLeftMargin = 8; | |
62 const SkColor kTrayPopupHoverBackgroundColor = SkColorSetRGB(0xe4, 0xe4, 0xe4); | |
63 const int kTrayPopupScrollSeparatorHeight = 15; | |
64 const int kTrayRoundedBorderRadius = 2; | |
65 | |
66 const int kTrayToggleButtonWidth = 68; | |
67 | |
68 const SkColor kBackgroundColor = SkColorSetRGB(0xfe, 0xfe, 0xfe); | |
69 const SkColor kHoverBackgroundColor = SkColorSetRGB(0xf3, 0xf3, 0xf3); | |
70 const SkColor kPublicAccountUserCardTextColor = SkColorSetRGB(0x66, 0x66, 0x66); | |
71 const SkColor kPublicAccountUserCardNameColor = SK_ColorBLACK; | |
72 | |
73 const SkColor kHeaderBackgroundColor = SkColorSetRGB(0xf5, 0xf5, 0xf5); | |
74 | |
75 const SkColor kBorderDarkColor = SkColorSetRGB(0xaa, 0xaa, 0xaa); | |
76 const SkColor kBorderLightColor = SkColorSetRGB(0xeb, 0xeb, 0xeb); | |
77 const SkColor kButtonStrokeColor = SkColorSetRGB(0xdd, 0xdd, 0xdd); | |
78 | |
79 const SkColor kHeaderTextColorNormal = SkColorSetARGB(0x7f, 0, 0, 0); | |
80 const SkColor kHeaderTextColorHover = SkColorSetARGB(0xd3, 0, 0, 0); | |
81 | |
82 const int kTrayPopupMinWidth = 300; | |
83 const int kTrayPopupMaxWidth = 500; | |
84 const int kNotificationIconWidth = 40; | |
85 const int kNotificationButtonWidth = 32; | |
86 const int kTrayNotificationContentsWidth = | |
87 kTrayPopupMinWidth - (kNotificationIconWidth + kNotificationButtonWidth + | |
88 (kTrayPopupPaddingHorizontal / 2) * 3); | |
89 | |
90 const int kTrayIconSize = 16; | |
91 const int kTrayEdgePadding = 6; | |
92 const SkColor kTrayIconColor = SK_ColorWHITE; | |
93 const int kMenuIconSize = 20; | |
94 const SkColor kMenuIconColor = gfx::kChromeIconGrey; | |
95 const SkColor kMenuIconColorDisabled = SkColorSetA(gfx::kChromeIconGrey, 0x61); | |
96 const int kMenuButtonSize = 48; | |
97 const int kMenuSeparatorVerticalPadding = 4; | |
98 const int kMenuExtraMarginFromLeftEdge = 4; | |
99 const int kMenuEdgeEffectivePadding = | |
100 kMenuExtraMarginFromLeftEdge + (kMenuButtonSize - kMenuIconSize) / 2; | |
101 | |
102 const int kHitRegionPadding = 4; | |
103 const int kSeparatorWidth = 1; | |
104 | |
105 const SkColor kMenuSeparatorColor = SkColorSetA(SK_ColorBLACK, 0x1F); | |
106 | |
107 const SkColor kTrayPopupInkDropBaseColor = SK_ColorBLACK; | |
108 const float kTrayPopupInkDropRippleOpacity = 0.06f; | |
109 const float kTrayPopupInkDropHighlightOpacity = 0.08f; | |
110 const int kTrayPopupInkDropInset = 4; | |
111 const int kTrayPopupInkDropCornerRadius = 2; | |
112 | |
113 const int kTrayPopupSystemInfoRowHeight = 40; | |
114 | |
115 } // namespace ash | |
OLD | NEW |