<?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>49027</bug_id>
          
          <creation_ts>2010-11-04 14:30:57 -0700</creation_ts>
          <short_desc>video controls RenderReplaced::layout() calls setNeedsLayout(false) while its children still need layout</short_desc>
          <delta_ts>2011-11-28 08:56:57 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Layout and Rendering</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>PC</rep_platform>
          <op_sys>OS X 10.5</op_sys>
          <bug_status>NEW</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>53020</dependson>
          <blocked>49019</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="James Robinson">jamesr</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>dglazkov</cc>
    
    <cc>eric.carlson</cc>
    
    <cc>hyatt</cc>
    
    <cc>koivisto</cc>
    
    <cc>mitz</cc>
    
    <cc>simon.fraser</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>304876</commentid>
    <comment_count>0</comment_count>
    <who name="James Robinson">jamesr</who>
    <bug_when>2010-11-04 14:30:57 -0700</bug_when>
    <thetext>The ASSERT()s in https://bugs.webkit.org/show_bug.cgi?id=49019 trigger on the following HTML:

&lt;!DOCTYPE html&gt;
&lt;video controls&gt;&lt;/video&gt;

as well as most of the media/ tests.  The render tree looks something like this:


RenderView 0x3dc3cd8                   	#document	0x3dfed20
  RenderBlock 0x3e3c968                	HTML	0x3e3bf40
    RenderBody 0x3e37968               	BODY	0x3e3cd90
      RenderVideo 0x3e4aa88            	VIDEO	0x3e37a30
*       RenderBlock (relative positioned) 0x3e4ae48	DIV	0x3e38950
          RenderFlexibleBox (positioned) 0x3e48308	DIV	0x3e4b050
            RenderButton 0x3e48808     	INPUT	0x3e4c610
            RenderFlexibleBox (positioned) 0x3e48ea8	DIV	0x3e4cb90
              RenderBlock (positioned) 0x3e49438	DIV	0x3e4cc30
                RenderText 0x3db0ed8   	#text	0x3db0e50 &quot;00:00&quot;
              RenderSlider 0x3e499a8   	INPUT	0x3e4ccd0
                RenderBlock 0x3db0a08  	DIV	0x3db01f0
            RenderButton 0x3dafb88     	INPUT	0x3e476d0

The RenderBlock root of the controls is marked as m_needsLayout=true, m_normalChildNeedsLayout=true, m_posChildNeedsLayout=true at the end of RenderReplaced::layout() on its parent RenderVideo.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>304885</commentid>
    <comment_count>1</comment_count>
    <who name="Simon Fraser (smfr)">simon.fraser</who>
    <bug_when>2010-11-04 14:39:28 -0700</bug_when>
    <thetext>Oooh, maybe RenderTreeAsText should optionally mark renderers that still need layout.  If we did that in DRT, it might catch lots of bugs.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>304911</commentid>
    <comment_count>2</comment_count>
    <who name="James Robinson">jamesr</who>
    <bug_when>2010-11-04 15:13:58 -0700</bug_when>
    <thetext>(In reply to comment #1)
&gt; Oooh, maybe RenderTreeAsText should optionally mark renderers that still need layout.  If we did that in DRT, it might catch lots of bugs.

I like it.  I also think that DRT should ASSERT that if any renderers are marked as needing layout at the end of the test that the appropriate layout timer is set and the layout root (if set) is an ancestor of all dirty objects.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>304967</commentid>
    <comment_count>3</comment_count>
    <who name="James Robinson">jamesr</who>
    <bug_when>2010-11-04 16:06:26 -0700</bug_when>
    <thetext>RenderReplaced::layout() isn&apos;t written to handle children and in fact RenderReplaced overrides canHaveChildren() to return false, however RenderMedia goes ahead and inserts a shadow RenderObject tree underneath itself.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>305307</commentid>
    <comment_count>4</comment_count>
    <who name="Antti Koivisto">koivisto</who>
    <bug_when>2010-11-05 09:11:10 -0700</bug_when>
    <thetext>(In reply to comment #3)
&gt; RenderReplaced::layout() isn&apos;t written to handle children and in fact RenderReplaced overrides canHaveChildren() to return false, however RenderMedia goes ahead and inserts a shadow RenderObject tree underneath itself.

RenderMedia also overrides layout() which is supposed to handle this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>350396</commentid>
    <comment_count>5</comment_count>
    <who name="Dimitri Glazkov (Google)">dglazkov</who>
    <bug_when>2011-02-13 08:42:18 -0800</bug_when>
    <thetext>I think I can fix this while I am in here.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>383513</commentid>
    <comment_count>6</comment_count>
    <who name="Dimitri Glazkov (Google)">dglazkov</who>
    <bug_when>2011-04-11 14:17:53 -0700</bug_when>
    <thetext>(In reply to comment #5)
&gt; I think I can fix this while I am in here.

One fix write RenderMedia::layout as full replacement for RenderReplaced::layout.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>509860</commentid>
    <comment_count>7</comment_count>
    <who name="Dimitri Glazkov (Google)">dglazkov</who>
    <bug_when>2011-11-28 08:56:57 -0800</bug_when>
    <thetext>(In reply to comment #5)
&gt; I think I can fix this while I am in here.

I am no longer &quot;in here&quot; :(</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>