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

Side by Side Diff: chrome/browser/ui/gtk/autofill/autofill_popup_view_gtk.cc

Issue 11817051: Elide text in the new Autofill UI (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 7 years, 11 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "chrome/browser/ui/gtk/autofill/autofill_popup_view_gtk.h" 5 #include "chrome/browser/ui/gtk/autofill/autofill_popup_view_gtk.h"
6 6
7 #include <gdk/gdkkeysyms.h> 7 #include <gdk/gdkkeysyms.h>
8 8
9 #include "base/i18n/rtl.h" 9 #include "base/i18n/rtl.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 int top_of_popup = 0; 319 int top_of_popup = 0;
320 if (screen_height < bottom_of_field + popup_height) { 320 if (screen_height < bottom_of_field + popup_height) {
321 // The popup must appear above the field. 321 // The popup must appear above the field.
322 top_of_popup = controller_->element_bounds().y() - popup_height; 322 top_of_popup = controller_->element_bounds().y() - popup_height;
323 } else { 323 } else {
324 // The popup can appear below the field. 324 // The popup can appear below the field.
325 top_of_popup = bottom_of_field; 325 top_of_popup = bottom_of_field;
326 } 326 }
327 327
328 controller_->SetPopupBounds(gfx::Rect( 328 controller_->SetPopupBounds(gfx::Rect(
329 controller_->element_bounds().x(), 329 controller_->popup_bounds().x(),
330 top_of_popup, 330 top_of_popup,
331 controller_->GetPopupRequiredWidth(), 331 controller_->GetPopupRequiredWidth(),
332 popup_height)); 332 popup_height));
333 } 333 }
334 334
335 AutofillPopupView* AutofillPopupView::Create( 335 AutofillPopupView* AutofillPopupView::Create(
336 AutofillPopupController* controller) { 336 AutofillPopupController* controller) {
337 return new AutofillPopupViewGtk(controller); 337 return new AutofillPopupViewGtk(controller);
338 } 338 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698