<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>75294</bug_id>
          
          <creation_ts>2011-12-28 00:22:00 -0800</creation_ts>
          <short_desc>:empty still matches after content is added to element with display: none</short_desc>
          <delta_ts>2012-04-26 22:37:46 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>CSS</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>79734</dup_id>
          
          <bug_file_loc>http://jsfiddle.net/gtXYC/1/</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter>webkit</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>ap</cc>
    
    <cc>davidbarr</cc>
    
    <cc>jchaffraix</cc>
    
    <cc>simon.fraser</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>527573</commentid>
    <comment_count>0</comment_count>
    <who name="">webkit</who>
    <bug_when>2011-12-28 00:22:00 -0800</bug_when>
    <thetext>Compare the following examples (using innerHTML to add content):

1) http://jsfiddle.net/gtXYC/0/ (works)
2) http://jsfiddle.net/gtXYC/1/ (broken)

Same problem using appendChild() instead of innerHTML:

3) http://jsfiddle.net/gtXYC/2/ (works)
4) http://jsfiddle.net/gtXYC/3/ (broken)

Examples 1/3: The div&apos;s background-color changes based on whether the div is empty or not.
Examples 2/4: Same situation, except that the visibility of the div should change. The problem is that :empty still matches after content is added to the div.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>610336</commentid>
    <comment_count>1</comment_count>
    <who name="David Barr">davidbarr</who>
    <bug_when>2012-04-25 21:43:20 -0700</bug_when>
    <thetext>Verified as fixed with WebKit Nightly Version 5.1.5 (6534.55.3, r115022).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>610590</commentid>
    <comment_count>2</comment_count>
    <who name="Julien Chaffraix">jchaffraix</who>
    <bug_when>2012-04-26 07:28:20 -0700</bug_when>
    <thetext>(In reply to comment #1)
&gt; Verified as fixed with WebKit Nightly Version 5.1.5 (6534.55.3, r115022).

Are we sure the test cases attached on this bug are covered? Shouldn&apos;t we land them to prevent a regression?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>610695</commentid>
    <comment_count>3</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2012-04-26 10:06:16 -0700</bug_when>
    <thetext>Since we don&apos;t know what fixed this, and haven&apos;t landed tests, this is WORKSFORME at best. I agree with Julien that we should investigate the need to land tests.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>611167</commentid>
    <comment_count>4</comment_count>
    <who name="David Barr">davidbarr</who>
    <bug_when>2012-04-26 18:46:38 -0700</bug_when>
    <thetext>$ bisect-builds http://jsfiddle.net/gtXYC/1/ -r 109280:109476 -p -s
Fails: r109280  Works: r109476
http://trac.webkit.org/log/trunk/?rev=109476&amp;stop_rev=109281

See http://trac.webkit.org/changeset/109417/trunk

  :empty still applies to elements made non-empty via page dynamics.
  https://bugs.webkit.org/show_bug.cgi?id=79734

Covered by test:
  http://trac.webkit.org/browser/trunk/LayoutTests/fast/selectors/empty-element-made-non-empty.html?rev=109417</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>611169</commentid>
    <comment_count>5</comment_count>
    <who name="David Barr">davidbarr</who>
    <bug_when>2012-04-26 18:48:13 -0700</bug_when>
    <thetext>

*** This bug has been marked as a duplicate of bug 79734 ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>611254</commentid>
    <comment_count>6</comment_count>
    <who name="Alexey Proskuryakov">ap</who>
    <bug_when>2012-04-26 22:37:46 -0700</bug_when>
    <thetext>Thank you for researching when this got fixed!</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>