private void UpdateThumbnail(MessageViewModel message, Thumbnail thumbnail, File file) { if (file.Local.IsDownloadingCompleted) { if (thumbnail.Format is ThumbnailFormatJpeg) { //Texture.Source = new BitmapImage(new Uri("file:///" + file.Local.Path)); Texture.Source = PlaceholderHelper.GetBlurred(file.Local.Path); } else if (!Services.SettingsService.Current.Diagnostics.SoftwareDecoderEnabled) { this.BeginOnUIThread(async() => { Texture.Source = await PlaceholderHelper.GetFirstVideoFrameAsBlurredTumbnailAsync(file.Local.Path); }); } } else if (file.Local.CanBeDownloaded && !file.Local.IsDownloadingActive) { message.ProtoService.DownloadFile(file.Id, 1); } }