TheChan.ViewModels.VideoPlayerViewModel.OpenInPlayer C# (CSharp) Method

OpenInPlayer() public method

public OpenInPlayer ( ) : void
return void
        public async void OpenInPlayer() {
            IsInProgress = true;
            try {
                StorageFile file = await CacheService.RetrieveFileAsync(Attachment.Uri, CacheItemType.Video);
                IsInProgress = false;
                await Launcher.LaunchFileAsync(file);
            }
            catch {
                try {
                    await CacheService.DeleteItemAsync(Attachment.Uri);
                }
                catch { /* OK */ }
                IsInProgress = false;
                IsError = true;
                Status = Localization.GetForView("VideoPlayer", "Error");
            }
        }