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

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

Issue 23462005: Adds the contextMessage field to notifications. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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 #include "ui/message_center/message_center_style.h" 5 #include "ui/message_center/message_center_style.h"
6 6
7 namespace message_center { 7 namespace message_center {
8 8
9 // Exported values ///////////////////////////////////////////////////////////// 9 // Exported values /////////////////////////////////////////////////////////////
10 10
(...skipping 20 matching lines...) Expand all
31 const int kNotificationWidth = 360; 31 const int kNotificationWidth = 360;
32 const int kIconToTextPadding = 16; 32 const int kIconToTextPadding = 16;
33 const int kTextTopPadding = 12; 33 const int kTextTopPadding = 12;
34 const int kIconBottomPadding = 16; 34 const int kIconBottomPadding = 16;
35 35
36 // Text sizes. 36 // Text sizes.
37 const int kTitleFontSize = 14; 37 const int kTitleFontSize = 14;
38 const int kTitleLineHeight = 20; 38 const int kTitleLineHeight = 20;
39 const int kMessageFontSize = 12; 39 const int kMessageFontSize = 12;
40 const int kMessageLineHeight = 18; 40 const int kMessageLineHeight = 18;
41 const int kContextMessageFontSize = 12;
42 const int kContextMessageLineHeight = 18;
41 43
42 // Colors. 44 // Colors.
43 const SkColor kNotificationBackgroundColor = SkColorSetRGB(255, 255, 255); 45 const SkColor kNotificationBackgroundColor = SkColorSetRGB(255, 255, 255);
44 const SkColor kLegacyIconBackgroundColor = SkColorSetRGB(0xf5, 0xf5, 0xf5); 46 const SkColor kLegacyIconBackgroundColor = SkColorSetRGB(0xf5, 0xf5, 0xf5);
45 const SkColor kRegularTextColor = SkColorSetRGB(34, 34, 34); 47 const SkColor kRegularTextColor = SkColorSetRGB(34, 34, 34);
46 const SkColor kDimTextColor = SkColorSetRGB(102, 102, 102); 48 const SkColor kDimTextColor = SkColorSetRGB(102, 102, 102);
49 const SkColor kContextTextColor = SkColorSetRGB(80, 80, 80);
47 const SkColor kFocusBorderColor = SkColorSetRGB(64, 128, 250); 50 const SkColor kFocusBorderColor = SkColorSetRGB(64, 128, 250);
48 51
49 // Limits. 52 // Limits.
50 53
51 gfx::Size GetImageSizeForWidth(int width, const gfx::Size& image_size) { 54 gfx::Size GetImageSizeForWidth(int width, const gfx::Size& image_size) {
52 const int kNotificationMaximumImageHeight = 55 const int kNotificationMaximumImageHeight =
53 kNotificationWidth * kNotificationPreferredImageRatio; 56 kNotificationWidth * kNotificationPreferredImageRatio;
54 57
55 gfx::Size size = image_size; 58 gfx::Size size = image_size;
56 if (width > 0 && !size.IsEmpty()) { 59 if (width > 0 && !size.IsEmpty()) {
(...skipping 20 matching lines...) Expand all
77 80
78 // Colors. 81 // Colors.
79 const SkColor kBackgroundLightColor = SkColorSetRGB(0xf1, 0xf1, 0xf1); 82 const SkColor kBackgroundLightColor = SkColorSetRGB(0xf1, 0xf1, 0xf1);
80 const SkColor kBackgroundDarkColor = SkColorSetRGB(0xe7, 0xe7, 0xe7); 83 const SkColor kBackgroundDarkColor = SkColorSetRGB(0xe7, 0xe7, 0xe7);
81 const SkColor kShadowColor = SkColorSetARGB(0.3 * 255, 0, 0, 0); 84 const SkColor kShadowColor = SkColorSetARGB(0.3 * 255, 0, 0, 0);
82 const SkColor kMessageCenterBackgroundColor = SkColorSetRGB(0xee, 0xee, 0xee); 85 const SkColor kMessageCenterBackgroundColor = SkColorSetRGB(0xee, 0xee, 0xee);
83 const SkColor kFooterDelimiterColor = SkColorSetRGB(0xcc, 0xcc, 0xcc); 86 const SkColor kFooterDelimiterColor = SkColorSetRGB(0xcc, 0xcc, 0xcc);
84 const SkColor kFooterTextColor = SkColorSetRGB(0x7b, 0x7b, 0x7b); 87 const SkColor kFooterTextColor = SkColorSetRGB(0x7b, 0x7b, 0x7b);
85 88
86 } // namespace message_center 89 } // namespace message_center
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698