padmaAPI/static/js/liveFuncs.js
2010-07-17 20:48:44 +05:30

25 lines
649 B
JavaScript

$('.removeClip').live("click", function() {
$(this).parents('.padmaClip').slideUp("slow", function() {
$(this).remove();
});
});
$('.clipView').live("click", function() {
var layer = $(this).parents('.padmaClip').data("layer");
var html = tmpl("tmpl_playerWindow", {'layer': layer});
if (typeof playerWindow != 'undefined') {
playerWindow.close();
}
playerWindow = window.open();
playerWindow.document.write(html);
});
/*
$('.clipDownload').live("click", function() {
var layer = $(this).parents('.padmaClip').data("layer");
console.log(layer);
var downloadUrl = layer.downloadUrl;
window.open(downloadUrl);
});
*/