Fix soundcloud/soundcloud transition
This commit is contained in:
parent
afe14c2128
commit
b243f8bc7e
|
@ -1010,7 +1010,6 @@ Callbacks = {
|
|||
|
||||
changeMedia: function(data) {
|
||||
if (PLAYER) {
|
||||
console.log('getting volume for', PLAYER.type);
|
||||
PLAYER.getVolume(function (v) {
|
||||
VOLUME = v;
|
||||
setOpt("volume", VOLUME);
|
||||
|
|
|
@ -468,6 +468,11 @@ var SoundcloudPlayer = function (data) {
|
|||
self.videoLength = data.seconds;
|
||||
if(self.player && self.player.load) {
|
||||
self.player.load(data.id, { auto_play: true });
|
||||
var soundcloudNeedsToFuckingFixTheirPlayer = function () {
|
||||
self.setVolume(VOLUME);
|
||||
self.player.unbind(SC.Widget.Events.PLAY_PROGRESS);
|
||||
};
|
||||
self.player.bind(SC.Widget.Events.PLAY_PROGRESS, soundcloudNeedsToFuckingFixTheirPlayer);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in a new issue