brucetoo / PickView

Date and Province WheelView like IOS
1.1k stars 265 forks source link

how could I just show only two selection #19

Closed MarnoDev closed 8 years ago

MarnoDev commented 8 years ago

我怎么才能只显示两个选项呢? OptionsPickerView pvGenderOption = new OptionsPickerView(mContext); ArrayList<String> genderStr = new ArrayList<>(); genderStr.add("male"); genderStr.add("female"); pvGenderOption.setCyclic(false, true, true); pvGenderOption.setPicker(genderStr); pvGenderOption.setSelectOptions(1); pvGenderOption.setOnoptionsSelectListener((options1, option2, options3) -> { String s = genderStr.get(options1); mTvGender.setText(s); }); pvGenderOption.show(); image

brucetoo commented 8 years ago

You should see source code first(How three selection works),then you can see how to show two selection.