Greetings all,
Bet everyone is tired of hearing me talk about the
NS4 resize problems. I promise this is the last one
for a while, but somebody needed this answer.
When using frames and writing DynAPI from one frame to
another (ie one is blank and the other writes the
contents in to it) NS4 has a problem where on the
first resize after load it fails to recreate the
layers in the "blank" frame. After the first resize,
it will then recreate the layers every time. The
following is not a "good" solution, but it works.
Add a onresize function to the document and include a
line specific to the dyndocument being created in the
blank frame.
I create the dyndocument in the top frame with the
following:
tdoc = new DynDocument(parent.top1);
tdoc is a variable and top1 is the name I assigned to
the top frame (by the way, don't use top as I believe
it is reserved and will not work).
Then to get the first resize to fire correctly, the
onresize function looks like this:
DynAPI.onResize=function() {
tdoc.recreateAll();
}
After the first resize it actually causes it to be
recreated twice on a resize, but that is better than
not having it the first time. You could also add a
conditional "if (is.ns4)" to it so that it only fires
when needed.
if (is.ns4) tdoc.recreateAll();
Anyone come up with a better solution?
This problem has shown up in ns4.08 and ns4.76 the
browsers I have installed.
I have posted some examples so you can see the problem
under NS4. I am also using these examples to test
images in stacked layers, so the download is a little
slow and under NN6, since there is no onloaderdone
function, the page has to be reloaded to get the
images to show. I am also using my modified dynimage
file so that the dynimages do not stop the resize.
Original frames with the problem (use ns4)
http://www.merlinsworld.net/dynapi_ri_dcexamples/frames_nstest_1.shtml
Modified pages with the function added:
http://www.merlinsworld.net/dynapi_ri_dcexamples/frames_nstest_1mod.shtml
There is also a link on the mod page that shows the
dynapi code used to create the layers.
Is this stuff useful?
Cheers,
Dave C. "You Changed What?!?"
__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.
http://personal.mail.yahoo.com/
_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help