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

Unified Diff: chrome/browser/ui/autofill/autofill_popup_controller_impl.cc

Issue 2517843002: Http Bad: Put icon on the left of http warning message on Views (Closed)
Patch Set: fix mac Created 4 years 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
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/autofill_popup_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/autofill/autofill_popup_controller_impl.cc
diff --git a/chrome/browser/ui/autofill/autofill_popup_controller_impl.cc b/chrome/browser/ui/autofill/autofill_popup_controller_impl.cc
index bed581f497d3ad993e44911a729682889a250a5d..bcdcaf6fa79b3104cd20d627bffa6840c479085f 100644
--- a/chrome/browser/ui/autofill/autofill_popup_controller_impl.cc
+++ b/chrome/browser/ui/autofill/autofill_popup_controller_impl.cc
@@ -327,7 +327,7 @@ int AutofillPopupControllerImpl::GetElidedValueWidthForRow(size_t row) {
int AutofillPopupControllerImpl::GetElidedLabelWidthForRow(size_t row) {
return gfx::GetStringWidth(GetElidedLabelAt(row),
- layout_model_.GetLabelFontList());
+ layout_model_.GetLabelFontListForRow(row));
}
#endif
@@ -510,8 +510,8 @@ void AutofillPopupControllerImpl::ElideValueAndLabelForRow(
int available_width) {
int value_width = gfx::GetStringWidth(
suggestions_[row].value, layout_model_.GetValueFontListForRow(row));
- int label_width = gfx::GetStringWidth(suggestions_[row].label,
- layout_model_.GetLabelFontList());
+ int label_width = gfx::GetStringWidth(
+ suggestions_[row].label, layout_model_.GetLabelFontListForRow(row));
int total_text_length = value_width + label_width;
// The line can have no strings if it represents a UI element, such as
@@ -526,9 +526,9 @@ void AutofillPopupControllerImpl::ElideValueAndLabelForRow(
value_size, gfx::ELIDE_TAIL);
int label_size = available_width * label_width / total_text_length;
- elided_labels_[row] =
- gfx::ElideText(suggestions_[row].label, layout_model_.GetLabelFontList(),
- label_size, gfx::ELIDE_TAIL);
+ elided_labels_[row] = gfx::ElideText(
+ suggestions_[row].label, layout_model_.GetLabelFontListForRow(row),
+ label_size, gfx::ELIDE_TAIL);
}
#endif
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/autofill_popup_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698