ANRTournament.MainWindow.MainWindow C# (CSharp) Метод

MainWindow() публичный Метод

public MainWindow ( ) : System
Результат System
        public MainWindow()
        {
            InitializeComponent();

            this.lblVersion.Content = string.Format(this.lblVersion.Content.ToString(), Assembly.GetEntryAssembly().GetName().Version.ToString(3));
            this.Title = this.lblVersion.Content.ToString();

            this.RefreshTournamentDataContexts();

            this.bkgGenerateRound.DoWork += new DoWorkEventHandler(bkgGenerateRound_DoWork);
            this.bkgGenerateRound.RunWorkerCompleted += new RunWorkerCompletedEventHandler(bkgGenerateRound_RunWorkerCompleted);
            this.bkgGenerateRound.ProgressChanged += new ProgressChangedEventHandler(bkgGenerateRound_ProgressChanged);

            if (App.Settings.MainTabSetting == Settings.MainTabSettings.PointsTableWithRoundsSeparate)
            {
                this.gridRounds.Children.Remove(this.brdTablePoints);
                this.gridTablePoints.Children.Add(this.brdTablePoints);
                this.tabTablePoints.Visibility = System.Windows.Visibility.Visible;

                this.brdRounds.SetValue(Grid.ColumnProperty, 0);
                this.brdRounds.SetValue(Grid.ColumnSpanProperty, 2);
                this.brdRounds.MaxWidth = 700;
            }
            else
            {
                this.tbMain.SelectedIndex = 1;
            }

            this.colDiceCount.Visibility = System.Windows.Visibility.Collapsed;

            this.colDeckcheck.Visibility = App.Settings.ColumnDC ? System.Windows.Visibility.Visible : System.Windows.Visibility.Collapsed;
            this.colGalakta.Visibility = App.Settings.ColumnG ? System.Windows.Visibility.Visible : System.Windows.Visibility.Collapsed;
            this.colPayment.Visibility = App.Settings.ColumnPayment ? System.Windows.Visibility.Visible : System.Windows.Visibility.Collapsed;
            this.colRankBeforeTournament.Visibility = App.Settings.ColumnRank ? System.Windows.Visibility.Visible : System.Windows.Visibility.Collapsed;

            #region Generowanie Playerów
            #if DEBUG
            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "morphine",
                    Name = "Tomasz",
                    Surname = "Bator",
                    RankBeforeTournament = 666,
                    DeckCheck = true,
                    Payment = true,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Alf",
                    Name = "Włochaty",
                    Surname = "Kosmita",
                    RankBeforeTournament = 777,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Tinky Winky",
                    Name = "Fioletowy",
                    Surname = "Tubiś",
                    RankBeforeTournament = 1333,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Dipsy",
                    Name = "Zielony",
                    Surname = "Tubiś",
                    RankBeforeTournament = 1249,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Laa-Laa",
                    Name = "Żółta",
                    Surname = "Tubiśka",
                    RankBeforeTournament = 1111,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Po",
                    Name = "Czerwona",
                    Surname = "Tubiśka",
                    RankBeforeTournament = 903,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Noo-Noo",
                    Name = "Że niby",
                    Surname = "odkurzacz :)",
                    RankBeforeTournament = 1098,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });

            for (int i = 0; i < 0; i++)
            {
                this.tournament.PointsTable.Add(
                new Player()
                {
                    Alias = "Player" + i.ToString(),
                    Name = "Player" + i.ToString(),
                    Surname = "Player" + i.ToString(),
                    RankBeforeTournament = 1098,
                    CorpoIdentity = "NBN: The World is Yours*",
                    RunnerIdentity = "Iain Stirling: Retired Spook",
                });
            }
            #endif
            #endregion
        }
MainWindow