Create a  DynAPI.onResize=function() { }
 
in that function do something like this:
 
myLayer.moveTo( (DynAPI.document.getWidth()/2)-(myLayer.w/2), (DynAPI.document.getHeight()/2)-(myLayer.h/2))
 
that should center the layer as soon as the onResize is called.
 
cya,

Pascal Bestebroer
[EMAIL PROTECTED]
http://www.dynamic-core.net

-----Oorspronkelijk bericht-----
Van: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]Namens rlb
Verzonden: zondag 14 januari 2001 6:52
Aan: '[EMAIL PROTECTED]'
Onderwerp: [Dynapi-Help] It's late again and I've been doing some more pondering

Resizing a window.

Has anyone put together anything along these lines already:

I'm thinking about generating an image that is about three times as big as a browser window and placing it on a dynlayer (draggable), let's say 2500 pixels square and I would like to center it in a browser window and basically fill the window to the edges with the image. Is there a facility for repositioning  the image in the center upon resizing the window in a DynAPI object, or do I need to work on it in JS ?
Thanks
 

--

bobb

http://64.33.167.222/
 

Reply via email to