Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2014
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. function readFile3(file, file2){
  2. fileA = URL.createObjectURL(file);
  3. audioElement.setAttribute('src', fileA);
  4. audioElement.play();
  5. var test = $("#musics").html();
  6.  
  7. $(audioElement).on("loadedmetadata", function () {
  8. var test3 = test.replace('<div class="music"><div class="bola"></div>' + file3[file2].name + '</div>', '<div class="music2"><div class="bola2"></div>' + file3[file2].name + '</div>');
  9. $("#musics").html(test3);
  10. $("#div3a").scrollTop(0);
  11. $("#div3a").scrollTop($(".music2").position().top);
  12. });
  13.  
  14. $(audioElement).on("ended", function () {
  15. if (file2 < fill - 1) {
  16. $("#musics").html(test);
  17. file2 = file2 + 1;
  18. readFile3(file3[file2], file2);
  19. }
  20. else {
  21. $("#musics").html(test);
  22. audioElement.load();
  23. }
  24. });
  25.  
  26. $(audioElement).on("timeupdate", function () {
  27. tempo();
  28. videoTimeUpdateHandler();
  29. });
  30. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement