Skip to content

Added Callback when IOS video closed and Fixed Android YouTube Bug. - #25

Open
JonSmart wants to merge 43 commits into
Glitchbone:masterfrom
JonSmart:master
Open

Added Callback when IOS video closed and Fixed Android YouTube Bug.#25
JonSmart wants to merge 43 commits into
Glitchbone:masterfrom
JonSmart:master

Conversation

@JonSmart

Copy link
Copy Markdown

I have added a callback in JS, when the IOS video player finishes, this was useful for me to be able to handle some rotation logic.

I also had issues with new YouTube videos not playing, so have merged with some other contributors D0cz and trakout, and added a further fix based on:
https://code.google.com/p/gdata-issues/issues/detail?id=8244

arctouch-brunowolff and others added 30 commits February 17, 2016 15:20
For newer android versions (5+), it will use the YouTube API player.
Changing android:screenOrientation from "landscape" to "unspecified" (default).
http://developer.android.com/guide/topics/manifest/activity-element.html
…m/p/gdata-issues/issues/detail?id=8244.

The app will however now load the YouTube Player on the device leaving your app, which may not be intended...
…s/issues/detail?id=8244 and https://code.google.com/p/gdata-issues/issues/detail?id=8248.

Checks for YouTube App Version.

NOTE: If this is fixed in the next version then change this to be == not >=
@juergengunz

Copy link
Copy Markdown

@JonSmart could you please describe how to use the callback functions ?

@JonSmart

JonSmart commented Dec 20, 2016

Copy link
Copy Markdown
Author

@juergengunz I will aim to update the documentation. But in the mean time here is an example of how I have used it:
YoutubeVideoPlayer.openVideo(videoID, (result) => { console.log('Video Finished');});

@JonSmart

Copy link
Copy Markdown
Author

If you want this to work on Android, you may need to use the latest version of my branch, I will look to add another pull request to this Repository once I have performed some tidying and testing.

@juergengunz

Copy link
Copy Markdown

@JonSmart thanks! sounds cool. looking forward to it.

@zabojad

zabojad commented Jul 28, 2017

Copy link
Copy Markdown

@Glitchbone why don't you merge it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants