private void window_Loaded(object sender, RoutedEventArgs e)
        {
            vm = new CIAViewModel(this);
            m  = new CIAModel(this);
            StartDialog sd = new StartDialog(this);

            sd.Owner = this;
            sd.WindowStartupLocation = System.Windows.WindowStartupLocation.CenterOwner;
            sd.Visibility            = Visibility.Visible;
        }
Пример #2
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.window = ((Conquer_It_All.MainWindow)(target));
                return;

            case 2:
                this.MainWindowGrid = ((System.Windows.Controls.Grid)(target));
                return;

            case 3:
                this.RankingBorder = ((System.Windows.Controls.Border)(target));
                return;

            case 4:
                this.Player1 = ((System.Windows.Controls.Label)(target));
                return;

            case 5:
                this.Player2 = ((System.Windows.Controls.Label)(target));
                return;

            case 6:
                this.Player3 = ((System.Windows.Controls.Label)(target));
                return;

            case 7:
                this.Player4 = ((System.Windows.Controls.Label)(target));
                return;

            case 8:
                this.Player1Score = ((System.Windows.Controls.Label)(target));
                return;

            case 9:
                this.Player2Score = ((System.Windows.Controls.Label)(target));
                return;

            case 10:
                this.Player3Score = ((System.Windows.Controls.Label)(target));
                return;

            case 11:
                this.Player4Score = ((System.Windows.Controls.Label)(target));
                return;

            case 12:
                this.CardBorder = ((System.Windows.Controls.Border)(target));
                return;

            case 13:
                this.border = ((System.Windows.Controls.Border)(target));
                return;

            case 14:
                this.ActionForStage = ((System.Windows.Controls.Label)(target));
                return;

            case 15:
                this.Territory1 = ((System.Windows.Controls.Label)(target));
                return;

            case 16:
                this.Territory3 = ((System.Windows.Controls.Label)(target));
                return;

            case 17:
                this.Territory4 = ((System.Windows.Controls.Label)(target));
                return;

            case 18:
                this.Territory5 = ((System.Windows.Controls.Label)(target));
                return;

            case 19:
                this.Territory6 = ((System.Windows.Controls.Label)(target));
                return;

            case 20:
                this.Territory7 = ((System.Windows.Controls.Label)(target));
                return;

            case 21:
                this.Territory8 = ((System.Windows.Controls.Label)(target));
                return;

            case 22:
                this.Territory10 = ((System.Windows.Controls.Label)(target));
                return;

            case 23:
                this.Territory11 = ((System.Windows.Controls.Label)(target));
                return;

            case 24:
                this.Territory12 = ((System.Windows.Controls.Label)(target));
                return;

            case 25:
                this.Territory13 = ((System.Windows.Controls.Label)(target));
                return;

            case 26:
                this.Territory14 = ((System.Windows.Controls.Label)(target));
                return;

            case 27:
                this.Territory15 = ((System.Windows.Controls.Label)(target));
                return;

            case 28:
                this.Territory18 = ((System.Windows.Controls.Label)(target));
                return;

            case 29:
                this.Territory19 = ((System.Windows.Controls.Label)(target));
                return;

            case 30:
                this.Territory20 = ((System.Windows.Controls.Label)(target));
                return;

            case 31:
                this.Territory21 = ((System.Windows.Controls.Label)(target));
                return;

            case 32:
                this.Territory22 = ((System.Windows.Controls.Label)(target));
                return;

            case 33:
                this.Territory23 = ((System.Windows.Controls.Label)(target));
                return;

            case 34:
                this.Territory24 = ((System.Windows.Controls.Label)(target));
                return;

            case 35:
                this.Territory25 = ((System.Windows.Controls.Label)(target));
                return;

            case 36:
                this.Territory1_Copy = ((System.Windows.Controls.Label)(target));
                return;

            case 37:
                this.Territory1_Copy1 = ((System.Windows.Controls.Label)(target));
                return;

            case 38:
                this.Territory1_Copy2 = ((System.Windows.Controls.Label)(target));
                return;

            case 39:
                this.Territory1_Copy3 = ((System.Windows.Controls.Label)(target));
                return;

            case 40:
                this.Territory1_Copy4 = ((System.Windows.Controls.Label)(target));
                return;

            case 41:
                this.Territory1_Copy5 = ((System.Windows.Controls.Label)(target));
                return;

            case 42:
                this.Territory1_Copy6 = ((System.Windows.Controls.Label)(target));
                return;

            case 43:
                this.Territory1_Copy7 = ((System.Windows.Controls.Label)(target));
                return;

            case 44:
                this.Territory1_Copy8 = ((System.Windows.Controls.Label)(target));
                return;

            case 45:
                this.Territory1_Copy9 = ((System.Windows.Controls.Label)(target));
                return;

            case 46:
                this.Territory1_Copy10 = ((System.Windows.Controls.Label)(target));
                return;

            case 47:
                this.Territory1_Copy11 = ((System.Windows.Controls.Label)(target));
                return;

            case 48:
                this.Territory1_Copy12 = ((System.Windows.Controls.Label)(target));
                return;

            case 49:
                this.Territory1_Copy13 = ((System.Windows.Controls.Label)(target));
                return;

            case 50:
                this.Territory1_Copy14 = ((System.Windows.Controls.Label)(target));
                return;

            case 51:
                this.Territory1_Copy15 = ((System.Windows.Controls.Label)(target));
                return;

            case 52:
                this.Territory1_Copy16 = ((System.Windows.Controls.Label)(target));
                return;

            case 53:
                this.Territory1_Copy17 = ((System.Windows.Controls.Label)(target));
                return;

            case 54:
                this.Territory1_Copy18 = ((System.Windows.Controls.Label)(target));
                return;

            case 55:
                this.Territory1_Copy19 = ((System.Windows.Controls.Label)(target));
                return;

            case 56:
                this.Territory1_Copy20 = ((System.Windows.Controls.Label)(target));
                return;

            case 57:
                this.Territory1_Copy21 = ((System.Windows.Controls.Label)(target));
                return;

            case 58:
                this.Territory1_Copy22 = ((System.Windows.Controls.Label)(target));
                return;

            case 59:
                this.Territory1_Copy23 = ((System.Windows.Controls.Label)(target));
                return;

            case 60:
                this.Territory1_Copy24 = ((System.Windows.Controls.Label)(target));
                return;

            case 61:
                this.Territory1_Copy25 = ((System.Windows.Controls.Label)(target));
                return;

            case 62:
                this.dialogGrid = ((System.Windows.Controls.Grid)(target));
                return;

            case 63:
                this.StartDialog = ((Conquer_It_All.StartDialog)(target));
                return;
            }
            this._contentLoaded = true;
        }
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.window = ((Conquer_It_All.ConquerItAll)(target));
                return;

            case 2:
                this.viewbox = ((System.Windows.Controls.Viewbox)(target));
                return;

            case 3:
                this.uniformGrid = ((System.Windows.Controls.Grid)(target));
                return;

            case 4:
                this.MapCanvas = ((System.Windows.Controls.Grid)(target));
                return;

            case 5:
                this.Map = ((System.Windows.Controls.Image)(target));
                return;

            case 6:
                this.Territory1 = ((System.Windows.Controls.Label)(target));

            #line 19 "..\..\ConquerItAll.xaml"
                this.Territory1.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 7:
                this.Territory2 = ((System.Windows.Controls.Label)(target));

            #line 20 "..\..\ConquerItAll.xaml"
                this.Territory2.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 8:
                this.Territory3 = ((System.Windows.Controls.Label)(target));

            #line 21 "..\..\ConquerItAll.xaml"
                this.Territory3.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 9:
                this.Territory4 = ((System.Windows.Controls.Label)(target));

            #line 22 "..\..\ConquerItAll.xaml"
                this.Territory4.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 10:
                this.Territory5 = ((System.Windows.Controls.Label)(target));

            #line 23 "..\..\ConquerItAll.xaml"
                this.Territory5.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 11:
                this.Territory6 = ((System.Windows.Controls.Label)(target));

            #line 24 "..\..\ConquerItAll.xaml"
                this.Territory6.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 12:
                this.Territory7 = ((System.Windows.Controls.Label)(target));

            #line 25 "..\..\ConquerItAll.xaml"
                this.Territory7.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 13:
                this.Territory8 = ((System.Windows.Controls.Label)(target));

            #line 26 "..\..\ConquerItAll.xaml"
                this.Territory8.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 14:
                this.Territory9 = ((System.Windows.Controls.Label)(target));

            #line 27 "..\..\ConquerItAll.xaml"
                this.Territory9.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 15:
                this.Territory10 = ((System.Windows.Controls.Label)(target));

            #line 28 "..\..\ConquerItAll.xaml"
                this.Territory10.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 16:
                this.Territory11 = ((System.Windows.Controls.Label)(target));

            #line 29 "..\..\ConquerItAll.xaml"
                this.Territory11.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 17:
                this.Territory12 = ((System.Windows.Controls.Label)(target));

            #line 30 "..\..\ConquerItAll.xaml"
                this.Territory12.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 18:
                this.Territory13 = ((System.Windows.Controls.Label)(target));

            #line 31 "..\..\ConquerItAll.xaml"
                this.Territory13.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 19:
                this.Territory14 = ((System.Windows.Controls.Label)(target));

            #line 32 "..\..\ConquerItAll.xaml"
                this.Territory14.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 20:
                this.Territory15 = ((System.Windows.Controls.Label)(target));

            #line 33 "..\..\ConquerItAll.xaml"
                this.Territory15.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 21:
                this.Territory16 = ((System.Windows.Controls.Label)(target));

            #line 34 "..\..\ConquerItAll.xaml"
                this.Territory16.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 22:
                this.Territory17 = ((System.Windows.Controls.Label)(target));

            #line 35 "..\..\ConquerItAll.xaml"
                this.Territory17.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 23:
                this.Territory18 = ((System.Windows.Controls.Label)(target));

            #line 36 "..\..\ConquerItAll.xaml"
                this.Territory18.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 24:
                this.Territory19 = ((System.Windows.Controls.Label)(target));

            #line 37 "..\..\ConquerItAll.xaml"
                this.Territory19.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 25:
                this.Territory20 = ((System.Windows.Controls.Label)(target));

            #line 38 "..\..\ConquerItAll.xaml"
                this.Territory20.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 26:
                this.Territory21 = ((System.Windows.Controls.Label)(target));

            #line 39 "..\..\ConquerItAll.xaml"
                this.Territory21.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 27:
                this.Territory22 = ((System.Windows.Controls.Label)(target));

            #line 40 "..\..\ConquerItAll.xaml"
                this.Territory22.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 28:
                this.Territory23 = ((System.Windows.Controls.Label)(target));

            #line 41 "..\..\ConquerItAll.xaml"
                this.Territory23.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 29:
                this.Territory24 = ((System.Windows.Controls.Label)(target));

            #line 42 "..\..\ConquerItAll.xaml"
                this.Territory24.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 30:
                this.Territory25 = ((System.Windows.Controls.Label)(target));

            #line 43 "..\..\ConquerItAll.xaml"
                this.Territory25.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 31:
                this.Territory26 = ((System.Windows.Controls.Label)(target));

            #line 44 "..\..\ConquerItAll.xaml"
                this.Territory26.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 32:
                this.Territory27 = ((System.Windows.Controls.Label)(target));

            #line 45 "..\..\ConquerItAll.xaml"
                this.Territory27.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 33:
                this.Territory28 = ((System.Windows.Controls.Label)(target));

            #line 46 "..\..\ConquerItAll.xaml"
                this.Territory28.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 34:
                this.Territory29 = ((System.Windows.Controls.Label)(target));

            #line 47 "..\..\ConquerItAll.xaml"
                this.Territory29.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 35:
                this.Territory30 = ((System.Windows.Controls.Label)(target));

            #line 48 "..\..\ConquerItAll.xaml"
                this.Territory30.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 36:
                this.Territory31 = ((System.Windows.Controls.Label)(target));

            #line 49 "..\..\ConquerItAll.xaml"
                this.Territory31.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 37:
                this.Territory32 = ((System.Windows.Controls.Label)(target));

            #line 50 "..\..\ConquerItAll.xaml"
                this.Territory32.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 38:
                this.Territory33 = ((System.Windows.Controls.Label)(target));

            #line 51 "..\..\ConquerItAll.xaml"
                this.Territory33.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 39:
                this.Territory34 = ((System.Windows.Controls.Label)(target));

            #line 52 "..\..\ConquerItAll.xaml"
                this.Territory34.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 40:
                this.Territory35 = ((System.Windows.Controls.Label)(target));

            #line 53 "..\..\ConquerItAll.xaml"
                this.Territory35.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 41:
                this.Territory36 = ((System.Windows.Controls.Label)(target));

            #line 54 "..\..\ConquerItAll.xaml"
                this.Territory36.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 42:
                this.Territory37 = ((System.Windows.Controls.Label)(target));

            #line 55 "..\..\ConquerItAll.xaml"
                this.Territory37.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 43:
                this.Territory38 = ((System.Windows.Controls.Label)(target));

            #line 56 "..\..\ConquerItAll.xaml"
                this.Territory38.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 44:
                this.Territory39 = ((System.Windows.Controls.Label)(target));

            #line 57 "..\..\ConquerItAll.xaml"
                this.Territory39.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 45:
                this.Territory40 = ((System.Windows.Controls.Label)(target));

            #line 58 "..\..\ConquerItAll.xaml"
                this.Territory40.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 46:
                this.Territory41 = ((System.Windows.Controls.Label)(target));

            #line 59 "..\..\ConquerItAll.xaml"
                this.Territory41.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 47:
                this.Territory42 = ((System.Windows.Controls.Label)(target));

            #line 60 "..\..\ConquerItAll.xaml"
                this.Territory42.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 48:
                this.Territory43 = ((System.Windows.Controls.Label)(target));

            #line 61 "..\..\ConquerItAll.xaml"
                this.Territory43.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 49:
                this.Territory44 = ((System.Windows.Controls.Label)(target));

            #line 62 "..\..\ConquerItAll.xaml"
                this.Territory44.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 50:
                this.Territory45 = ((System.Windows.Controls.Label)(target));

            #line 63 "..\..\ConquerItAll.xaml"
                this.Territory45.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 51:
                this.Territory46 = ((System.Windows.Controls.Label)(target));

            #line 64 "..\..\ConquerItAll.xaml"
                this.Territory46.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Territory_MouseUp);

            #line default
            #line hidden
                return;

            case 52:
                this.PlayerNameLabel = ((System.Windows.Controls.Label)(target));
                return;

            case 53:
                this.CurrentStageLabel = ((System.Windows.Controls.Label)(target));
                return;

            case 54:
                this.CurrentStageActionLabel2 = ((System.Windows.Controls.Label)(target));
                return;

            case 55:
                this.CurrentStageActionLabel1 = ((System.Windows.Controls.Label)(target));
                return;

            case 56:
                this.DropDownDialogue = ((System.Windows.Controls.Grid)(target));
                return;

            case 57:
                this.Cards = ((System.Windows.Controls.Image)(target));

            #line 78 "..\..\ConquerItAll.xaml"
                this.Cards.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.Cards_MouseUp);

            #line default
            #line hidden
                return;

            case 58:
                this.NextStageButton = ((System.Windows.Controls.Image)(target));

            #line 79 "..\..\ConquerItAll.xaml"
                this.NextStageButton.MouseUp += new System.Windows.Input.MouseButtonEventHandler(this.NextStageButton_MouseUp);

            #line default
            #line hidden
                return;

            case 59:
                this.Player1Name = ((System.Windows.Controls.Label)(target));
                return;

            case 60:
                this.Player2Name = ((System.Windows.Controls.Label)(target));
                return;

            case 61:
                this.Player3Name = ((System.Windows.Controls.Label)(target));
                return;

            case 62:
                this.Player4Name = ((System.Windows.Controls.Label)(target));
                return;

            case 63:
                this.Player1Territories = ((System.Windows.Controls.Label)(target));
                return;

            case 64:
                this.Player2Territories = ((System.Windows.Controls.Label)(target));
                return;

            case 65:
                this.Player3Territories = ((System.Windows.Controls.Label)(target));
                return;

            case 66:
                this.Player4Territories = ((System.Windows.Controls.Label)(target));
                return;

            case 67:
                this.StartDialog = ((Conquer_It_All.StartDialog)(target));
                return;
            }
            this._contentLoaded = true;
        }