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

Side by Side Diff: chrome/browser/ui/cocoa/autofill/autofill_suggestion_container.mm

Issue 18355002: Move HyperlinkButtonCell to /ui/base/cocoa/controls. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: helpful comment Created 7 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/ui/cocoa/autofill/autofill_suggestion_container.h" 5 #import "chrome/browser/ui/cocoa/autofill/autofill_suggestion_container.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
11 #include "base/mac/scoped_nsobject.h" 11 #include "base/mac/scoped_nsobject.h"
12 #include "base/strings/sys_string_conversions.h" 12 #include "base/strings/sys_string_conversions.h"
13 #include "chrome/browser/ui/autofill/autofill_dialog_controller.h" 13 #include "chrome/browser/ui/autofill/autofill_dialog_controller.h"
14 #include "chrome/browser/ui/chrome_style.h" 14 #include "chrome/browser/ui/chrome_style.h"
15 #import "chrome/browser/ui/cocoa/autofill/autofill_textfield.h" 15 #import "chrome/browser/ui/cocoa/autofill/autofill_textfield.h"
16 #import "chrome/browser/ui/cocoa/hyperlink_button_cell.h"
17 #include "skia/ext/skia_utils_mac.h" 16 #include "skia/ext/skia_utils_mac.h"
18 17
19 namespace { 18 namespace {
20 19
21 // Horizontal padding between text and other elements (in pixels). 20 // Horizontal padding between text and other elements (in pixels).
22 const int kAroundTextPadding = 4; 21 const int kAroundTextPadding = 4;
23 22
24 // Vertical padding between individual elements. 23 // Vertical padding between individual elements.
25 const int kVerticalPadding = 8; 24 const int kVerticalPadding = 8;
26 25
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 } 167 }
169 168
170 [label_ setFrame:labelFrame]; 169 [label_ setFrame:labelFrame];
171 [label2_ setFrameOrigin:NSMakePoint( 170 [label2_ setFrameOrigin:NSMakePoint(
172 0, 171 0,
173 NSMinY(lineFrame) - kAroundTextPadding - NSHeight([label2_ frame]))]; 172 NSMinY(lineFrame) - kAroundTextPadding - NSHeight([label2_ frame]))];
174 [[self view] setFrameSize:preferredContainerSize]; 173 [[self view] setFrameSize:preferredContainerSize];
175 } 174 }
176 175
177 @end 176 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698