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

Unified Diff: ui/message_center/cocoa/notification_controller.mm

Issue 16075002: mac: Make notification text colors match views. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/message_center/message_center_style.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/message_center/cocoa/notification_controller.mm
diff --git a/ui/message_center/cocoa/notification_controller.mm b/ui/message_center/cocoa/notification_controller.mm
index 1402cf81cdd09b1c7357b4770fd1b7f4a84b3ee9..fb99ce970d44b055a638612b108958d51b0419a7 100644
--- a/ui/message_center/cocoa/notification_controller.mm
+++ b/ui/message_center/cocoa/notification_controller.mm
@@ -62,9 +62,10 @@
frame.size.width -= offsetX;
NSDictionary* attributes = @{
- NSFontAttributeName : [title attribute:NSFontAttributeName
- atIndex:0
- effectiveRange:NULL],
+ NSFontAttributeName :
+ [title attribute:NSFontAttributeName atIndex:0 effectiveRange:NULL],
+ NSForegroundColorAttributeName :
+ gfx::SkColorToDeviceNSColor(message_center::kRegularTextColor),
};
[[title string] drawWithRect:frame
options:(NSStringDrawingUsesLineFragmentOrigin |
@@ -344,6 +345,8 @@
frame.size.height = 0;
title_.reset([self newLabelWithFrame:frame]);
[title_ setAutoresizingMask:NSViewMinYMargin];
+ [title_ setTextColor:gfx::SkColorToCalibratedNSColor(
+ message_center::kRegularTextColor)];
[title_ setFont:[NSFont messageFontOfSize:message_center::kTitleFontSize]];
}
@@ -352,6 +355,8 @@
frame.size.height = 0;
message_.reset([self newLabelWithFrame:frame]);
[message_ setAutoresizingMask:NSViewMinYMargin];
+ [message_ setTextColor:gfx::SkColorToCalibratedNSColor(
+ message_center::kDimTextColor)];
[message_ setFont:
[NSFont messageFontOfSize:message_center::kMessageFontSize]];
}
@@ -362,8 +367,6 @@
[label setBezeled:NO];
[label setEditable:NO];
[label setSelectable:NO];
- [label setTextColor:gfx::SkColorToCalibratedNSColor(
- message_center::kRegularTextColor)];
return label;
}
« no previous file with comments | « no previous file | ui/message_center/message_center_style.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698