Added flash size constraining
This commit is contained in:
parent
abbaa35188
commit
9b9ba9c33c
1 changed files with 14 additions and 0 deletions
|
@ -1,7 +1,21 @@
|
|||
function constrainFlashSize()
|
||||
{
|
||||
var target = $('.post-type-flash object');
|
||||
var container = $('#inner-content');
|
||||
target.width('');
|
||||
if (target.width() > container.width())
|
||||
{
|
||||
target.width(container.width())
|
||||
target.height(container.width() * target.attr('height') / target.attr('width'));
|
||||
}
|
||||
}
|
||||
|
||||
$(function()
|
||||
{
|
||||
function onDomUpdate()
|
||||
{
|
||||
constrainFlashSize();
|
||||
|
||||
$('#sidebar .permalink').bindOnce('select-link', 'click', function(e)
|
||||
{
|
||||
e.preventDefault();
|
||||
|
|
Loading…
Reference in a new issue