예제 #1
0
 public RoomsPage(Main main)
 {
     this.main = main;
     this.DataContext = _rooms;
     //Room room = new Room("ya", DateTime.Now);
     InitializeComponent();
     //rooms.Add(room);
 }
예제 #2
0
 public GamePage(Main main, string opponent_name, string initial_chat, bool []field)
 {
     InitializeComponent();
     this.main = main;
     textBlockMessages.Text = initial_chat;
     this.opponent_name = opponent_name;
     for (int i = 0; i < 100; i++)
     {
         if (field[i])
         {
             Rectangle cell = (Rectangle)FindName(string.Format("mycell{0}", i));
             Style style = this.FindResource("ShipCell") as Style;
             cell.Style = style;
         }
     }
     my_turn = false;
     Greetings.Content = "Opponent name: " + opponent_name + "; Turn: " + opponent_name;
     this.field = new bool[100];
 }
예제 #3
0
 public LoginPage(Main main)
 {
     InitializeComponent();
     this.main = main;
 }
예제 #4
0
 public WaitPage(Main main)
 {
     InitializeComponent();
     this.main = main;
 }