Esempio n. 1
0
        public static TimePickerFragment NewInstance(Action <DateTime> onTimeSelected)
        {
            TimePickerFragment frag = new TimePickerFragment();

            frag.timeSelectedHandler = onTimeSelected;
            return(frag);
        }
Esempio n. 2
0
        private void TimeDisplay_Click(object sender, EventArgs e)
        {
            TimePickerFragment frag = TimePickerFragment.NewInstance(
                delegate(DateTime time)
            {
                timeDisplay.Text = time.ToString("HH:mm");
                selectedDateTime = new DateTime(selectedDateTime.Year, selectedDateTime.Month, selectedDateTime.Day, time.Hour, time.Minute, 0);
            });

            frag.Show(FragmentManager, TimePickerFragment.TAG);
        }