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

Side by Side Diff: ui/android/java/src/org/chromium/ui/autofill/AutofillPopup.java

Issue 16212007: Implement the autofill UI for chromium powered android webview. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@issue15097004
Patch Set: rebased Created 7 years, 5 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 package org.chromium.chrome.browser.autofill; 5 package org.chromium.ui.autofill;
6 6
7 import android.content.Context; 7 import android.content.Context;
8 import android.graphics.Paint; 8 import android.graphics.Paint;
9 import android.graphics.Rect; 9 import android.graphics.Rect;
10 import android.view.LayoutInflater; 10 import android.view.LayoutInflater;
11 import android.view.View; 11 import android.view.View;
12 import android.view.View.OnLayoutChangeListener; 12 import android.view.View.OnLayoutChangeListener;
13 import android.widget.AdapterView; 13 import android.widget.AdapterView;
14 import android.widget.ListPopupWindow; 14 import android.widget.ListPopupWindow;
15 import android.widget.TextView; 15 import android.widget.TextView;
16 16
17 import java.util.ArrayList; 17 import java.util.ArrayList;
18 18
19 import org.chromium.chrome.R; 19 import org.chromium.ui.R;
20 import org.chromium.ui.ViewAndroidDelegate; 20 import org.chromium.ui.ViewAndroidDelegate;
21 21
22 /** 22 /**
23 * The Autofill suggestion popup that lists relevant suggestions. 23 * The Autofill suggestion popup that lists relevant suggestions.
24 */ 24 */
25 public class AutofillPopup extends ListPopupWindow implements AdapterView.OnItem ClickListener { 25 public class AutofillPopup extends ListPopupWindow implements AdapterView.OnItem ClickListener {
26 26
27 /** 27 /**
28 * Constants defining types of Autofill suggestion entries. 28 * Constants defining types of Autofill suggestion entries.
29 * Has to be kept in sync with enum in WebAutofillClient.h 29 * Has to be kept in sync with enum in WebAutofillClient.h
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 // Adding padding. 193 // Adding padding.
194 return maxTextWidth + TEXT_PADDING_DP; 194 return maxTextWidth + TEXT_PADDING_DP;
195 } 195 }
196 196
197 @Override 197 @Override
198 public void onItemClick(AdapterView<?> parent, View view, int position, long id) { 198 public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
199 mAutofillCallback.suggestionSelected(position); 199 mAutofillCallback.suggestionSelected(position);
200 } 200 }
201 201
202 } 202 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698