예제 #1
0
        private void CheckForVictory()
        {
            IsNotWin = !Buttons.All(x => x.Value == null || x.Value == x.Position + 1);
            if (!IsNotWin)
            {
                Title = "Victory! Press restart!";
            }

            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(Title)));
            PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(nameof(IsNotWin)));
        }