dimensions plugin Mozilla bug

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

dimensions plugin Mozilla bug

Wizzud
While playing with Ext I encountered a problem in Firefox whereby the offset function in dimensions was causing an elem.style error. The reason is that there is a do-while loop if options.scroll is set, and that loop will go all the way up to the document, at which point - if the browser is Mozilla - the code attempts to check the css for overflow not visible and falls over because document has no style.
I fixed this in my version by modifying line 260 of dimensions.js and inserting a check for op, so the line now begins ...

if (op && jQuery.browser.mozilla && ....

This prevents the jQuery.css() call failing at the document level.
Reply | Threaded
Open this post in threaded view
|

Re: dimensions plugin Mozilla bug

Brandon Aaron
Thanks for the bug ... I'll get this fixed soon!

--
Brandon Aaorn

On 3/18/07, Wizzud <[hidden email]> wrote:

>
> While playing with Ext I encountered a problem in Firefox whereby the offset
> function in dimensions was causing an elem.style error. The reason is that
> there is a do-while loop if options.scroll is set, and that loop will go all
> the way up to the document, at which point - if the browser is Mozilla - the
> code attempts to check the css for overflow not visible and falls over
> because document has no style.
> I fixed this in my version by modifying line 260 of dimensions.js and
> inserting a check for op, so the line now begins ...
>
> if (op && jQuery.browser.mozilla && ....
>
> This prevents the jQuery.css() call failing at the document level.
> --
> View this message in context: http://www.nabble.com/dimensions-plugin-Mozilla-bug-tf3421935.html#a9537545
> Sent from the jQuery Plugins mailing list archive at Nabble.com.
>
>
> _______________________________________________
> jQuery mailing list
> [hidden email]
> http://jquery.com/discuss/
>

_______________________________________________
jQuery mailing list
[hidden email]
http://jquery.com/discuss/
Reply | Threaded
Open this post in threaded view
|

Re: dimensions plugin Mozilla bug

Brandon Aaron
After some investigating, I'm not able to reproduce what you describe.
Could you possibly post up or send me a test case for this? The
highest the loop should go to is the body tag (in Mozilla). Once it
hits the body tag inside the loop you describe the code that gives you
an error *should* not run. Also, you might want to insure you have the
latest revision: 1485.

Thanks
--
Brandon Aaron

On 3/18/07, Brandon Aaron <[hidden email]> wrote:

> Thanks for the bug ... I'll get this fixed soon!
>
> --
> Brandon Aaorn
>
> On 3/18/07, Wizzud <[hidden email]> wrote:
> >
> > While playing with Ext I encountered a problem in Firefox whereby the offset
> > function in dimensions was causing an elem.style error. The reason is that
> > there is a do-while loop if options.scroll is set, and that loop will go all
> > the way up to the document, at which point - if the browser is Mozilla - the
> > code attempts to check the css for overflow not visible and falls over
> > because document has no style.
> > I fixed this in my version by modifying line 260 of dimensions.js and
> > inserting a check for op, so the line now begins ...
> >
> > if (op && jQuery.browser.mozilla && ....
> >
> > This prevents the jQuery.css() call failing at the document level.
> > --
> > View this message in context: http://www.nabble.com/dimensions-plugin-Mozilla-bug-tf3421935.html#a9537545
> > Sent from the jQuery Plugins mailing list archive at Nabble.com.
> >
> >
> > _______________________________________________
> > jQuery mailing list
> > [hidden email]
> > http://jquery.com/discuss/
> >
>

_______________________________________________
jQuery mailing list
[hidden email]
http://jquery.com/discuss/
Reply | Threaded
Open this post in threaded view
|

Re: dimensions plugin Mozilla bug

GrgC
Brandon Aaron wrote
After some investigating, I'm not able to reproduce what you describe.
Could you possibly post up or send me a test case for this?
Hello,

I just encountered this bug (rev. 2454) when trying to get dimensions of a table inside an iframe contained in a hidden DIV (the whole structure is actually html>frameset>frameset>frame>html>body>form>div>div(hidden)>iframe>html>body>table but after debugging with Firebug I *think* the problem lies with the document inside the iframe).

I can't give you an example right away since the whole page&code are a bit complicated, plus I am in a kind of a hurry to finish this right now, but I could try to reproduce the bug later on a test page if it helps.