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

Unified Diff: ui/android/java/src/org/chromium/ui/autofill/AutofillListAdapter.java

Issue 62203014: Move WindowOpenDisposition.template to ui/base/android. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix ui.gyp Created 7 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 side-by-side diff with in-line comments
Download patch
Index: ui/android/java/src/org/chromium/ui/autofill/AutofillListAdapter.java
diff --git a/ui/android/java/src/org/chromium/ui/autofill/AutofillListAdapter.java b/ui/android/java/src/org/chromium/ui/autofill/AutofillListAdapter.java
deleted file mode 100644
index 62203dc70a802f4c7268cb3cbbd920f77e4f1956..0000000000000000000000000000000000000000
--- a/ui/android/java/src/org/chromium/ui/autofill/AutofillListAdapter.java
+++ /dev/null
@@ -1,54 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-
-package org.chromium.ui.autofill;
-
-import android.content.Context;
-import android.text.TextUtils;
-
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.widget.ArrayAdapter;
-import android.widget.TextView;
-
-import org.chromium.ui.R;
-
-import java.util.ArrayList;
-
-/**
- * Autofill suggestion adapter for AutofillWindow.
- */
-public class AutofillListAdapter extends ArrayAdapter<AutofillSuggestion> {
- private Context mContext;
-
- AutofillListAdapter(Context context, ArrayList<AutofillSuggestion> objects) {
- super(context, R.layout.autofill_text, objects);
- mContext = context;
- }
-
- @Override
- public View getView(int position, View convertView, ViewGroup parent) {
- View layout = convertView;
- if (convertView == null) {
- LayoutInflater inflater =
- (LayoutInflater) mContext.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
- layout = inflater.inflate(R.layout.autofill_text, null);
- }
- TextView labelView = (TextView) layout.findViewById(R.id.autofill_label);
- labelView.setText(getItem(position).mLabel);
-
- TextView sublabelView = (TextView) layout.findViewById(R.id.autofill_sublabel);
- CharSequence sublabel = getItem(position).mSublabel;
- if (TextUtils.isEmpty(sublabel)) {
- sublabelView.setVisibility(View.GONE);
- } else {
- sublabelView.setText(sublabel);
- sublabelView.setVisibility(View.VISIBLE);
- }
-
- return layout;
- }
-}

Powered by Google App Engine
This is Rietveld 408576698