benjipott / video.js-chromecast

Use chromecast with videojs html5 player
Other
207 stars 86 forks source link

When we stop Chromecast the video cannot play after #40

Open onigetoc opened 7 years ago

onigetoc commented 7 years ago

When we stop Chromecast the video cannot play in Video.js after.

Error after sending video to Chromecast. (I think the plugin should pause de video right after click chromecast button to load faster and not wait Chromecast player to be playing)

videojs-chromecast.min.js:7 Uncaught TypeError: c.default.createEl is not a function
    at t.value (videojs-chromecast.min.js:7)
    at t.Component (video.js:3050)
    at t.Tech (video.js:14745)
    at new t (videojs-chromecast.min.js:7)
    at Player.loadTech_ (video.js:9578)
    at t.value (videojs-chromecast.min.js:7)
    at cast_sender.js:82
    at cast_sender.js:83
    at V.onMessage (cast_sender.js:88)
    at O.h (cast_sender.js:62)

Error after stoping video from the Chromecast button. (For HLS Video or other Tech)

Uncaught TypeError: this.tech_[method] is not a function
    at Player.techCall_ (video.js:10254)
    at Player.play (video.js:10310)
    at PlayToggle.handleClick (video.js:4908)
    at HTMLButtonElement.ret (video.js:18397)
    at HTMLButtonElement.data.dispatcher (video.js:18045)

Also, i think the video on Chromecast should stop and not show the browser Chromecast extension confirmation window to open.

Another issus, if i dynamically change video it won't load on Chromecast, it will be usefull to allow loading new video to Chromecast from Videojs api the same way we load another video with javascript. And allowing to send Title - Subtitle - and the new Poster

  player.src({
    "type": player.currentType(),
    "src": player.currentSrc()
  });
  player.load();
  player.play();
jessica-christie commented 7 years ago

The video stops playing for me too though I am not getting any error.