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

Unified Diff: chrome/browser/ui/cocoa/autofill/autofill_overlay_controller.mm

Issue 23546007: [rAC, OSX] Namespaced constants. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Once more merge to HEAD 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/cocoa/autofill/autofill_overlay_controller.mm
diff --git a/chrome/browser/ui/cocoa/autofill/autofill_overlay_controller.mm b/chrome/browser/ui/cocoa/autofill/autofill_overlay_controller.mm
index ee15455378759e13829ded9b8ea52b7e968c8051..59216ab33d9c8f654835d499fbfe4e2c1e0b2def 100644
--- a/chrome/browser/ui/cocoa/autofill/autofill_overlay_controller.mm
+++ b/chrome/browser/ui/cocoa/autofill/autofill_overlay_controller.mm
@@ -114,9 +114,9 @@ void OverlayTimerBridge::UpdateOverlayState() {
NSColor* shadingColor = gfx::SkColorToCalibratedNSColor(kShadingColor);
NSColor* borderColor = gfx::SkColorToCalibratedNSColor(kSubtleBorderColor);
- CGFloat arrowHalfWidth = kArrowWidth / 2.0;
+ CGFloat arrowHalfWidth = autofill::kArrowWidth / 2.0;
NSRect bounds = [self bounds];
- CGFloat y = NSMaxY(bounds) - kArrowHeight;
+ CGFloat y = NSMaxY(bounds) - autofill::kArrowHeight;
NSBezierPath* arrow = [NSBezierPath bezierPath];
// Note that we purposely draw slightly outside of |bounds| so that the
@@ -126,8 +126,10 @@ void OverlayTimerBridge::UpdateOverlayState() {
[arrow moveToPoint:NSMakePoint(NSMinX(arrowBounds), y)];
[arrow lineToPoint:
NSMakePoint(NSMidX(arrowBounds) - arrowHalfWidth, y)];
- [arrow relativeLineToPoint:NSMakePoint(arrowHalfWidth, kArrowHeight)];
- [arrow relativeLineToPoint:NSMakePoint(arrowHalfWidth, -kArrowHeight)];
+ [arrow relativeLineToPoint:
+ NSMakePoint(arrowHalfWidth,autofill::kArrowHeight)];
+ [arrow relativeLineToPoint:
+ NSMakePoint(arrowHalfWidth, -autofill::kArrowHeight)];
[arrow lineToPoint:NSMakePoint(NSMaxX(arrowBounds), y)];
[arrow lineToPoint:NSMakePoint(NSMaxX(arrowBounds), NSMinY(arrowBounds))];
[arrow lineToPoint:NSMakePoint(NSMinX(arrowBounds), NSMinY(arrowBounds))];
@@ -145,7 +147,7 @@ void OverlayTimerBridge::UpdateOverlayState() {
height += NSHeight([label frame]);
height += kOverlayTextInterlineSpacing;
}
- return height + kArrowHeight;
+ return height + autofill::kArrowHeight;
}
- (void)setMessages:
@@ -175,8 +177,8 @@ void OverlayTimerBridge::UpdateOverlayState() {
}
- (void)performLayout {
- CGFloat y =
- NSMaxY([self bounds]) - kArrowHeight - kOverlayTextInterlineSpacing;
+ CGFloat y = NSMaxY([self bounds]) - autofill::kArrowHeight -
+ kOverlayTextInterlineSpacing;
for (NSTextView* label in [self subviews]) {
DCHECK([label isKindOfClass:[NSTextView class]]);
CGFloat labelHeight = NSHeight([label frame]);

Powered by Google App Engine
This is Rietveld 408576698