How to use the react-native-google-cast.play function in react-native-google-cast

To help you get started, we’ve selected a few react-native-google-cast examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github react-native-google-cast / react-native-google-cast / example / src / main.js View on Github external
onActionSelected = position => {
    switch (position) {
      case 0:
        GoogleCast.play()
        break
      case 1:
        GoogleCast.pause()
        break
      case 2:
        GoogleCast.stop()
        break
      case 3:
        this.subtitlesEnabled = !this.subtitlesEnabled
        GoogleCast.toggleSubtitles(this.subtitlesEnabled)
        break
    }
  }