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

Side by Side Diff: ui/message_center/message_center_style.h

Issue 23462005: Adds the contextMessage field to notifications. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Adjust unit test due to bugfix in toast layout. Created 7 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_ 5 #ifndef UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_
6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_ 6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "third_party/skia/include/core/SkColor.h" 9 #include "third_party/skia/include/core/SkColor.h"
10 #include "ui/gfx/size.h" 10 #include "ui/gfx/size.h"
(...skipping 25 matching lines...) Expand all
36 // Within a notification /////////////////////////////////////////////////////// 36 // Within a notification ///////////////////////////////////////////////////////
37 37
38 // DIP dimensions (H = horizontal, V = vertical). 38 // DIP dimensions (H = horizontal, V = vertical).
39 extern const int kControlButtonSize; // Square size of close & expand buttons. 39 extern const int kControlButtonSize; // Square size of close & expand buttons.
40 extern const int kIconToTextPadding; // H space between icon & title/message. 40 extern const int kIconToTextPadding; // H space between icon & title/message.
41 extern const int kTextTopPadding; // V space between text elements. 41 extern const int kTextTopPadding; // V space between text elements.
42 extern const int kIconBottomPadding; // Minimum non-zero V space between icon 42 extern const int kIconBottomPadding; // Minimum non-zero V space between icon
43 // and frame. 43 // and frame.
44 44
45 // Text sizes. 45 // Text sizes.
46 extern const int kTitleFontSize; // For title only. 46 extern const int kTitleFontSize; // For title only.
47 extern const int kTitleLineHeight; // In DIPs. 47 extern const int kTitleLineHeight; // In DIPs.
48 extern const int kMessageFontSize; // For everything but title. 48 extern const int kMessageFontSize; // For everything but title.
49 extern const int kMessageLineHeight; // In DIPs. 49 extern const int kMessageLineHeight; // In DIPs.
50 50
51 // Colors. 51 // Colors.
52 extern const SkColor kNotificationBackgroundColor; // Background of the card. 52 extern const SkColor kNotificationBackgroundColor; // Background of the card.
53 extern const SkColor kLegacyIconBackgroundColor; // Used behind icons smaller. 53 extern const SkColor kLegacyIconBackgroundColor; // Used behind icons smaller.
54 // than the icon view. 54 // than the icon view.
55 extern const SkColor kRegularTextColor; // Title, message, ... 55 extern const SkColor kRegularTextColor; // Title, message, ...
56 extern const SkColor kDimTextColor; 56 extern const SkColor kDimTextColor;
57 extern const SkColor kFocusBorderColor; // The focus border. 57 extern const SkColor kFocusBorderColor; // The focus border.
58 58
59 // Limits. 59 // Limits.
60 60
61 // Given the size of an image, returns the rect the image should be displayed 61 // Given the size of an image, returns the rect the image should be displayed
62 // in, centered. 62 // in, centered.
63 gfx::Size GetImageSizeForWidth(int width, const gfx::Size& image_size); 63 gfx::Size GetImageSizeForWidth(int width, const gfx::Size& image_size);
64 64
65 extern const int kNotificationMaximumImageHeight; // For image notifications. 65 extern const int kNotificationMaximumImageHeight; // For image notifications.
66 extern const size_t kNotificationMaximumItems; // For list notifications. 66 extern const size_t kNotificationMaximumItems; // For list notifications.
67 67
(...skipping 16 matching lines...) Expand all
84 const int kProgressBarThickness = 5; 84 const int kProgressBarThickness = 5;
85 const int kProgressBarTopPadding = 16; 85 const int kProgressBarTopPadding = 16;
86 const int kProgressBarCornerRadius = 3; 86 const int kProgressBarCornerRadius = 3;
87 const SkColor kProgressBarBackgroundColor = SkColorSetRGB(216, 216, 216); 87 const SkColor kProgressBarBackgroundColor = SkColorSetRGB(216, 216, 216);
88 const SkColor kProgressBarSliceColor = SkColorSetRGB(120, 120, 120); 88 const SkColor kProgressBarSliceColor = SkColorSetRGB(120, 120, 120);
89 89
90 // Line limits. 90 // Line limits.
91 const int kTitleLineLimit = 3; 91 const int kTitleLineLimit = 3;
92 const int kMessageCollapsedLineLimit = 3; 92 const int kMessageCollapsedLineLimit = 3;
93 const int kMessageExpandedLineLimit = 7; 93 const int kMessageExpandedLineLimit = 7;
94 const int kContextMessageLineLimit = 1;
94 95
95 // Around notifications //////////////////////////////////////////////////////// 96 // Around notifications ////////////////////////////////////////////////////////
96 97
97 // DIP dimensions (H = horizontal, V = vertical). 98 // DIP dimensions (H = horizontal, V = vertical).
98 MESSAGE_CENTER_EXPORT extern const int kMarginBetweenItems; // H & V space 99 MESSAGE_CENTER_EXPORT extern const int kMarginBetweenItems; // H & V space
99 // around & between 100 // around & between
100 // notifications. 101 // notifications.
101 102
102 // Colors. 103 // Colors.
103 extern const SkColor kBackgroundLightColor; // Behind notifications, gradient 104 extern const SkColor kBackgroundLightColor; // Behind notifications, gradient
104 extern const SkColor kBackgroundDarkColor; // from light to dark. 105 extern const SkColor kBackgroundDarkColor; // from light to dark.
105 106
106 extern const SkColor kShadowColor; // Shadow in the tray. 107 extern const SkColor kShadowColor; // Shadow in the tray.
107 108
108 extern const SkColor kMessageCenterBackgroundColor; 109 extern const SkColor kMessageCenterBackgroundColor;
109 extern const SkColor kFooterDelimiterColor; // Separator color for the tray. 110 extern const SkColor kFooterDelimiterColor; // Separator color for the tray.
110 extern const SkColor kFooterTextColor; // Text color for tray labels. 111 extern const SkColor kFooterTextColor; // Text color for tray labels.
111 112
112 } // namespace message_center 113 } // namespace message_center
113 114
114 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_ 115 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_STYLE_H_
OLDNEW
« no previous file with comments | « ui/message_center/cocoa/popup_collection_unittest.mm ('k') | ui/message_center/message_center_style.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698