Hi,
Details about the platform(s) upon which the bug was
detected.
System: Apple Mac G3
OS: MacOS9
Browser: Netscape v 6
Netscape6 Mozilla/5.0(Macintosh;N;PPC;en-GB;m18)
Gecko/20001108 Netscape6/6.0
System: Compaq Deskpro 733
OS: Windows2000 (no service pack)
Browser: Netscape v 6
Netscape6 Mozilla/5.0(Windows;U;Windows NT-5;en-
US;m18) Gecko/20001108 Netscape6/6.0
Using: DynAPI v2.53
Bug description: The bug was found on the above
configuration while viewing the example file
dynapi/examples/dynapi.gui.scrollpane.html
In NS6.0 on the both Mac and PC, bug manifests itself
in same circumstances. When the user loads the afore
mentioned file, the label is displayed, but the
scrollpane isnt. The user has ensured that the
labelsize is set to dimensions greater than the
scrollpane size.
The only apparent workaround for this bug is to
refresh the page. After this the page is downloaded
correctly and the user can use the scrollpane normally.
Logged In: YES
user_id=184633
It isn't a bug of scrollpane itself. It's a bug of DynImage.
To verify this, try to open dynapi.gui.buttonimage.html
from local hard disk. You can observe such behavior both in
NS6 and IE4 (but only first time! if you can see a button,
rename dynapy folder and try again).
Logged In: YES
user_id=268682
same problem here, any fixes? it becomes weirdo if U put it
into frames... after the scorllbar finally comes up and
working fine and u reload the page, it dissapears again! in
NS6.0
- PC windows2000
- NS6.0
The only crued fix for me so far is to:
1) write a mess for NS6 users to reload the page to see
scrolbar
2) then when user reload page it location.replace with the
another file but same code. this seems to work?!?!(weird)
and u can reload it as many times as u want to, and it will
still work.
3) I am not a programmer, so I do not know how and where to
fix the dynimage.js if it is in fact the main problem
behind all this.
AGAIN, any fixes? :)
Steven Seah
Logged In: YES
user_id=725670
I have had a similar problem with Mozilla on my Unix
workstation.
You can test the following (simple) solution for the
dynapi.gui.buttonimage.html example:
just put the "addChild" command (that adds the buttonImage
to its parent layer) BEFORE you do the "setImage" that
displays the image. Apparently, Mozilla can only setImage a
layer that already is a child of another layer.
Perhaps your scrollbar problem has a similar solution.
I first encountered this problem when trying to display an
image animation (using a DynImage). In internet explorer it
worked just fine, but Mozilla didn't give me the image until I
put the first setImage of the animation (that displays the first
frame) after the addChild() call that adds the DynImage to its
viewport (=parent layer).
Logged In: YES
user_id=725670
Sorry, my solution didn't work for button images, only for
dynimages.
Maybe there is a problem with the way button images use
dynimage code? For instance, should bRedraw be set to true
in some/all of the setImage() calls?
Logged In: YES
user_id=725670
I've found a solution that works (at least on Internet Explorer
and Mozilla), using DynAPI 2.5.6.
Instead of using the upgrade to 2.5.7 (which alters the
dynimage.js file, but doesn't solve the problem), you can try
the following:
In the DynImage() function, you should see the following lines:
if (this.img && this.img.dynimages) {
this.img.dynimages[this.img.dynimages.length]=this;
this.imgresize=true;
}
But I found that this if-test just isn't working the way it should
and you should should alter it to:
if(this.img) {
this.img.dynimages[this.img.dynimages.length]=this;
this.imgresize=true;
}
This has also cured a bug that ocurred when testing in
Internet Explorer, but that could have been a coincidence.
The second step is to disable the "hack" in the
buttomimage.js file by commenting out the line "setTimeout
(this+".setSize
("+this+".defaultImage.width,"+this+".defaultImage.height);",0)
;" at the bottom of the setImages function. (note that this is
also done in 2.5.7, so the hack is probably worthless).
I also used the following sequence (for each buttonimage and
also for the dynimage I used in my animation).
1. Load (or preload) the image using DynImage.getImage(),
2. Define your DynImage/buttonImage (by using "new
buttomImage() for instance). But don't specify any parameters.
3. Add the button (or dynimage) to its parent by using the
addChild() function.
4.. Set any properties and set the images using setImages()
(on your buttonimage).
5. Instead of the hack (that actually tries to do a setSize(),
but uses methods/properties to compute the width and height
it wants to set the button to), use the setSize() function in
your code directly, but don't use any properties/methods (like
getWidth() which is bugged in Mozilla and also img.width like
in the hack doesn't seem to work). Instead, use the real
values for the image (if possible).
Example from my code:
Step 1:
buttonUpNormal=DynImage.getImage
("dynapi/buttons/blue_Up.gif");
buttonUpHighlight=DynImage.getImage
("dynapi/buttons/yellow_Up.gif");
Step 2:
buttonUp=new ButtonImage();
Step 3:
buttonLayer.addChild(buttonUp);
Step 4:
buttonUp.setImages(buttonUpNormal,buttonUpHighlight);
buttonUp.moveTo(45,125);
Step 5:
buttonUp.setSize(15,15)
This has worked in my case and apparently it's the setSize
that does the trick for Mozilla. If anyone can explain this to
me, I would be happy to hear that.
Note: if you also do stuff (like zooming/scrolling) with
DynImages in Mozilla and you have trouble getting Mozilla to
display the image changes, try setting the image again to its
source (just use the setImage() again). This has also proven
valuable to me.