| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 #import "chrome/browser/cocoa/bubble_view.h" | 5 #import "chrome/browser/cocoa/bubble_view.h" |
| 6 | 6 |
| 7 #import "third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.h" | 7 #import "third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.h" |
| 8 #import "third_party/GTM/AppKit/GTMNSColor+Luminance.h" | 8 #import "third_party/GTM/AppKit/GTMNSColor+Luminance.h" |
| 9 #import "third_party/GTM/AppKit/GTMTheme.h" | 9 #import "third_party/GTM/AppKit/GTMTheme.h" |
| 10 | 10 |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 | 100 |
| 101 [[NSColor colorWithDeviceWhite:kWindowEdge alpha:1.0f] set]; | 101 [[NSColor colorWithDeviceWhite:kWindowEdge alpha:1.0f] set]; |
| 102 [border stroke]; | 102 [border stroke]; |
| 103 | 103 |
| 104 // Text | 104 // Text |
| 105 NSColor* textColor = [theme textColorForStyle:GTMThemeStyleToolBar | 105 NSColor* textColor = [theme textColorForStyle:GTMThemeStyleToolBar |
| 106 state:GTMThemeStateActiveWindow]; | 106 state:GTMThemeStateActiveWindow]; |
| 107 NSFont* textFont = [self font]; | 107 NSFont* textFont = [self font]; |
| 108 scoped_nsobject<NSShadow> textShadow([[NSShadow alloc] init]); | 108 scoped_nsobject<NSShadow> textShadow([[NSShadow alloc] init]); |
| 109 [textShadow setShadowBlurRadius:0.0f]; | 109 [textShadow setShadowBlurRadius:0.0f]; |
| 110 [textShadow setShadowColor:[textColor gtm_legibleTextColor]]; | 110 [textShadow.get() setShadowColor:[textColor gtm_legibleTextColor]]; |
| 111 [textShadow setShadowOffset:NSMakeSize(0.0f, -1.0f)]; | 111 [textShadow.get() setShadowOffset:NSMakeSize(0.0f, -1.0f)]; |
| 112 | 112 |
| 113 NSDictionary* textDict = [NSDictionary dictionaryWithObjectsAndKeys: | 113 NSDictionary* textDict = [NSDictionary dictionaryWithObjectsAndKeys: |
| 114 textColor, NSForegroundColorAttributeName, | 114 textColor, NSForegroundColorAttributeName, |
| 115 textFont, NSFontAttributeName, | 115 textFont, NSFontAttributeName, |
| 116 textShadow.get(), NSShadowAttributeName, | 116 textShadow.get(), NSShadowAttributeName, |
| 117 nil]; | 117 nil]; |
| 118 [content_ drawAtPoint:NSMakePoint(kBubbleViewTextPositionX, | 118 [content_ drawAtPoint:NSMakePoint(kBubbleViewTextPositionX, |
| 119 kBubbleViewTextPositionY) | 119 kBubbleViewTextPositionY) |
| 120 withAttributes:textDict]; | 120 withAttributes:textDict]; |
| 121 } | 121 } |
| 122 | 122 |
| 123 @end | 123 @end |
| OLD | NEW |