This project is archived and is in readonly mode.

#577 open
Jason Petrik

Element.Position.setOffsetOption Result of expression 'offsetParent' [null] is not an object.

Reported by Jason Petrik | June 17th, 2011 @ 06:26 PM | in 1.4.0.2 (closed)

Upgraded from 1.3.1.1 to 1.3.2.1 and starting receiving "Result of expression 'offsetParent' [null] is not an object."

I saw two problems with setOffsetOption:

1) Defined parentOffset then reassigned it, then used it

2) Used a method on offsetParent, then checked if offsetParent was null.

Comments and changes to this ticket

  • fakedarren

    fakedarren July 16th, 2011 @ 05:27 PM

    • State changed from “new” to “open”
  • Arian

    Arian August 18th, 2011 @ 01:46 AM

    • Milestone set to 1.4.0.2
    • Milestone order changed from “197604” to “0”

    Your patch is a bit corrupted (can't just apply it with git am. Can't you push this to github? Also a testcase on http://jsfiddle.net would be great!

  • Jason Petrik

    Jason Petrik August 18th, 2011 @ 08:42 PM

    http://jsfiddle.net/nYfrg/2/

    As I was stripping my code down to test in jsfiddle I found it wasn't quite what I thought it was (of course!). When an element is styled with "position: fixed !important" element.position() will throw the error above.

    I don't know why I had my element styled that way and I have removed it. It appears to be an edge case, but I have made a pull request on github (hopefully correctly).

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

The MooTools Extensions

People watching this ticket

Attachments

Pages