| Index: chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_editor.mm
|
| diff --git a/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_editor.mm b/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_editor.mm
|
| index a8214d4425604dbd530206f7bfb07b08325878c4..0021b4012629064171bdc9f0a250cb172dc13c0b 100644
|
| --- a/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_editor.mm
|
| +++ b/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_editor.mm
|
| @@ -39,6 +39,9 @@ bool gInDrag = false;
|
| // so this is conservative.
|
| const NSUInteger kMaxPasteLength = 10000;
|
|
|
| +// How much the text should be offset from its left.
|
| +const CGFloat kTextXOffset = -1.0;
|
| +
|
| // Returns |YES| if too much text would be pasted.
|
| BOOL ThePasteboardIsTooDamnBig() {
|
| NSPasteboard* pb = [NSPasteboard generalPasteboard];
|
| @@ -599,9 +602,15 @@ NSMenuItem* PasteAndGoMenuItemForObserver(
|
| }
|
|
|
| - (void)drawRect:(NSRect)rect {
|
| + gfx::ScopedNSGraphicsContextSaveGState saveGraphicsState;
|
| AutocompleteTextFieldObserver* observer = [self observer];
|
| if (observer)
|
| observer->OnBeforeDrawRect();
|
| +
|
| + NSAffineTransform* transform = [NSAffineTransform transform];
|
| + [transform translateXBy:kTextXOffset yBy:0];
|
| + [transform concat];
|
| +
|
| [super drawRect:rect];
|
| if (observer)
|
| observer->OnDidDrawRect();
|
|
|