Example #1
0
File: App.xaml.cs Project: bdr27/c-
        public App()
            : base()
        {
            player1Window = new MainWindow();
            player1Window.Show();
            player2Window = new MainWindow();
            player2Window.IPAddressMenuItem.IsEnabled = false;
            player1Window.Show();
            player2Window.Show();

            handler = new MOCKMessageHandler();

            //wire the handlers
            wireHandlers(player1Window);
            wireHandlers(player2Window);
            player1Window.GameBoard.AddMouseHandler(HandleMouseEventForPlayer1);
            player2Window.GameBoard.AddMouseHandler(HandleMouseEventForPlayer2); 

            player1Window.NameMenuItemHandler(HandleNameMenuItemPlayer1);
            player2Window.NameMenuItemHandler(HandleNameMenuItemPlayer2);
                       
        }
Example #2
0
File: App.xaml.cs Project: bdr27/c-
        public App()
            : base()
        {
            player1Window = new MainWindow();
            player2Window = new MainWindow();
            player2Window.IPAddressMenuItem.IsEnabled = false;
            player1Window.Title = "Brendan Russo - MiniCheckers v4 - Navy";
            player2Window.Title = "Brendan Russo - MiniCheckers v4 - Fuschia";
            player1Window.Show();
            player2Window.Show();

            setupThread();
            handler = new MOCKMessageHandler();

            //wire the handlers
            wireHandlers(player1Window);
            wireHandlers(player2Window);
            player1Window.GameBoard.AddMouseHandler(HandleMouseEventForPlayer1);
            player2Window.GameBoard.AddMouseHandler(HandleMouseEventForPlayer2);

            player1Window.NameMenuItemHandler(HandleNameMenuItemPlayer1);
            player2Window.NameMenuItemHandler(HandleNameMenuItemPlayer2);
        }
Example #3
0
File: App.xaml.cs Project: bdr27/c-
 private void wireHandlers(MainWindow playerWindow)
 {
     playerWindow.AddIPAddressMenuItemHandler(HandleIPAddressMenuItem);
 }