<?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>13440</bug_id>
          
          <creation_ts>2007-04-21 17:21:57 -0700</creation_ts>
          <short_desc>minmax width &quot;optimization&quot; is completely bogus.</short_desc>
          <delta_ts>2007-04-25 15:24:56 -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>Layout and Rendering</component>
          <version>523.x (Safari 3)</version>
          <rep_platform>Mac</rep_platform>
          <op_sys>OS X 10.4</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</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>13431</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Dave Hyatt">hyatt</reporter>
          <assigned_to name="Dave Hyatt">hyatt</assigned_to>
          
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>13369</commentid>
    <comment_count>0</comment_count>
    <who name="Dave Hyatt">hyatt</who>
    <bug_when>2007-04-21 17:21:57 -0700</bug_when>
    <thetext>recalcMinMaxWidth contains an optimization where it attempts to avoid doing a recalc if a block child&apos;s minwidth and maxwidth stay the same.  This is a bogus optimization, since a child can have any number of properties change on it (such as float or clear or overflow) that will affect the parent&apos;s min max width computations</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>13370</commentid>
    <comment_count>1</comment_count>
      <attachid>14128</attachid>
    <who name="Dave Hyatt">hyatt</who>
    <bug_when>2007-04-21 17:23:15 -0700</bug_when>
    <thetext>Created attachment 14128
Test case showing the problem

Here is a test case illustrating the issue.  Maxwidth is computed for a container with two floats inside it.  If you then dynamically unfloat one of the children, its minwidth/maxwidth don&apos;t change.  Therefore the parent does not bother to recomputed its maxwidth, even though the new result would be different.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>13345</commentid>
    <comment_count>2</comment_count>
    <who name="Dave Hyatt">hyatt</who>
    <bug_when>2007-04-21 17:25:54 -0700</bug_when>
    <thetext>Relating this to 13431, since my rework of calcMinMaxWidth should fix this problem without adversely affecting performance.

</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>12438</commentid>
    <comment_count>3</comment_count>
    <who name="Dave Hyatt">hyatt</who>
    <bug_when>2007-04-25 15:24:56 -0700</bug_when>
    <thetext>Fixed by lazy minmaxwidth patch.  I landed this test case in r21100.

</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="0"
              isprivate="0"
          >
            <attachid>14128</attachid>
            <date>2007-04-21 17:23:15 -0700</date>
            <delta_ts>2007-04-21 17:23:15 -0700</delta_ts>
            <desc>Test case showing the problem</desc>
            <filename>minmax.html</filename>
            <type>text/html</type>
            <size>410</size>
            <attacher name="Dave Hyatt">hyatt</attacher>
            
              <data encoding="base64">PGhlYWQ+CjxzdHlsZT4KI2NvbnRhaW5lciB7IGJvcmRlcjoycHggc29saWQgYmx1ZTsgfQojY29u
dGFpbmVyOmhvdmVyIHsgYm9yZGVyOjVweCBzb2xpZCBsaW1lOyB9CiNvbmUgeyBib3JkZXI6MnB4
IHNvbGlkIG9yYW5nZSB9Cjwvc3R5bGU+CjwvaGVhZD4KPGJvZHk+CjxkaXYgaWQ9ImNvbnRhaW5l
ciIgc3R5bGU9InBvc2l0aW9uOmFic29sdXRlOyI+CjxkaXYgaWQ9Im9uZSIgc3R5bGU9ImZsb2F0
OmxlZnQiPk9uZTwvZGl2PjxkaXYgc3R5bGU9ImZsb2F0OmxlZnQ7Ij5Ud288L2Rpdj4KPC9kaXY+
Cgo8cCBzdHlsZT0icGFkZGluZy10b3A6NTBweCI+CjxpbnB1dCB0eXBlPWJ1dHRvbiB2YWx1ZT0i
VW5mbG9hdCIgb25jbGljaz0iZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoJ29uZScpLnN0eWxlLmNz
c0Zsb2F0PScnIj4=
</data>

          </attachment>
      

    </bug>

</bugzilla>