Ejemplo n.º 1
0
 public static IPageView NavigateToPlaylist(this INavigationService @this, PlaylistNavigationRequest request)
 {
     if (request.PlaylistType == PlaylistType.Album)
     {
         return(@this.NavigateTo <IAlbumPageView>(request));
     }
     else if (request.PlaylistType == PlaylistType.Artist)
     {
         return(@this.NavigateTo <IArtistPageView>(request));
     }
     else
     {
         return(@this.NavigateTo <IPlaylistPageView>(request));
     }
 }
Ejemplo n.º 2
0
        public static IPageView NavigateToPlaylist(this INavigationService @this, IPlaylist playlist)
        {
            if (@this == null)
            {
                throw new ArgumentNullException("this");
            }

            if (playlist == null)
            {
                throw new ArgumentNullException("playlist");
            }

            var request = new PlaylistNavigationRequest(playlist.PlaylistType, playlist.Id);

            return(@this.NavigateToPlaylist(request));
        }