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

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillPopupBridge.java

Issue 443193006: Show icons in Android web autofill dropdown (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix indent Created 6 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 side-by-side diff with in-line comments
Download patch
Index: chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillPopupBridge.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillPopupBridge.java b/chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillPopupBridge.java
index 7c2f4271ac9e5976da9c85468b298f3a01f69a4d..dc23e612255e7e5fe69b0c58b2c5dcf582e2c2e2 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillPopupBridge.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/autofill/AutofillPopupBridge.java
@@ -9,6 +9,7 @@ import android.os.Handler;
import org.chromium.base.CalledByNative;
import org.chromium.base.JNINamespace;
+import org.chromium.chrome.browser.ResourceId;
import org.chromium.ui.autofill.AutofillPopup;
import org.chromium.ui.autofill.AutofillPopup.AutofillPopupDelegate;
import org.chromium.ui.autofill.AutofillSuggestion;
@@ -105,8 +106,9 @@ public class AutofillPopupBridge implements AutofillPopupDelegate{
*/
@CalledByNative
private static void addToAutofillSuggestionArray(AutofillSuggestion[] array, int index,
- String label, String sublabel, int uniqueId) {
- array[index] = new AutofillSuggestion(label, sublabel, uniqueId);
+ String label, String sublabel, int iconId, int suggestionId) {
+ int drawableId = iconId == 0 ? 0 : ResourceId.mapToDrawableId(iconId);
+ array[index] = new AutofillSuggestion(label, sublabel, drawableId, suggestionId);
}
private native void nativePopupDismissed(long nativeAutofillPopupViewAndroid);

Powered by Google App Engine
This is Rietveld 408576698