Bug Tracker

Ticket #9773 (closed bug: invalid)

Opened 4 years ago

Last modified 4 years ago

getComputedStyle fails for an element created in another window because elem.ownerDocument == undefined

Reported by: TiTi Owned by:
Priority: low Milestone: 1.next
Component: css Version: 1.6.2
Keywords: Cc:
Blocking: Blocked by:



Test case to reproduce my issue:  http://jsfiddle.net/GnPTe/ [Allow popups for jsfiddle] When the popup is opened, mouseover the text.

Basically, an exception occurs at the line :

"if ( !(defaultView = elem.ownerDocument.defaultView) ) {"

because elem.ownerDocument is undefined. What am I missing?

Change History

comment:1 Changed 4 years ago by timmywil

  • Priority changed from undecided to low
  • Resolution set to invalid
  • Status changed from new to closed
  • Component changed from unfiled to css

delegate callbacks are not passed the element. tr is undefined at that point. Change tr to this and everything works fine:  http://jsfiddle.net/timmywil/GnPTe/1/

On a side note, eww popups.

Note: See TracTickets for help on using tickets.