https://github.com/JZXiang/TimePickerDialog
1,使用时如果报错API版本太低,那么使用全属性
DatePickerDialog dialog = new DatePickerDialog(AddTesterActivity.this,
DatePickerDialog.THEME_HOLO_DARK, new DatePickerDialog.OnDateSetListener() {
@Override
public void onDateSet(DatePicker view, int year, int month, int dayOfMonth) {
month++;
mTvTesterBirthdaySelector.setText(year+"年"+month+"月"+dayOfMonth+"日");
}
}, 1965, 4, 21);
dialog.show();
2,如果DatePickerDialog.THEME_HOLO_DARK 报错,2中解决方法
1,自定义Theme
2,在方法前面加上@SuppressWarnings("ResourceType")