Chromium Code Reviews| Index: chrome/browser/cocoa/info_bubble_view.mm |
| =================================================================== |
| --- chrome/browser/cocoa/info_bubble_view.mm (revision 43634) |
| +++ chrome/browser/cocoa/info_bubble_view.mm (working copy) |
| @@ -92,4 +92,22 @@ |
| } |
| } |
| +- (NSPoint)arrowTip { |
| + NSRect bounds = [self bounds]; |
| + NSPoint arrowTip = NSMakePoint(NSMaxX(bounds), NSMaxY(bounds)); |
|
Scott Hess - ex-Googler
2010/04/05 23:07:16
If kTopLeft, arrowTip.x should be NSMinX(bounds) +
mrossetti
2012/05/14 21:35:09
Done.
|
| + CGFloat tipXOffset = kBubbleArrowXOffset + kBubbleArrowWidth / 2.0; |
| + switch (arrowLocation_) { |
| + case kTopLeft: |
| + arrowTip.x = tipXOffset; |
| + break; |
| + case kTopRight: |
| + arrowTip.x -= tipXOffset; |
| + break; |
| + default: |
| + NOTREACHED(); |
| + break; |
| + } |
| + return arrowTip; |
| +} |
| + |
| @end |