Skip to content

Commit

Permalink
Merge pull request frankyghost#26 from fixedmachine/fix_vod_streams_seek
Browse files Browse the repository at this point in the history
Fixed streams random seeking with OSMFVIDEO model
  • Loading branch information
frankyghost committed Feb 13, 2014
2 parents b0194d9 + d07b6ef commit d1401e6
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/models/player.audio.video.osmf.js
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,8 @@ $p.newModel({
MBRItemChange: "OSMF_universal",
isDynamicStreamChange: "OSMF_updateDynamicStream",
autoSwitchChange: "OSMF_updateDynamicStream",
switchingChange: "OSMF_updateDynamicStream"
switchingChange: "OSMF_updateDynamicStream",
canSeekChange: "OSMF_canSeekChange"
},

applyMedia: function(destContainer) {
Expand Down Expand Up @@ -300,6 +301,16 @@ $p.newModel({
this.sendUpdate('availableQualitiesChange', result);
},

OSMF_canSeekChange: function(enabled) {
if(enabled){
this.allowRandomSeek = true;
this.media.loadProgress = 100;
}
else {
this.allowRandomSeek = false;
}
},

/* todo */
switchDynamicStreamIndex: function(index) {
if (index==-1) {
Expand Down

0 comments on commit d1401e6

Please sign in to comment.