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

Side by Side Diff: chrome/browser/ui/android/autofill/autofill_popup_view_android.cc

Issue 2496683003: Http Bad: Add a PopupItemId to identify http warning message (Closed)
Patch Set: update Created 4 years, 1 month 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_controller_impl.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/android/autofill/autofill_popup_view_android.h" 5 #include "chrome/browser/ui/android/autofill/autofill_popup_view_android.h"
6 6
7 #include "base/android/jni_android.h" 7 #include "base/android/jni_android.h"
8 #include "base/android/jni_string.h" 8 #include "base/android/jni_string.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "chrome/browser/android/resource_mapper.h" 10 #include "chrome/browser/android/resource_mapper.h"
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 90
91 const Suggestion& suggestion = controller_->GetSuggestionAt(i); 91 const Suggestion& suggestion = controller_->GetSuggestionAt(i);
92 if (!suggestion.icon.empty()) { 92 if (!suggestion.icon.empty()) {
93 android_icon_id = ResourceMapper::MapFromChromiumId( 93 android_icon_id = ResourceMapper::MapFromChromiumId(
94 controller_->layout_model().GetIconResourceID(suggestion.icon)); 94 controller_->layout_model().GetIconResourceID(suggestion.icon));
95 } 95 }
96 96
97 bool deletable = 97 bool deletable =
98 controller_->GetRemovalConfirmationText(i, nullptr, nullptr); 98 controller_->GetRemovalConfirmationText(i, nullptr, nullptr);
99 bool is_label_multiline = 99 bool is_label_multiline =
100 suggestion.frontend_id == POPUP_ITEM_ID_WARNING_MESSAGE || 100 suggestion.frontend_id ==
101 POPUP_ITEM_ID_INSECURE_CONTEXT_PAYMENT_DISABLED_MESSAGE ||
101 suggestion.frontend_id == POPUP_ITEM_ID_CREDIT_CARD_SIGNIN_PROMO; 102 suggestion.frontend_id == POPUP_ITEM_ID_CREDIT_CARD_SIGNIN_PROMO;
102 Java_AutofillPopupBridge_addToAutofillSuggestionArray( 103 Java_AutofillPopupBridge_addToAutofillSuggestionArray(
103 env, data_array, i, value, label, android_icon_id, 104 env, data_array, i, value, label, android_icon_id,
104 suggestion.frontend_id, deletable, is_label_multiline); 105 suggestion.frontend_id, deletable, is_label_multiline);
105 } 106 }
106 107
107 Java_AutofillPopupBridge_show(env, java_object_, data_array, 108 Java_AutofillPopupBridge_show(env, java_object_, data_array,
108 controller_->IsRTL()); 109 controller_->IsRTL());
109 } 110 }
110 111
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 // static 167 // static
167 AutofillPopupView* AutofillPopupView::Create( 168 AutofillPopupView* AutofillPopupView::Create(
168 AutofillPopupController* controller) { 169 AutofillPopupController* controller) {
169 if (IsKeyboardAccessoryEnabled()) 170 if (IsKeyboardAccessoryEnabled())
170 return new AutofillKeyboardAccessoryView(controller); 171 return new AutofillKeyboardAccessoryView(controller);
171 172
172 return new AutofillPopupViewAndroid(controller); 173 return new AutofillPopupViewAndroid(controller);
173 } 174 }
174 175
175 } // namespace autofill 176 } // namespace autofill
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/autofill/autofill_popup_controller_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698