-
Notifications
You must be signed in to change notification settings - Fork 421
CAPickerViewDataSource
CAPickerView’s data delegate
Access modifier |
Method name |
Description |
public |
numberOfComponentsInPickerView |
set component number |
public |
numberOfRowsInComponent |
set row number of component |
public |
widthForComponent |
set component width |
public |
rowHeightForComponent |
set row height |
public |
titleForRow |
set display content of row |
public |
viewForRow |
set view of alternative row |
public |
viewForSelect |
set view of selected row |
virtual unsigned int numberOfComponentsInPickerView(CAPickerView pickerView) = 0*
Return value: unsigned int
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
virtual unsigned int numberOfRowsInComponent(CAPickerView pickerView, unsigned int component) = 0*
Return value: unsigned int
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
unsigned int |
component |
current component |
virtual float widthForComponent(CAPickerView pickerView, unsigned int component) {return 0;}*
Return value: float
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
unsigned int |
component |
current component |
virtual float rowHeightForComponent(CAPickerView pickerView, unsigned int component) {return 0;}*
Return value: float
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
unsigned int |
component |
current component |
virtual CCString titleForRow(CAPickerView pickerView, unsigned int row, unsigned int component) {return NULL;}**
Return value: CCString*
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
unsigned int |
row |
current row |
unsigned int |
component |
current component |
virtual CAView viewForRow(CAPickerView pickerView, unsigned int row, unsigned int component) {return NULL;}**
Return value: CAView*
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
unsigned int |
row |
current row |
unsigned int |
component |
current component |
virtual CAView viewForSelect(CAPickerView pickerView, unsigned int component, const CCSize& size) {return NULL;}**
Return value: CAView*
Parameter:
Type |
Parameter name |
Description |
CAPickerView* |
pickerView |
current pickerView |
unsigned int |
component |
current component |
const CCSize& |
size |
size of selected row |