Posted by jbrauer on July 14, 2009 at 3:36pm
| Project: | Popups API (Ajax Dialogs) |
| Version: | 6.x-2.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | needs review |
Issue Summary
When resizing the browser window with a popup open the popup window is not repositioned and the overlay does not cover the full window. Looking at how a couple of modules handle this Lightbox2 takes the same approach (with the same limitation) as Popups API. On the other hand Thickbox makes the overlay 100% wide and positions the popup at 50% wide by 50% tall and then uses negative margins of half the popup size which keeps the popup centered even when the window is resized.
In some searching I didn't find a compelling argument for not doing this in the way Thickbox does. Is there any reason Popups API shouldn't move in this direction.
| Attachment | Size |
|---|---|
| Popups resized PNG | 165.08 KB |
Comments
#1
Links to Thickbox and Lightbox2 demo sites for comparison
http://jquery.com/demo/thickbox/
http://www.stellapower.net/lightbox2
#2
Here's a first-round patch that does this. If the module moves this way we can probably remove the top and left variables as well.
#3
Oops silly mistake forgot to include the overlay width.