2017-05-19 01:50:56 +08:00
|
|
|
function deleteVideo( index ) {
|
|
|
|
window.location.replace( thisUrl+'?view='+currentView+'&eid='+eventId+'&deleteIndex='+index );
|
2008-07-14 21:54:50 +08:00
|
|
|
}
|
|
|
|
|
2017-05-19 01:50:56 +08:00
|
|
|
function downloadVideo( index ) {
|
|
|
|
window.location.replace( thisUrl+'?view='+currentView+'&eid='+eventId+'&downloadIndex='+index );
|
2008-07-14 21:54:50 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
var generateVideoTimer = null;
|
|
|
|
|
2017-05-19 01:50:56 +08:00
|
|
|
function generateVideoProgress() {
|
|
|
|
var tickerText = $('videoProgressTicker').get('text');
|
|
|
|
if ( tickerText.length < 1 || tickerText.length > 4 )
|
|
|
|
$('videoProgressTicker').set( 'text', '.' );
|
|
|
|
else
|
|
|
|
$('videoProgressTicker').appendText( '.' );
|
2008-07-14 21:54:50 +08:00
|
|
|
}
|
|
|
|
|
2017-05-19 01:50:56 +08:00
|
|
|
function generateVideoResponse( respObj, respText ) {
|
|
|
|
window.location.replace( thisUrl+'?view='+currentView+'&eid='+eventId+'&generated='+((respObj.result=='Ok')?1:0) );
|
2008-07-14 21:54:50 +08:00
|
|
|
}
|
|
|
|
|
2017-05-19 01:50:56 +08:00
|
|
|
function generateVideo( form ) {
|
|
|
|
var parms = 'view=request&request=event&action=video';
|
|
|
|
parms += '&'+$(form).toQueryString();
|
|
|
|
var query = new Request.JSON( { url: thisUrl, method: 'post', data: parms, onSuccess: generateVideoResponse } );
|
|
|
|
query.send();
|
|
|
|
$('videoProgress').removeClass( 'hidden' );
|
|
|
|
$('videoProgress').setProperty( 'class', 'warnText' );
|
|
|
|
$('videoProgressText').set( 'text', videoGenProgressString );
|
|
|
|
generateVideoProgress();
|
|
|
|
generateVideoTimer = generateVideoProgress.periodical( 500 );
|
2008-07-14 21:54:50 +08:00
|
|
|
}
|