public BaseViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine)
 {
     this.navigationService = navigationService;
     this.dialogService     = dialogService;
     this.apiComicsVine     = apiComicsVine;
     IsConnected            = Connectivity.NetworkAccess != NetworkAccess.Internet;
 }
 public NextPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
     GoToMarvelOrDc = new DelegateCommand(async() =>
     {
         ETypeApplication editor = ImagePublisher == marvel ? ETypeApplication.Marvel : ETypeApplication.DC;
         var param = new NavigationParameters
         {
             { $"{ConfigPageUri.NextPage}", editor }
         };
         await Task.Delay(3000);
         await navigationService.NavigateAsync(new Uri($"/MenuPage/{ConfigPageUri.SharedTransitionNavigationPage}/HomePage", UriKind.Absolute), param);
     });
 }
 public DcVolumePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, DcUniverse, WarnerBrothers, DynamiteEntertainment, Offset)
 {
 }
 public MenuMasterDetailPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, string pubisher) : base(navigationService, dialogService, apiComicsVine)
 {
     this.MarvelOrDc = pubisher;
     SelectMasterDetail();
 }
Beispiel #5
0
 public NextPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
     GoToMarvelOrDc = new DelegateCommand(async() =>
     {
         await Task.Delay(3000);
         var page = ImagePublisher == marvel ? $"{ConfigPageUri.MarvelMasterDetailPage}{ConfigPageUri.SharedTransitionNavigationPage}{ConfigPageUri.MarvelHomePage}": $"{ConfigPageUri.DcMasterDetailPage}{ConfigPageUri.SharedTransitionNavigationPage}{ConfigPageUri.DcHomePage}";
         await navigationService.NavigateAsync(new Uri($"{page}", UriKind.Absolute));
     });
 }
        public SeriePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, string studioName, string ExtrastudioName, int offeset) : base(navigationService, dialogService, apiComicsVine)
        {
            this.ExtraStudioName = ExtrastudioName;
            this.StudioName      = studioName;
            RefreshCommand       = new DelegateCommand(async() =>
            {
                IsBusy = true;
                Text   = string.Empty;
                await LoadSeries();
                IsBusy = false;
            });

            ItemTresholdReachedCommand = new DelegateCommand(async() =>
            {
                offeset += 100;
                await ScrollLoadSeries(offeset);
            });

            SearchCommand = new DelegateCommand(async() =>
            {
                await FindSeries(Text, 0);
            });
            LoadListCommand = new DelegateCommand(async() =>
            {
                await LoadSeries();
            });
            LoadListCommand.Execute();
        }
        public VolumePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
        {
            int offeset = 0;

            ItemTresholdReachedCommand = new DelegateCommand(async() =>
            {
                offeset += 100;
                await ScrollLoadComics(offeset);
            });

            RefreshCommand = new DelegateCommand(async() =>
            {
                IsBusy = true;
                Text   = string.Empty;
                await LoadComics();
                IsBusy = false;
            });
            LoadListCommand = new DelegateCommand(async() =>
            {
                await LoadComics();
            });
        }
        public HomePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, string publisherPrincipal, string publisherSecond, string publisherThird, string publisherFourth) : base(navigationService, dialogService, apiComicsVine)
        {
            this.PublisherPrincipal = publisherPrincipal;
            this.PublisherSecond    = publisherSecond;
            this.PublisherThird     = publisherThird;
            this.PublisherFourth    = publisherFourth;

            LoadListCommand = new DelegateCommand(async() =>
            {
                ListTask = new List <Task>()
                {
                    LoadTeams(), LoadCharacters(), LoadRecentSeries(), LoadRecentVolumes()
                };
                CurrentState = State.Loading;
                await Task.WhenAll(ListTask);
                CurrentState = State.None;
            });
            LoadListCommand.Execute();
        }
 public HomePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
     LoadListCommand = new DelegateCommand(async() =>
     {
         ListTask = new List <Task>()
         {
             LoadTeams(), LoadCharacters(), LoadRecentSeries(), LoadRecentVolumes()
         };
         CurrentState = State.Loading;
         await Task.WhenAll(ListTask);
     });
     LoadListCommand.Execute();
 }
Beispiel #10
0
 public VideoPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
 }
Beispiel #11
0
 public CompareCharactersPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, IApiCharacterStats apiStatsCharacters, string publisher) : base(navigationService, dialogService, apiComicsVine)
 {
     this.apiStatsCharacters = apiStatsCharacters;
     LoadListCommand         = new DelegateCommand(async() =>
     {
         await LoadCharacters(publisher);
     });
     LoadListCommand.Execute();
 }
