Video will NOT reset or go out of sync with this interaction
No need to go outside of the app for the lesson at all :^)
Uses Kotlin and cleans up the watch content fragment
Uses out of the box WebView with a custom chrome client
After trying many solutions, I managed to stitch this one together which uses a custom chrome web client and overrides onShowCustomView and onHideCustomView which in turn, implements hiding and showing a full-screen video. Refactored some code in the WatchContentFragment.
Alternate solutions:
1) Youtube Video Player API: costs $ after 10K queries / day. implementation is possible but cumbersome and will require more effort
2) android-youtube-player
Allows for ALOT of customizability, however seems like overkill for now, and would also require
much more effort to even get a simple web view working like the current web view. A simple
solution of showing full screen would just be to show a button outside of the web view. not the best UX.)
Closes #18
Enables Youtube video full screen with a clean UX
After trying many solutions, I managed to stitch this one together which uses a custom chrome web client and overrides onShowCustomView and onHideCustomView which in turn, implements hiding and showing a full-screen video. Refactored some code in the
WatchContentFragment
.Alternate solutions: 1) Youtube Video Player API: costs $ after 10K queries / day. implementation is possible but cumbersome and will require more effort
2) android-youtube-player Allows for ALOT of customizability, however seems like overkill for now, and would also require much more effort to even get a simple web view working like the current web view. A simple solution of showing full screen would just be to show a button outside of the web view. not the best UX.)
Sources: