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

Side by Side Diff: chrome/browser/ui/autofill/autofill_popup_controller_impl.cc

Issue 2203963002: [Autofill] Credit Card Signin promo: no bg color, no smaller font. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: removed kWarningTextColor Created 4 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/autofill_popup_layout_model.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/autofill/autofill_popup_controller_impl.h" 5 #include "chrome/browser/ui/autofill/autofill_popup_controller_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 364 matching lines...) Expand 10 before | Expand all | Expand 10 after
375 } else { 375 } else {
376 Hide(); 376 Hide();
377 } 377 }
378 378
379 return true; 379 return true;
380 } 380 }
381 381
382 SkColor AutofillPopupControllerImpl::GetBackgroundColorForRow(int index) const { 382 SkColor AutofillPopupControllerImpl::GetBackgroundColorForRow(int index) const {
383 if (index == selected_line_) 383 if (index == selected_line_)
384 return kHoveredBackgroundColor; 384 return kHoveredBackgroundColor;
385 if (suggestions_[index].frontend_id ==
386 POPUP_ITEM_ID_CREDIT_CARD_SIGNIN_PROMO) {
387 return kPromoPopupBackground;
388 }
389 385
390 return SK_ColorTRANSPARENT; 386 return SK_ColorTRANSPARENT;
391 } 387 }
392 388
393 int AutofillPopupControllerImpl::selected_line() const { 389 int AutofillPopupControllerImpl::selected_line() const {
394 return selected_line_; 390 return selected_line_;
395 } 391 }
396 392
397 const AutofillPopupLayoutModel& AutofillPopupControllerImpl::layout_model() 393 const AutofillPopupLayoutModel& AutofillPopupControllerImpl::layout_model()
398 const { 394 const {
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
536 // Don't clear view_, because otherwise the popup will have to get regenerated 532 // Don't clear view_, because otherwise the popup will have to get regenerated
537 // and this will cause flickering. 533 // and this will cause flickering.
538 suggestions_.clear(); 534 suggestions_.clear();
539 elided_values_.clear(); 535 elided_values_.clear();
540 elided_labels_.clear(); 536 elided_labels_.clear();
541 537
542 selected_line_ = kNoSelection; 538 selected_line_ = kNoSelection;
543 } 539 }
544 540
545 } // namespace autofill 541 } // namespace autofill
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/autofill_popup_layout_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698