mirror of https://github.com/calzoneman/sync.git
Fix vimeo synchronization, slight playlist tweak
Clicking the delete button on a playlist entry now removes the button strip before playing the removal animation, to prevent multiclicking
This commit is contained in:
parent
24f14530a4
commit
d51b900010
|
@ -16,6 +16,7 @@ function addUser(name, rank, leader) {
|
||||||
div.appendChild(flair);
|
div.appendChild(flair);
|
||||||
div.appendChild(span);
|
div.appendChild(span);
|
||||||
fmtUserlistItem(div, rank, leader);
|
fmtUserlistItem(div, rank, leader);
|
||||||
|
if(RANK >= Rank.Moderator)
|
||||||
addUserDropdown(div, name);
|
addUserDropdown(div, name);
|
||||||
$('#userlist')[0].appendChild(div);
|
$('#userlist')[0].appendChild(div);
|
||||||
}
|
}
|
||||||
|
@ -155,6 +156,7 @@ function addQueueButtons(li) {
|
||||||
|
|
||||||
// Callback time
|
// Callback time
|
||||||
$(btnRemove).click(function() {
|
$(btnRemove).click(function() {
|
||||||
|
btnstrip.remove();
|
||||||
var idx = $('#queue').children().index(li);
|
var idx = $('#queue').children().index(li);
|
||||||
socket.emit('unqueue', { pos: idx });
|
socket.emit('unqueue', { pos: idx });
|
||||||
});
|
});
|
||||||
|
@ -325,7 +327,7 @@ function initVI(data) {
|
||||||
var div = currentEmbed.parent();
|
var div = currentEmbed.parent();
|
||||||
currentEmbed.remove();
|
currentEmbed.remove();
|
||||||
// Ugly but it's the only way I managed to get the API calls to work
|
// Ugly but it's the only way I managed to get the API calls to work
|
||||||
div[0].innerHTML = '<iframe id="ytapiplayer" src="http://player.vimeo.com/video/' + data.id + '" width="640" height="390" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe>';
|
div[0].innerHTML = '<iframe id="ytapiplayer" src="http://player.vimeo.com/video/' + data.id + '?api=1&player_id=ytapiplayer" width="640" height="390" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe>';
|
||||||
// $f() is defined by froogaloop, Vimeo's API wrapper
|
// $f() is defined by froogaloop, Vimeo's API wrapper
|
||||||
PLAYER = $f($('iframe')[0]);
|
PLAYER = $f($('iframe')[0]);
|
||||||
// So we can retrieve the ID synchronously instead of waiting for
|
// So we can retrieve the ID synchronously instead of waiting for
|
||||||
|
|
Loading…
Reference in New Issue