Mercurial > hg > webaudioevaluationtool
comparison core.js @ 796:f69ec262337a
Audio fragment buffer pool objects have loading progress element
author | Nicholas Jillings <n.g.r.jillings@se14.qmul.ac.uk> |
---|---|
date | Thu, 17 Dec 2015 10:35:06 +0000 |
parents | a75a4e0af44f |
children | b7862798441d |
comparison
equal
deleted
inserted
replaced
795:a75a4e0af44f | 796:f69ec262337a |
---|---|
801 errorSessionDump('Fragment '+audioObj.id+' 404 error'); | 801 errorSessionDump('Fragment '+audioObj.id+' 404 error'); |
802 } | 802 } |
803 } | 803 } |
804 }); | 804 }); |
805 }; | 805 }; |
806 this.progress = 0; | |
807 this.progressCallback = function(event){ | |
808 if (event.lengthComputable) | |
809 { | |
810 this.progress = event.loaded / event.total; | |
811 } | |
812 }; | |
813 this.xmlRequest.addEventListener("progress", this.progressCallback); | |
806 this.xmlRequest.send(); | 814 this.xmlRequest.send(); |
807 }; | 815 }; |
808 }; | 816 }; |
809 | 817 |
810 this.play = function(id) { | 818 this.play = function(id) { |