Пример #1
0
        public static DialogResult EditTimesModal(Timer t, System.Windows.Forms.IWin32Window owner)
        {
            if (t == null)
            {
                return(DialogResult.Cancel);
            }
            EditTimes f = new EditTimes();

            f.setTimer(t);
            return(f.ShowDialog(owner));
        }
Пример #2
0
        private void mnuEditTimes_Click(object sender, System.EventArgs e)
        {
            Timer t = this.GetSelectedTimer();

            if (t == null)
            {
                return;
            }
            DialogResult dr = EditTimes.EditTimesModal(t, this);

            if (dr != DialogResult.OK)
            {
                return;
            }
            timers.Save();
        }