On 27-May-06, at 12:46 AM, Hamish Friedlander wrote:
> Whoops. Not sure why the partial send. Apologies to group. Lets try
> again
>
> There appears to be a bug in getElementPosition. At the top of the
> function is
>
> if (elem.x && elem.y) {
> /* it's just a MochiKit.Style.Coordinates object */
>
> It seems like ( in Firefox at any rate ) several normal DOM
> elements have x and y attributes. At least one of these is
> generally set to 0, so the && test fails and there aren't any
> problems. However on some floating elements this is not true and
> the wrong result is returned.
>
> My poor workaround is to add isUndefinedOrNull(elem.nodeType) to
> the test to try and eliminate the false matches. I'm not sure what
> the original intent of supporting arbitrary positioning using x and
> y attributes was though - is there a better way to detect this?
Hamish,
Could you please do me a favor and add your report to the bug tracker:
http://trac.mochikit.com/newticket
Thanks for reporting this!
Beau
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"MochiKit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/mochikit
-~----------~----~----~----~------~----~------~--~---