package com.mcivicm.editablespinner; import android.content.Context; import android.support.annotation.NonNull; import android.view.View; import android.view.ViewGroup; import android.widget.TextView; import java.lang.String; import java.util.List; /** * 默认的适配器 */ public class DefaultEditableSpinnerAdapter extends EditableSpinnerAdapter { public DefaultEditableSpinnerAdapter(Context context, List list) { super(context, list, R.layout.default_editable_spinner_item); } @Override public View bindView(int position, @NonNull View convertView, ViewGroup parent, String t) { TextView tv = (TextView) convertView.findViewById(R.id.default_editable_spinner_item); tv.setText(t); return convertView; } @Override public String getDisplayString(int position) { return getItem(position); } }