WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
13103
REGRESSION (
r15069
): getPropertyValue() returns null when element has display: none (affects Technorati.com)
https://bugs.webkit.org/show_bug.cgi?id=13103
Summary
REGRESSION (r15069): getPropertyValue() returns null when element has display...
Stef Pause
Reported
2007-03-17 16:31:24 PDT
Go to Technorati.com and click the "Sign In" link at the top-right. This onclick JavaScript should cause the div id="signin" to change its style (via a slide effect) to "display: block;" which it does correctly in Safari v2.0.4, Firefox, Camino, etc. However, in the latest Webkit nightly it slides down then immediately changes back to "display: none;". This obviously makes it somewhat difficult to sign in ;) The relevant JavaScript is: onclick="if(document.all) $('select').hide();if($e('signin').style.display=='block') {$('#signin').slideUp('fast'); } else { $('#signin').slideDown('fast');$e('username').focus()};return false" I'm not entirely sure if it's a Javascript bug or a DOM bug, I suspect the former, so I've filed it under "New Bugs".
Attachments
Reduction
(645 bytes, text/html)
2007-03-18 22:20 PDT
,
Matt Lilek
no flags
Details
Honor display property when we have no renderer.
(892 bytes, patch)
2007-03-29 01:27 PDT
,
Dave Hyatt
mitz: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Matt Lilek
Comment 1
2007-03-18 22:20:36 PDT
Created
attachment 13701
[details]
Reduction The heart of this bug is that when an element has display: none, getPropertyValue() returns null instead of 'none' like Firefox/Opera. This works in Safari 2.0.4 because jQuery (Technorati's JS framework of choice) checks if the getComputedStye() returns null, which Safari 2.0.4 does when an element has display: none. In that case they then check if they're looking for the display property and return 'none'. The reason this disappears in ToT after the animation is because we don't return 'none', jQuery's animation gizmo never gets sets the display as block permanently when it's finished, presuming we're handling that ourselves (ie: we want it to be display: inline) and removes the temporary display: block it added during animation.
Maciej Stachowiak
Comment 2
2007-03-19 11:51:34 PDT
<
rdar://problem/5072345
>
mitz
Comment 3
2007-03-26 12:55:11 PDT
***
Bug 13193
has been marked as a duplicate of this bug. ***
mitz
Comment 4
2007-03-26 13:48:47 PDT
Regressed in <
http://trac.webkit.org/projects/webkit/changeset/15069
>. Safari 2 returns null from getComputedStyle() if the element doesn't have a renderer.
r15069
and later return a CSSStyleDeclaration (which subsequently return null for all properties, see
bug 12384
).
Dave Hyatt
Comment 5
2007-03-29 01:27:07 PDT
Created
attachment 13859
[details]
Honor display property when we have no renderer.
mitz
Comment 6
2007-03-29 01:27:46 PDT
***
Bug 13223
has been marked as a duplicate of this bug. ***
mitz
Comment 7
2007-03-29 01:40:34 PDT
Comment on
attachment 13859
[details]
Honor display property when we have no renderer. Needs a change log and a layout test. Also make sure that existing tests pass or are updated as needed. r=me
Dave Hyatt
Comment 8
2007-03-29 01:58:34 PDT
Fixed in
r20570
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug