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

Side by Side Diff: ui/message_center/views/notification_view.cc

Issue 14050005: Updated notification text color. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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
« no previous file with comments | « ui/message_center/message_center_constants.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 (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/views/notification_view.h" 5 #include "ui/message_center/views/notification_view.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
9 #include "grit/ui_resources.h" 9 #include "grit/ui_resources.h"
10 #include "ui/base/accessibility/accessible_view_state.h" 10 #include "ui/base/accessibility/accessible_view_state.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 // Character limit = pixels per line * line limit / min. pixels per character. 55 // Character limit = pixels per line * line limit / min. pixels per character.
56 const size_t kTitleCharacterLimit = 56 const size_t kTitleCharacterLimit =
57 message_center::kNotificationWidth * kTitleLineLimit / 4; 57 message_center::kNotificationWidth * kTitleLineLimit / 4;
58 const size_t kMessageCharacterLimit = 58 const size_t kMessageCharacterLimit =
59 message_center::kNotificationWidth * kMessageExpandedLineLimit / 3; 59 message_center::kNotificationWidth * kMessageExpandedLineLimit / 3;
60 60
61 // Notification colors. The text background colors below are used only to keep 61 // Notification colors. The text background colors below are used only to keep
62 // view::Label from modifying the text color and will not actually be drawn. 62 // view::Label from modifying the text color and will not actually be drawn.
63 // See view::Label's SetEnabledColor() and SetBackgroundColor() for details. 63 // See view::Label's SetEnabledColor() and SetBackgroundColor() for details.
64 const SkColor kRegularTextBackgroundColor = SK_ColorWHITE; 64 const SkColor kRegularTextBackgroundColor = SK_ColorWHITE;
65 const SkColor kDimTextColor = SkColorSetRGB(136, 136, 136); 65 const SkColor kDimTextColor = SkColorSetRGB(102, 102, 102);
66 const SkColor kDimTextBackgroundColor = SK_ColorBLACK; 66 const SkColor kDimTextBackgroundColor = SK_ColorBLACK;
67 const SkColor kButtonSeparatorColor = SkColorSetRGB(234, 234, 234); 67 const SkColor kButtonSeparatorColor = SkColorSetRGB(234, 234, 234);
68 const SkColor kHoveredButtonBackgroundColor = SkColorSetRGB(243, 243, 243); 68 const SkColor kHoveredButtonBackgroundColor = SkColorSetRGB(243, 243, 243);
69 69
70 // static 70 // static
71 views::Background* MakeBackground( 71 views::Background* MakeBackground(
72 SkColor color = message_center::kNotificationBackgroundColor) { 72 SkColor color = message_center::kNotificationBackgroundColor) {
73 return views::Background::CreateSolidBackground(color); 73 return views::Background::CreateSolidBackground(color);
74 } 74 }
75 75
(...skipping 547 matching lines...) Expand 10 before | Expand all | Expand 10 after
623 return message_view_ ? 623 return message_view_ ?
624 message_view_->GetLinesForWidthAndLimit(width, limit) : 0; 624 message_view_->GetLinesForWidthAndLimit(width, limit) : 0;
625 } 625 }
626 626
627 int NotificationView::GetMessageHeight(int width, int limit) { 627 int NotificationView::GetMessageHeight(int width, int limit) {
628 return message_view_ ? 628 return message_view_ ?
629 message_view_->GetSizeForWidthAndLines(width, limit).height() : 0; 629 message_view_->GetSizeForWidthAndLines(width, limit).height() : 0;
630 } 630 }
631 631
632 } // namespace message_center 632 } // namespace message_center
OLDNEW
« no previous file with comments | « ui/message_center/message_center_constants.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698