Template:Appeal/Video-Impact/en: Difference between revisions

From Donate
Jump to navigation Jump to search
Content deleted Content added
Pgehres (WMF) (talk | contribs)
No edit summary
Pgehres (WMF) (talk | contribs)
No edit summary
Line 5: Line 5:
<html>
<html>
<script type='text/javascript'>
<script type='text/javascript'>

var documentWidth = $(document).width();
var appealWidth = documentWidth - 638; //static width for now

var playerW = appealWidth;
var playerH = playerW * 0.5625; //aspect ratio

$("#appeal-body").width( appealWidth );

$(mw).bind('EmbedPlayerNewPlayer', function( event, embedPlayer ){
$(mw).bind('EmbedPlayerNewPlayer', function( event, embedPlayer ){
$( embedPlayer ).bind( 'playerReady', function(){
$( embedPlayer ).bind( 'playerReady', function(){
embedPlayer.$interface.css({'width': 400, 'height':300})
embedPlayer.$interface.css({'width': playerW, 'height':playerH})
embedPlayer.updateLayout();
embedPlayer.updateLayout();
});
});

Revision as of 23:29, 29 November 2012