Skip to content

Instantly share code, notes, and snippets.

@krizzu
Created February 13, 2019 12:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save krizzu/c85aee741f6ff0da6f2a8958af127a7c to your computer and use it in GitHub Desktop.
Save krizzu/c85aee741f6ff0da6f2a8958af127a7c to your computer and use it in GitHub Desktop.
extension VideoGalleryViewController: ControlsViewControllerDelegate {
var hasNextVideo: Bool {
get {
return currentVideoIndex < videos.count - 1
}
}
func playNextVideo() {
trackSkippedVideo()
updateActiveVideo(currentVideoIndex + 1)
}
func handleExitFullScreenButtonPressed() {
if isIphone {
handleFullscreenRotation()
} else {
dismissFullscreenViewController()
}
}
func handleEnterFullScreenButtonPressed() {
if isIphone {
handleFullscreenRotation()
} else {
showFullscreenViewController()
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment