Welcome Guest Search | Active Topics | Sign In | Register

Auto-Centering Dialog? Options
Jamie Miller
Posted: Monday, September 26, 2011 9:55:31 AM
Rank: Member
Groups: Member

Joined: 2/6/2009
Posts: 26
Hi,

The dialogs automatically open centered in the browser window. However, if there's an image in the contenthtml that takes a while to load the dialog ends up not being in the center of the browser window.

Is there any way of getting the dialog to automatically re-center itself? Or do people get around this in other ways?
eo_support
Posted: Monday, September 26, 2011 2:15:26 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

The only reliable way to avoid that is to explicitly reserve space for the image. The dialog location is calculated when the dialog is displayed, so the only way to cause the dialog to re-calculate its position is to close and reopen it, obviously that would not be a practical solution. As a result, if you already know the image size, try to place it inside a div with a fixed size would reserve space for the image thus allow the dialog to position correctly.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.