|
WIMM Labs |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectandroid.app.Dialog
com.wimm.framework.app.Dialog
com.wimm.framework.app.YearPickerDialog
public class YearPickerDialog
A Dialog
for selecting a year.
Use this class and DatePickerDialog
instead of Android's DatePickerDialog
.
Dialog
,
DatePickerDialog
,
TimePickerDialog
Nested Class Summary | |
---|---|
static interface |
YearPickerDialog.OnYearSelectedListener
Interface supporting a callback function called when the year is selected. |
Nested classes/interfaces inherited from interface android.content.DialogInterface |
---|
DialogInterface.OnCancelListener, DialogInterface.OnClickListener, DialogInterface.OnDismissListener, DialogInterface.OnKeyListener, DialogInterface.OnMultiChoiceClickListener |
Field Summary |
---|
Fields inherited from interface android.content.DialogInterface |
---|
BUTTON_NEGATIVE, BUTTON_NEUTRAL, BUTTON_POSITIVE, BUTTON1, BUTTON2, BUTTON3 |
Constructor Summary | |
---|---|
YearPickerDialog(Context context)
Constructor. |
|
YearPickerDialog(Context context,
boolean cancelable,
DialogInterface.OnCancelListener cancelListener)
Constructor. |
Method Summary | |
---|---|
void |
setYear(int year)
Sets the year to display as initially selected in the dialog. |
void |
setYearRange(int min,
int max)
Sets the range of selectable years to display in the dialog. |
void |
setYearSelectedListener(YearPickerDialog.OnYearSelectedListener listener)
Sets the listener for the onYearSelected event. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public YearPickerDialog(Context context)
context
- The Context
.public YearPickerDialog(Context context, boolean cancelable, DialogInterface.OnCancelListener cancelListener)
context
- The Context
.cancelable
- A flag specifying whether the dialog can be cancelled.cancelListener
- The listener to inform when the dialog's cancel
method is called.Method Detail |
---|
public void setYearSelectedListener(YearPickerDialog.OnYearSelectedListener listener)
onYearSelected
event.
listener
- The listener.public void setYear(int year)
year
- The selected year.public void setYearRange(int min, int max)
min
- The earliest year to display.max
- The latest year to display.
|
WIMM Labs |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |