<?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>78562</bug_id>
          
          <creation_ts>2012-02-13 18:43:15 -0800</creation_ts>
          <short_desc>New flexboxes don&apos;t split into columns</short_desc>
          <delta_ts>2012-02-15 16:47:04 -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>Unspecified</rep_platform>
          <op_sys>Unspecified</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>
          
          <blocked>62048</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Ojan Vafai">ojan</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>hyatt</cc>
    
    <cc>tony</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>555848</commentid>
    <comment_count>0</comment_count>
    <who name="Ojan Vafai">ojan</who>
    <bug_when>2012-02-13 18:43:15 -0800</bug_when>
    <thetext>RenderBlock* RenderBlock::createAnonymousBlockWithSameTypeAs(RenderBlock* otherAnonymousBlock) const
{
    if (otherAnonymousBlock-&gt;isAnonymousColumnsBlock())
        return createAnonymousColumnsBlock();
    if (otherAnonymousBlock-&gt;isAnonymousColumnSpanBlock())
        return createAnonymousColumnSpanBlock();
    return createAnonymousBlock(otherAnonymousBlock-&gt;style()-&gt;display() == BOX);
}</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>555850</commentid>
    <comment_count>1</comment_count>
    <who name="Ojan Vafai">ojan</who>
    <bug_when>2012-02-13 18:43:53 -0800</bug_when>
    <thetext>As well as:
RenderBlock* RenderBlock::createAnonymousBlock(bool isFlexibleBox) const
{
    RefPtr&lt;RenderStyle&gt; newStyle = RenderStyle::createAnonymousStyle(style());

    RenderBlock* newBox = 0;
    if (isFlexibleBox) {
        newStyle-&gt;setDisplay(BOX);
        newBox = new (renderArena()) RenderDeprecatedFlexibleBox(document() /* anonymous box */);
    } else {
        newStyle-&gt;setDisplay(BLOCK);
        newBox = new (renderArena()) RenderBlock(document() /* anonymous box */);
    }

    newBox-&gt;setStyle(newStyle.release());
    return newBox;
}</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>555851</commentid>
    <comment_count>2</comment_count>
    <who name="Ojan Vafai">ojan</who>
    <bug_when>2012-02-13 18:45:32 -0800</bug_when>
    <thetext>And to round out the trio, RenderObject.h:
    bool isAnonymousBlock() const
    {
        // This function is kept in sync with anonymous block creation conditions in
        // RenderBlock::createAnonymousBlock(). This includes creating an anonymous
        // RenderBlock having a BLOCK or BOX display. Other classes such as RenderTextFragment
        // are not RenderBlocks and will return false. See https://bugs.webkit.org/show_bug.cgi?id=56709. 
        return isAnonymous() &amp;&amp; (style()-&gt;display() == BLOCK || style()-&gt;display() == BOX) &amp;&amp; style()-&gt;styleType() == NOPSEUDO &amp;&amp; isRenderBlock() &amp;&amp; !isListMarker()
#if ENABLE(FULLSCREEN_API)
            &amp;&amp; !isRenderFullScreen()
            &amp;&amp; !isRenderFullScreenPlaceholder()
#endif
            ;
    }</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>557734</commentid>
    <comment_count>3</comment_count>
    <who name="Ojan Vafai">ojan</who>
    <bug_when>2012-02-15 16:47:04 -0800</bug_when>
    <thetext>We need createAnonymousBlock to create a RenderFlexibleBox when splitting flexboxes. This will get new flexboxes to match the old ones. Old flexboxes are all sorts of buggy in multi-column though.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>