1
0
Fork 0
mirror of https://github.com/jellyfin/jellyfin-web synced 2025-03-30 19:56:21 +00:00

update components

This commit is contained in:
Luke Pulverenti 2016-01-18 14:07:26 -05:00
parent 4572a9dbaf
commit 576ca0442c
22 changed files with 472 additions and 303 deletions

View file

@ -3,16 +3,15 @@
*/
import Event from '../events';
import EventHandler from '../event-handler';
import {ErrorTypes, ErrorDetails} from '../errors';
class KeyLoader {
class KeyLoader extends EventHandler {
constructor(hls) {
this.hls = hls;
super(hls, Event.KEY_LOADING);
this.decryptkey = null;
this.decrypturl = null;
this.ondkl = this.onDecryptKeyLoading.bind(this);
hls.on(Event.KEY_LOADING, this.ondkl);
}
destroy() {
@ -20,10 +19,10 @@ class KeyLoader {
this.loader.destroy();
this.loader = null;
}
this.hls.off(Event.KEY_LOADING, this.ondkl);
EventHandler.prototype.destroy.call(this);
}
onDecryptKeyLoading(event, data) {
onKeyLoading(data) {
var frag = this.frag = data.frag,
decryptdata = frag.decryptdata,
uri = decryptdata.uri;