Beispiel #12
0
        public VolumePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, string publisherPrincipal, string publisherSecond, string publisherThird, int offeset) : base(navigationService, dialogService, apiComicsVine)
        {
            this.PublisherPrincipal    = publisherPrincipal;
            this.PublisherSecond       = publisherSecond;
            this.PublisherThird        = publisherThird;
            ItemTresholdReachedCommand = new DelegateCommand(async() =>
            {
                offeset += 100;
                await ScrollLoadComics(offeset);
            });

            RefreshCommand = new DelegateCommand(async() =>
            {
                IsBusy = true;
                Text   = string.Empty;
                await LoadComics();
                IsBusy = false;
            });
            LoadListCommand = new DelegateCommand(async() =>
            {
                await LoadComics();
            });
            LoadListCommand.Execute();
        }
Beispiel #13
0
 public MarvelSeriesPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, MarvelUniverse, Disney, Offset)
 {
 }
 public DcSeriesPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, DcUniverse, WarnerBrothers, Offset)
 {
 }
 public MarvelCharacterPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, Marvel, offeset)
 {
 }
 public DcCompareCharacterPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, ApiStatsCharacters apiStatsCharacters) : base(navigationService, dialogService, apiComicsVine, apiStatsCharacters, Dc)
 {
 }
Beispiel #17
0
 public MarvelVolumePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, MarvelUniverse, FawcettPublications, Atlas, Offset)
 {
 }
 public MenuPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
     ChangePageCommand = new DelegateCommand(async() =>
     {
         marvelOrDc = marvelOrDc == ETypeApplication.Marvel? ETypeApplication.DC : ETypeApplication.Marvel;
         var param  = new NavigationParameters();
         param.Add($"{ConfigPageUri.NextPage}", marvelOrDc);
         await navigationService.NavigateAsync($"{ConfigPageUri.MenuPage}{ConfigPageUri.SharedTransitionNavigationPage}{ConfigPageUri.HomePage}", param);
     });
     ItemPages = new List <ItemPage>()
     {
         new ItemPage("marvelhome", "Home", $"/HomePage"),
         new ItemPage("ic_action_live_tv.png", "Series", ConfigPageUri.SeriePage),
         new ItemPage("comic", "Volumes", ConfigPageUri.VolumePage),
         new ItemPage("MarvelCharacter", "Characters", ConfigPageUri.CharacterPage),
         new ItemPage("sword", "Vs", ConfigPageUri.VsPage)
     };
 }
        public CharacterPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, string publisherName, int offeset) : base(navigationService, dialogService, apiComicsVine)
        {
            this.PublisherName = publisherName;
            ChangedViewCommand = new DelegateCommand(() => {
                IsChangedView = !IsChangedView;
            });
            ItemTresholdReachedCommand = new DelegateCommand(async() =>
            {
                offeset += 100;
                await ScrollLoadCharacters(offeset);
            });

            SearchCommand = new DelegateCommand(async() =>
            {
                await FindCharacter(Text);
            });

            RefreshCommand = new DelegateCommand(async() =>
            {
                IsBusy = true;
                Text   = string.Empty;
                await LoadCharacters();
                IsBusy = false;
            });
            LoadListCommand = new DelegateCommand(async() =>
            {
                await LoadCharacters();
            });
            LoadListCommand.Execute();
        }
 public DetailVolumePageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
     ShareCommand = new DelegateCommand(async() =>
     {
         await SharedOpcion();
     });
 }
Beispiel #21
0
 public DCCharactersPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, DC_Comics, offeset)
 {
 }
Beispiel #22
0
        public DetailCharactersPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
        {
            ShareCommand = new DelegateCommand(async() =>
            {
                await SharedOpcion();
            });

            GoToVideo = new DelegateCommand(async() =>
            {
                var param = new NavigationParameters();
                param.Add($"{nameof(Video)}", Video);
                await navigationService.NavigateAsync(new Uri(ConfigPageUri.VideoPage, UriKind.Relative), param);
            });
        }
 public MarvelVsDcComicsPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine)
 {
     GoToNextPage = new DelegateCommand <string>(async(image) =>
     {
         var param = new NavigationParameters();
         param.Add($"{ConfigPageUri.NextPage}", image);
         await navigationService.NavigateAsync(new Uri($"{ConfigPageUri.NextPage}", UriKind.Relative), param);
     });
 }
 public MarvelMasterDetailPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine) : base(navigationService, dialogService, apiComicsVine, Marvel)
 {
     ChangePageCommand = new DelegateCommand(async() =>
     {
         await navigationService.NavigateAsync(new Uri($"{ConfigPageUri.DcMasterDetailPage}{ConfigPageUri.SharedTransitionNavigationPage}{ConfigPageUri.DcHomePage}"));
     });
 }
 public VsPageViewModel(INavigationService navigationService, IPageDialogService dialogService, IApiComicsVine apiComicsVine, IApiCharacterStats apiStatsCharacters) : base(navigationService, dialogService, apiComicsVine)
 {
     this.apiStatsCharacters = apiStatsCharacters;
 }