private async Task PlayVideo(BaseItemDto item, bool isResume = false)
        {
            Log.Info("Playing {0} [{1}]", item.Type, item.Name);
#if WP8
            if (!TrialHelper.Current.CanPlayVideo(item.Id))
            {
                TrialHelper.Current.ShowTrialMessage("In trial mode you can only play one video per day. Please try this tomorrow or purchase the full version.");
            }
            else
            {
                if (SimpleIoc.Default.GetInstance <VideoPlayerViewModel>() != null)
                {
                    Messenger.Default.Send(new NotificationMessage(item, isResume, Constants.Messages.PlayVideoItemMsg));
                    TrialHelper.Current.SetNewVideoItem(item.Id);
                    _navService.NavigateTo(Constants.Pages.VideoPlayerView);
                }
            }
#else
            var bounds = Application.Current.RootVisual.RenderSize;
            var query  = new VideoStreamOptions
            {
                ItemId     = item.Id,
                VideoCodec = VideoCodecs.Wmv,
                //OutputFileExtension = ".wmv",
                AudioCodec       = AudioCodecs.Wma,
                VideoBitRate     = 1000000,
                AudioBitRate     = 128000,
                MaxAudioChannels = 2,
                MaxHeight        = 480, // (int)bounds.Width,
                MaxWidth         = 800  // (int)bounds.Height
            };
            var url = _apiClient.GetVideoStreamUrl(query);
            System.Diagnostics.Debug.WriteLine(url);
            Log.Info(url);

            try
            {
                Log.Info("Telling the server about watching this video");
                await _apiClient.ReportPlaybackStartAsync(item.Id, AuthenticationService.Current.LoggedInUser.Id, true, new List <string>());
            }
            catch (HttpException ex)
            {
                Log.ErrorException("PlayMovieCommand", ex);
            }

            var mediaPlayerLauncher = new MediaPlayerLauncher
            {
                Orientation = MediaPlayerOrientation.Landscape,
                Media       = new Uri(url, UriKind.Absolute),
                Controls    = MediaPlaybackControls.Pause | MediaPlaybackControls.Stop,
                //Location = MediaLocationType.Data
            };
            mediaPlayerLauncher.Show();
#endif
        }