コード例 #1
0
        private void ManipulateValue(TextBox tb, ValueManipulator ValMan)
        {
            if (tb.get_HMSType() == HMSType.t || tb.get_HMSType() == HMSType.tt)
            {
                AM_PM_Change(tb);
                return;
            }
            int NewValue;

            if (int.TryParse(tb.Text, out NewValue))
            {
                ValMan(tb, NewValue);
            }

            tb.Focus();
            tb.SelectAll();
        }
コード例 #2
0
ファイル: TimeCtrl.xaml.cs プロジェクト: gahadzikwa/GAPP
        private void ManipulateValue(TextBox tb, ValueManipulator ValMan)
        {
            if (tb.get_HMSType() == HMSType.t || tb.get_HMSType() == HMSType.tt)
            {
                AM_PM_Change(tb);
                return;
            }
            int NewValue;

            if (int.TryParse(tb.Text, out NewValue))
                ValMan(tb, NewValue);

            tb.Focus();
            tb.SelectAll();
        }