public static TimePickerFragment NewInstance(Action <TimeSpan> onTimeSet) { TimePickerFragment frag = new TimePickerFragment(); frag._timeSelectedHandler = onTimeSet; return(frag); }
public void openDialog(Button button) { TimePickerFragment frag = TimePickerFragment.NewInstance(delegate(System.TimeSpan time) { button.Text = time.ToString(); }); frag.Show(FragmentManager, TimePickerFragment.TAG); }