# Dynamically sizing flash object in Safari

**URL:** <https://forum.kirupa.com/t/dynamically-sizing-flash-object-in-safari/312337>\
**Category:** flash\
**Created:** [July 30, 2010, 11:24pm UTC](https://forum.kirupa.com/t/dynamically-sizing-flash-object-in-safari/312337 "2010-07-30T23:24:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mcmustang](https://avatars.discourse-cdn.com/v4/letter/m/eada6e/32.png) [@mcmustang](https://forum.kirupa.com/u/mcmustang)\
**Post date:** [July 30, 2010, 11:24pm UTC](https://forum.kirupa.com/t/dynamically-sizing-flash-object-in-safari/312337/1 "2010-07-30T23:24:59Z")

</div>

I have a weird problem with Safari 5.0 and Flash player 10.1…

When I resize the flash html object via ExternalInterface and JavaScript flash will jump down the page a little bit for a fraction of a second.

Here is an example:

[http://www.benmcmaster.com/test/testSafari/](http://www.benmcmaster.com/test/testSafari/)

This may not be a flash question at all. It may be a CSS or JavaScript problem. I just wanted to see if anyone else has seen this. It seems to only be a problem with Safari 5 and Flash 10.1.

You can view the source of the html page. Here is the code inside the sample FLA:

one.addEventListener(MouseEvent.CLICK, oneClick);  
one.buttonMode = true;  
two.addEventListener(MouseEvent.CLICK, twoClick);  
two.buttonMode = true;

this.addEventListener(Event.ADDED\_TO\_STAGE, addedToStage);

function oneClick(e)  
{  
ExternalInterface.call(“changeDivHeight”, 2000);   
}

function twoClick(e)  
{  
ExternalInterface.call(“changeDivHeight”, 2500);  
}

Thank you!!!

* * *

Ben McMaster  
[http://www.benmcmaster.com](http://www.benmcmaster.com)
