コード例 #1
0
        void StartNewGame(int width, int height, int bombCount)
        {
            Game = new Gameboard(width, height, bombCount);
            Game.Show(ContentCanvas);
            ((MainWindow)System.Windows.Application.Current.MainWindow).lbl_Status.Background = Brushes.Transparent;
            ((MainWindow)System.Windows.Application.Current.MainWindow).lbl_Status.Content    = "laufendes Spiel!";

            if (Gametimer.IsRunning())
            {
                Gametimer.Stop();
            }
            Gametimer.Init(lbl_Timer);
            Gametimer.Start();
        }
コード例 #2
0
 private void Window_SizeChanged(object sender, SizeChangedEventArgs e)
 {
     Game.Show(ContentCanvas);
 }