コード例 #1
0
ファイル: WindowMain.xaml.cs プロジェクト: tuansolo/CodeBase
        // executes login command. Opens login dialog and loads members

        private void LoginCommand_Executed(object sender, ExecutedRoutedEventArgs e)
        {
            var window = new WindowLogin();
            window.Owner = this; // This will center dialog in owner window

            if (window.ShowDialog() == true)
            {
                TextBlockAnnouncement.Visibility = Visibility.Collapsed;

                Cursor = Cursors.Wait;
                ViewModel.LoadMembers();
                Cursor = Cursors.Arrow;

                CommandManager.InvalidateRequerySuggested();
            }
        }
コード例 #2
0
        // executes login command. Opens login dialog and loads members

        private void LoginCommand_Executed(object sender, ExecutedRoutedEventArgs e)
        {
            var window = new WindowLogin();

            window.Owner = this; // This will center dialog in owner window

            if (window.ShowDialog() == true)
            {
                TextBlockAnnouncement.Visibility = Visibility.Collapsed;

                Cursor = Cursors.Wait;
                ViewModel.LoadMembers();
                Cursor = Cursors.Arrow;

                CommandManager.InvalidateRequerySuggested();
            }
        }