+1 on Tobie's comment: Use smaller z-indexes.

Scientific notation isn't hard to parse, if you want to handle it that
way, but even that's problematic -- that number has been rounded
(2.14748e9 == 2,147,480,000, which != 2,147,483,647), and so even
comparing numeric values isn't going to work. Knocking a few orders of
magnitude off your maximum z-index is probably your best bet. I mean,
even the range 10000 through -10000 gives you a massive number
(20,001) of vertical planes to stack...

FWIW,
--
T.J. Crowder
Independent Software Consultant
tj / crowder software / com
www.crowdersoftware.com


On Apr 1, 1:13 am, JoJo <tokyot...@gmail.com> wrote:
> On all browsers but Safari, getStyle('zIndex') returns a string
> representation of the max integer value "2147483647" for one of my
> elements.  However, on an older version of Safari, it return the
> exponentiated number "2.14748e+9".  After upgrading to the newest
> Safari, it now returns "2.14748e+009", which has 2 extra zeros. Now my
> code has broken because it does an equality check on this value.  How
> do I future-proof my code to work for all versions of Safari? I tried
> to use parseInt(), but this function doesn't understand exponeniated
> numbers.

-- 
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptacul...@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.

Reply via email to