Task IUIView.TryActivateAsync()
        {
            PokerMainViewModel model = (PokerMainViewModel)DataContext;

            _deckGPile.Init(model.DeckPile, ts.TagUsed);
            return(Task.CompletedTask);
        }
Exemplo n.º 2
0
 Task IHandleAsync <LoadEventModel> .HandleAsync(LoadEventModel message)
 {
     _deck.Init(_model.Deck1, ts.TagUsed);
     _yourFace.Init(_model.YourFaceOffCard, ts.TagUsed);
     _opponentFace.Init(_model.OpponentFaceOffCard, ts.TagUsed);
     return(Task.CompletedTask);
 }
        Task IUIView.TryActivateAsync()
        {
            CalculationSolitaireMainViewModel model = (CalculationSolitaireMainViewModel)DataContext;

            _deckGPile.Init(model.DeckPile, ts.TagUsed);

            return(Task.CompletedTask);
        }
        Task IUIView.TryActivateAsync()
        {
            CarpetSolitaireMainViewModel model = (CarpetSolitaireMainViewModel)DataContext;

            _deckGPile.Init(model.DeckPile, ts.TagUsed);
            _discardGPile.Init(model.MainDiscardPile, ts.TagUsed);

            return(Task.CompletedTask);
        }
        Task IUIView.TryActivateAsync()
        {
            TriangleSolitaireMainViewModel model = (TriangleSolitaireMainViewModel)DataContext;

            _deckGPile.Init(model.DeckPile, ts.TagUsed);
            _discardGPile.Init(model.Pile1, ts.TagUsed);
            _triangle.Init(model.Triangle1);
            return(Task.CompletedTask);
        }
Exemplo n.º 6
0
        Task IUIView.TryActivateAsync()
        {
            PyramidSolitaireMainViewModel model = (PyramidSolitaireMainViewModel)DataContext;

            _deckGPile.Init(model.DeckPile, ts.TagUsed);
            _discardGPile.Init(model.Discard, ts.TagUsed);
            _currentCard.Init(model.CurrentPile, ts.TagUsed);
            _playerBoard.LoadList(model.PlayList1, ts.TagUsed);
            _triangle.Init(model.GameBoard1 !);
            return(Task.CompletedTask);
        }
        Task IUIView.TryActivateAsync()
        {
            CribbagePatienceMainViewModel model = (CribbagePatienceMainViewModel)DataContext;

            _deckGPile.Init(model.DeckPile, ts.TagUsed);
            if (model.StartPile == null)
            {
                throw new BasicBlankException("Start card was never set.  Rethink");
            }
            _startCard.Init(model.StartPile, ts.TagUsed);

            var(row, column) = model.GetRowColumn(EnumHandCategory.Hand1);
            AddControlToGrid(_grid, _hand1Score, row, column);
            var hand2D = model.GetRowColumn(EnumHandCategory.Hand2);

            AddControlToGrid(_grid, _hand2Score, hand2D.row, hand2D.column);
            var cribD = model.GetRowColumn(EnumHandCategory.Crib);

            AddControlToGrid(_grid, _cribScore, cribD.row, cribD.column);
            return(Task.CompletedTask);
        }