private void BtnAdd(object sender, RoutedEventArgs e)
        {
            GoalWindow window = new GoalWindow();

            if (window.ShowDialog((t) => Goal = t) == true)
            {
            }
        }
        private void BtnContextMenuEdit(object sender, RoutedEventArgs e)
        {
            GoalWindow window = new GoalWindow();

            if (window.ShowDialog((t) => Goal = t, Goal.Name, Goal.dateEnd) == true)
            {
                MainWindow.dataChanged = true;
            }
        }
示例#3
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.window = ((Time_Owner.GoalWindow)(target));
                return;

            case 2:
                this.goalNameText = ((System.Windows.Controls.TextBox)(target));

            #line 25 "..\..\GoalWindow.xaml"
                this.goalNameText.PreviewTextInput += new System.Windows.Input.TextCompositionEventHandler(this.MyPreviewTextInput);

            #line default
            #line hidden
                return;

            case 3:

            #line 26 "..\..\GoalWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.BtnOk);

            #line default
            #line hidden
                return;

            case 4:

            #line 27 "..\..\GoalWindow.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.BtnCancel);

            #line default
            #line hidden
                return;

            case 5:
                this.datePicker = ((System.Windows.Controls.DatePicker)(target));
                return;
            }
            this._contentLoaded = true;
        }