示例#1
0
        public CardRemoveViewModel(string collectionName, ICard card)
            : base(collectionName)
        {
            Source = new CardSourceViewModel(MagicDatabase, SourceCollection, card);

            Display.Title = "Remove card";
        }
示例#2
0
        public CardUpdateViewModel(string collectionName, ICard card)
            : base(collectionName)
        {
            _editions = MagicDatabase.GetAllEditionIncludingCardOrdered(card)
                        .ToArray();

            Source = new CardSourceViewModel(MagicDatabase, SourceCollection, card);

            EditionSelected = Source.EditionSelected;

            Display.Title = "Update infos";
        }
示例#3
0
        public CardMoveOrCopyViewModel(string collectionName, ICard card, bool copy) :
            base(collectionName)
        {
            Source = new CardSourceViewModel(MagicDatabase, SourceCollection, card);

            Copy         = copy;
            _collections = MagicDatabase.GetAllCollections().ToArray();

            if (_collections.Length > 0)
            {
                if (SourceCollection != _collections[0] || _collections.Length == 1)
                {
                    CardCollectionSelected = _collections[0];
                }
                else
                {
                    CardCollectionSelected = _collections[1];
                }
            }
        }