I have editbox I want when click on it to show TimePickerDialog instead of the keyboard , and when select the time the picker disappear and the time be shown in the edittext
这个 EditText 是这样的适配器类
public class TminuseistAdaptar extends ArrayAdapter<Tr> {
private final Context context;
ArrayList<Tr> TrBasics ;
static final int TIME_DIALOG_ID = 0;
CheckBox Confirm ;
ImageButton DialUp;
EditText data ;
public TminuseistAdaptar(Context context, int ResourceId,
ArrayList<Tr> items)
{
super(context, ResourceId, items);
this.context = context;
this.TrBasics = items ;
}
public View getView(int position, View convertView, ViewGroup parent) {
}
}
我为editText做了类似的事情
textViewEncounterType = (EditText) rowView.findViewById(R.id.TminuseTime);
textViewEncounterType.setText(TreatementMinuseObject.TBasic.TreatementTime);
textViewEncounterType.setTag(position);
textViewEncounterType.setClickable(true);
textViewEncounterType.setInputType(InputType.TYPE_NULL);
textViewEncounterType.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {
new TimePickerDialog(context, mTimeSetListener, hour, minute, false);
}
});
但什么也没有出现,我在另一个类中调用这个适配器类扩展片段
public class TminusList extends Fragment {
此致