public void OnInitializationSuccess(YouTubeThumbnailView thumbnailView, IYouTubeThumbnailLoader thumbnailLoader) { this.thumbnailLoader = thumbnailLoader; thumbnailLoader.SetOnThumbnailLoadedListener(new ThumbnailListener() { ThumbnailLoaded = (thumbnail, videoId) => { nextThumbnailLoaded = true; if (activityResumed) { if (state.Equals(State.LOADING_THUMBNAILS)) { FlipNext(); } else if (state.Equals(State.VIDEO_FLIPPED_OUT)) { // load player with the video of the next thumbnail being flipped in state = State.VIDEO_LOADING; player.CueVideo(videoId); } } }, ThumbnailError = (thumbnail, reason) => { LoadNextThumbnail(); } }); MaybeStartDemo(); }
void YouTubeThumbnailView.IOnInitializedListener.OnInitializationSuccess(YouTubeThumbnailView view, IYouTubeThumbnailLoader loader) { loader.SetOnThumbnailLoadedListener(this); thumbnailViewToLoaderMap.Add(view, loader); view.SetImageResource(Resource.Drawable.loading_thumbnail); var videoId = (string)view.Tag; loader.SetVideo(videoId); }
public void OnInitializationSuccess(YouTubeThumbnailView view, IYouTubeThumbnailLoader loader) { loader.SetOnThumbnailLoadedListener(this); OnInitializationSuccessAction?.Invoke(view, loader); //thumbnailViewToLoaderMap.put(view, loader); view.SetImageResource(Resource.Drawable.loading_thumbnail); string videoId = (string)view.Tag; loader.SetVideo(videoId); }
void YouTubeThumbnailView.IOnInitializedListener.OnInitializationSuccess(YouTubeThumbnailView view, IYouTubeThumbnailLoader loader) { this.thumbnailLoader = loader; thumbnailLoader.SetOnThumbnailLoadedListener(this); thumbnailLoader.SetPlaylist(PlaylistId); }
void YouTubeThumbnailView.IOnInitializedListener.OnInitializationSuccess(YouTubeThumbnailView thumbnailView, IYouTubeThumbnailLoader thumbnailLoader) { this.thumbnailLoader = thumbnailLoader; thumbnailLoader.SetOnThumbnailLoadedListener(this); MaybeStartDemo(); }