https://bugs.webkit.org/show_bug.cgi?id=91000
REGRESSION (r122244): Overflow elements don't shrink as much as they should.

Reviewed by Simon Fraser.

This is a fix for a a regression from https://bugs.webkit.org/show_bug.cgi?id=90646.

I incorrectly analyzed the issue with Robert Hogan's negative margin patch and fooled myself into putting back
in an incorrect minimum width check from long ago.
        
What should have happened in the test case I patched is that the overflow element should shrink to 0. The issue 
with improving the logical top estimate in the previous patch is it made the clear delta become 0. This in turn
exposed a bug in our clearing algorithm with Robert's changes where you could need a relayout even if you didn't
actually move. This issue only occurs because the floats list is getting changed mid-layout because of negative margins.

The patch changes getClearDelta to call setChildNeedsLayout(true) on children whose widths change even when their
positions do not. In effect this dynamic addition of new floats after you have done a layout on the child already means
that you can need to lay out again despite not actually having to move.
        
To handle this, the code that does the relayout is now called if the child needs a relayout. This is done even if
the logical top estimate matches the final position.
        
No new tests required, since the test in fast/block/float is now correctly covering the issue.

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::layoutBlockChild):
(WebCore::RenderBlock::getClearDelta):
* rendering/RenderBox.cpp:
(WebCore::RenderBox::shrinkLogicalWidthToAvoidFloats):



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122489 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Unreviewed gardening. Re-baseline expected text for fast/multicol/table-vertical-align.html

* platform/chromium-linux-x86/fast/multicol/table-vertical-align-expected.txt: Copied from LayoutTests/platform/chromium-win/fast/multicol/table-vertical-align-expected.txt.
* platform/chromium-linux/fast/multicol/table-vertical-align-expected.txt: Copied from LayoutTests/platform/chromium-win/fast/multicol/table-vertical-align-expected.txt.
* platform/chromium-mac-snowleopard/fast/multicol/table-vertical-align-expected.txt: Added.
* platform/chromium-win-xp/fast/multicol/table-vertical-align-expected.txt: Copied from LayoutTests/platform/chromium-win/fast/multicol/table-vertical-align-expected.txt.
* platform/chromium-win/fast/multicol/table-vertical-align-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122490 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Document ListHashSet iteration guarantees
https://bugs.webkit.org/show_bug.cgi?id=91106

Reviewed by Eric Seidel.

* wtf/ListHashSet.h:
(WTF): Expand class comment to document this.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122491 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/platform/google-chrome-linux32 and google-chrome-linux64 are empty and should be removed
https://bugs.webkit.org/show_bug.cgi?id=91114

Reviewed by Tony Chang.

These directories are empty and haven't been touched in over a year.
We should remove them.

* platform/google-chrome-linux32: Removed.
* platform/google-chrome-linux32/README: Removed.
* platform/google-chrome-linux64: Removed.
* platform/google-chrome-linux64/README: Removed.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122492 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Unreviewed gardening. Layout Test storage/indexeddb/constants.html is flaky.
https://bugs.webkit.org/show_bug.cgi?id=91133

Has started to crash occassionally on WebKitWin, cause unknown.

* platform/chromium/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122493 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Threadsafety issues in WebScriptObject
https://bugs.webkit.org/show_bug.cgi?id=90849

Reviewed by Filip Pizlo & Oliver Hunt.

Updated fix for this bug. Taking the JSC API lock from WebScriptObject::release
may not be safe; better to just guard the JSWrapperCache with its own spinlock.

* bindings/objc/WebScriptObject.mm:
(WebCore::getJSWrapper):
    - Added spinlock; also retain/autorelease the returned wrapper - it is unsafe
      to wait for the caller to do so, due to a race condition vs release removing
      the wrapper from the map.
(WebCore::addJSWrapper):
    - Take the spinlock guarding the cache.
(WebCore::removeJSWrapper):
    - Take the spinlock guarding the cache.
(WebCore::removeJSWrapperIfRetainCountOne):
    - Take the spinlock guarding the cache, remove the wrapper if retainCount is one.
(WebCore::createJSWrapper):
    - Remove the API lock; this method no longer needs to retain/autorelease (this is
      done by getJSWrapper).
(-[WebScriptObject _setImp:originRootObject:rootObject:]):
    - Remove the API lock.
(-[WebScriptObject release]):
    - Remove the API lock, retainCount check moved into removeJSWrapperIfRetainCountOne.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122494 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Mac] input-in-table-cell-no-value.html fails due to INPUT_TYPE_DATE being disabled.

* platform/mac/TestExpectations: Mark input-in-table-cell-no-value.html
as expected to fail.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122495 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium][Mac] r122400 broke 10.6 build
https://bugs.webkit.org/show_bug.cgi?id=91103

Patch by Robert Sesek <rsesek@chromium.org> on 2012-07-12
Reviewed by Tony Chang.

Use the right availability macros for forward-declaring methods and
defining constants.

* src/mac/WebInputEventFactory.mm:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122496 268f45cc-cd09-0410-ab3c-d52691b4dbfc
nrwt: reimplement manager_worker_broker in a much simpler form
https://bugs.webkit.org/show_bug.cgi?id=90513

Reviewed by Ojan Vafai.

This is a wholesale replacement of the MessagePool() implementation
and the other classes in manager_worker_broker.py. All of the
BrokerConnection*, Broker*, etc. classes are gone, and there are now
just a MessagePool class and a _Worker class. Happiness ensues.

I'm removing manager_worker_broker_unittest.py as well; we get
nearly complete coverage from the integration tests, and will
get more coverage when test-webkitpy moves to use this as well,
so having unit tests seems like unnecessary overhead. (running
coverage numbers with test-webkitpy shows that pretty much the only
uncovered lines are lines that are only run in the child processes,
which coverage doesn't handle at the moment).

* Scripts/webkitpy/layout_tests/controllers/manager_worker_broker.py:
(_MessagePool.__init__):
(_MessagePool.run):
(_MessagePool._start_workers):
(_MessagePool):
(_MessagePool.wait):
(_MessagePool._close):
(_MessagePool._handle_done):
(_MessagePool._can_pickle):
(_MessagePool._loop):
(WorkerException):
(_Message.__init__):
(_Message.__repr__):
(_Worker):
(_Worker.__init__):
(_Worker.terminate):
(_Worker._close):
(_Worker.run):
(_Worker.post):
(_Worker.yield_to_caller):
(_Worker._post):
(_Worker._raise):
(_Worker._set_up_logging):
(_WorkerLogHandler.__init__):
(_WorkerLogHandler.emit):
* Scripts/webkitpy/layout_tests/controllers/manager_worker_broker_unittest.py: Removed.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122497 268f45cc-cd09-0410-ab3c-d52691b4dbfc
invalidateNodeListsCacheAfterAttributeChanged should dynamically figure out which attribute needs invalidation
https://bugs.webkit.org/show_bug.cgi?id=91046

Reviewed by Anders Carlsson.

Added an array of counters (m_nodeListCounts) for each set of attributes (NodeListInvalidationType) node lists care about
to Document, and made DynamicSubtreeNodeList's constructor and destructor increment and decrement these counters via
registerDynamicSubtreeNodeList and unregisterDynamicSubtreeNodeList respectively. shouldInvalidateDynamicSubtreeNodeList,
which is called by invalidateNodeListsCacheAfterAttributeChanged, then use these counters to determine whether a given
attribute change should result in node list invalidations.

Also removed m_numNodeListCaches from TreeScope because this counter has now become redundant with m_nodeListCounts.

* dom/ChildNodeList.cpp:
(WebCore::ChildNodeList::ChildNodeList): Do not invalidate on attribute changes.
* dom/ClassNodeList.cpp:
(WebCore::ClassNodeList::ClassNodeList): Invalidate on class attribute changes.
* dom/Document.cpp:
(WebCore::Document::Document): Initialize m_nodeListCounts.
(WebCore::Document::~Document): Add assertions to make sure m_listsInvalidatedAtDocument, m_nodeListCounts, and
m_collections are all empty.
(WebCore::Document::registerDynamicSubtreeNodeList): This function is now called for all DynamicSubtreeNodeLists supposed
to just ones rooted at the document in order to increment the counter for each invalidation type.
(WebCore::Document::unregisterDynamicSubtreeNodeList): Ditto.
(WebCore::shouldInvalidateDynamicSubtreeNodeListForType): Checks the attribute name against NodeListInvalidationType.
(WebCore::Document::shouldInvalidateDynamicSubtreeNodeList): Returns true if the given attribute name matches the invalidation
type of the existing DynamicSubtreeNodeLists in the document. If the attribute name is not given (used when children change),
then it checks for the existence of any DynamicSubtreeNodeLists. Conceptually, this function can be written as a list of
"if" statements that checks values in m_nodeListCounts and the attribute name. We use "for" loop and switch statement instead
to share logic and detect future addition of values to NodeListInvalidationType.
* dom/Document.h:
(Document): Moved RootType and InvalidationType from DynamicNodeListCacheBase and renamed them to NodeListRootType and
NodeListInvalidationType respectively in order to reduce the possibility of future name collisions. Also the invalidation type
now contains 6 values instead of 2.
* dom/DynamicNodeList.cpp:
(WebCore):
* dom/DynamicNodeList.h:
(WebCore::DynamicNodeListCacheBase::DynamicNodeListCacheBase): 
(WebCore::DynamicNodeListCacheBase::shouldInvalidateOnAttributeChange):
(WebCore::DynamicNodeListCacheBase::rootType): Added.
(WebCore::DynamicNodeListCacheBase::invalidationType): Added.
(DynamicNodeListCacheBase): Uses 3 bits to store invalidation type now that the number of values have increased from 2 to 6.
(WebCore::DynamicNodeList::DynamicNodeList):
(WebCore::DynamicSubtreeNodeList::~DynamicSubtreeNodeList): Call unregisterDynamicSubtreeNodeList.
(WebCore::DynamicSubtreeNodeList::DynamicSubtreeNodeList): Call registerDynamicSubtreeNodeList.
* dom/MicroDataItemList.cpp:
(WebCore::MicroDataItemList::MicroDataItemList): Invalidate on itemscope, itemprop, and itemtype content attribute changes.
* dom/NameNodeList.cpp:
(WebCore::NameNodeList::NameNodeList): Invalidate on name attribute changes.
* dom/Node.cpp:
(WebCore::Node::clearRareData):
(WebCore::Node::invalidateNodeListsCacheAfterAttributeChanged): Replaced the hard coded check list of attributes, by a call
to shouldInvalidateDynamicSubtreeNodeList.
(WebCore::Node::invalidateNodeListsCacheAfterChildrenChanged): Calls shouldInvalidateDynamicSubtreeNodeList.
(WebCore::Node::getElementsByTagName):
(WebCore::Node::getElementsByTagNameNS):
(WebCore::Node::getElementsByName):
(WebCore::Node::getElementsByClassName):
(WebCore::Node::radioNodeList):
(WebCore::NodeRareData::createNodeLists):
* dom/NodeRareData.h:
(WebCore::NodeListsNodeData::adoptTreeScope): Unregister and register node lists in m_tagNodeListCacheNS since all node lists
need to be accounted in m_nodeListCounts.
(WebCore::NodeRareData::ensureNodeLists):
(NodeRareData):
* dom/TagNodeList.cpp:
(WebCore::TagNodeList::TagNodeList): Do not invalidate on any attribute changes.
* dom/TreeScope.cpp:
(WebCore::TreeScope::TreeScope): No longer initializes m_numNodeListCaches since it has been removed.
* dom/TreeScope.h:
(TreeScope): Removed m_numNodeListCaches.
* dom/TreeScopeAdopter.cpp:
(WebCore::TreeScopeAdopter::moveTreeToNewScope):
* html/HTMLCollection.h:
(WebCore::HTMLCollectionCacheBase::HTMLCollectionCacheBase): Just pass in DoNotInvalidateOnAttributeChanges for now since
it's never used in HTMLCollections.
* html/LabelableElement.cpp:
(WebCore::LabelableElement::labels):
* html/LabelsNodeList.cpp:
(WebCore::LabelsNodeList::LabelsNodeList): Invalidate on for content attribute changes.
(WebCore::LabelsNodeList::~LabelsNodeList):
* html/RadioNodeList.cpp:
(WebCore::RadioNodeList::RadioNodeList): Invalidate on id, name, and for content attribute changes.
(WebCore::RadioNodeList::~RadioNodeList):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122498 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2012-07-12  Dirk Pranke  <dpranke@chromium.org>

        Remove chromium-mac-leopard baselines.

        Rubber-stamped by Tony Chang.

        Chromium no longer actively supports the Leopard (10.5) version
        of Mac OS and doesn't have any bots running it, so we don't need
        the baselines any more.




git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122499 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] Add missing Network Information API integration to WebContext and WebPage
https://bugs.webkit.org/show_bug.cgi?id=90781

Patch by Christophe Dumez <christophe.dumez@intel.com> on 2012-07-12
Reviewed by Anders Carlsson.

Integrate Network Information API to WebPage, WebContext and
properly route messages to the WebNetworkInfoManagerProxy.
Without this, the Network Information tests are crashing for
WebKit2.

* UIProcess/WebContext.cpp:
(WebKit::WebContext::WebContext):
(WebKit::WebContext::~WebContext):
(WebKit::WebContext::disconnectProcess):
(WebKit::WebContext::didReceiveMessage):
(WebKit::WebContext::didReceiveSyncMessage):
* UIProcess/WebContext.h:
(WebKit):
(WebContext):
(WebKit::WebContext::networkInfoManagerProxy):
* UIProcess/WebNetworkInfoManagerProxy.cpp:
(WebKit::WebNetworkInfoManagerProxy::didReceiveSyncMessage):
(WebKit):
* UIProcess/WebNetworkInfoManagerProxy.h:
(WebNetworkInfoManagerProxy):
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::didReceiveMessage):
(WebKit::WebProcessProxy::didReceiveSyncMessage):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122500 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Percentage width replaced element in zero percent/fixed width container block incorrectly rendered.
https://bugs.webkit.org/show_bug.cgi?id=9493

Patch by Pravin D <pravind.2k4@gmail.com> on 2012-07-12
Reviewed by Andy Estes.

Source/WebCore:

When the width of the container is zero percent/fixed value then the width of the replaced element must also be zero.

Test: fast/css/percent-width-img-inside-zero-percent-and-fixed-container.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeReplacedLogicalWidthUsing):
  When the containing block's available width is zero there can be two cases.
  The containing block is floated/positioned in which case the width of the replaced child element must be its instrinsic width.
  On the other hand if the width of the container is specified to be either zero percent or fixed value then the width of the
  replaced elment must be zero.

LayoutTests:

* fast/css/percent-width-img-inside-zero-percent-and-fixed-container-expected.html: Added.
* fast/css/percent-width-img-inside-zero-percent-and-fixed-container.html: Added.
* fast/css/resources/red-box.png: Added.
  Image resource file for the test case.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122501 268f45cc-cd09-0410-ab3c-d52691b4dbfc
ASSERT(genChild->isListMarker() || genChild->style()->styleType() == FIRST_LETTER) triggered on flex-box content
https://bugs.webkit.org/show_bug.cgi?id=91003

Reviewed by Abhishek Arya.

Source/WebCore:

Tests: fast/flexbox/assert-generated-deprecated-flexbox.html
       fast/flexbox/assert-generated-new-flexbox.html

The issue was that findBeforeAfterParent didn't return the right parent for the flex-box case. This would
make us update the wrong children (and not propagate the style updates properly).

* rendering/RenderObjectChildList.cpp:
(WebCore::findBeforeAfterParent):
Added a check for flex boxes (both deprecated and new).

LayoutTests:

* fast/flexbox/assert-generated-deprecated-flexbox-expected.txt: Added.
* fast/flexbox/assert-generated-deprecated-flexbox.html: Added.
* fast/flexbox/assert-generated-new-flexbox-expected.txt: Added.
* fast/flexbox/assert-generated-new-flexbox.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122502 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Let XCode have its own way.

* WebCore.xcodeproj/project.pbxproj:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122503 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed.  Delete two empty directories.

* platform/google-chrome-linux32: Removed.
* platform/google-chrome-linux64: Removed.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122504 268f45cc-cd09-0410-ab3c-d52691b4dbfc
nrwt crashes saving the output for a platform-specific expected test reference
https://bugs.webkit.org/show_bug.cgi?id=90872

Reviewed by Ojan Vafai.

Tools:

The expected output for a test is copied alongside the test
itself in the layout-test-results directory; in other words, for
foo/bar-expected.txt sits alongside foo/bar.html even if we're
actually using platform/mac/foo/bar-expected.txt.

Unless the test is a reftest, in which case we would copy the
output to platform/mac/foo/bar-expected.html and set a
'ref_file' parameter in results.json to indicate the path. This
can be useful in the cases where we have multiple references for
a single test or when multiple tests share the same reference.

We found a bug where we weren't creating platform/mac/foo under
the results directory, and so this wasn't actually working.
However, treating reftests differently seems like a bad thing,
so we should probably be consistent. This change puts the
-expected.html next to the test, and reworks test_result_writer
so that we create directories uniformly and consistently.

Note that we weren't catching this problem in unit tests because
the MockFileSystem creates a directory automatically if it
doesn't exist; this was done intentionally for convenience, but
is really a bug and should be fixed; see https://bugs.webkit.org/show_bug.cgi?id=91028.

I have not added additional tests here since fixing that bug
should be sufficient.

* Scripts/webkitpy/layout_tests/controllers/manager.py:
(interpret_test_failures):
* Scripts/webkitpy/layout_tests/controllers/manager_unittest.py:
(ResultSummaryTest.test_interpret_test_failures):
* Scripts/webkitpy/layout_tests/controllers/test_result_writer.py:
(write_test_result):
(TestResultWriter._write_binary_file):
(TestResultWriter):
(TestResultWriter._write_text_file):
(TestResultWriter.write_output_files):
(TestResultWriter.write_stderr):
(TestResultWriter.write_crash_log):
(TestResultWriter.create_text_diff_and_write_result):
(TestResultWriter.write_image_diff_files):
(write_reftest):
* Scripts/webkitpy/layout_tests/run_webkit_tests_integrationtest.py:
(EndToEndTest.test_reftest_with_two_notrefs):

LayoutTests:

Remove tests for the 'ref_file' parameter in results.json
entries.

* fast/harness/resources/results-test.js:
* fast/harness/results.html:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122505 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Use CCTexture/TextureAllocator and remove TextureManager
https://bugs.webkit.org/show_bug.cgi?id=91001

Patch by Eric Penner <epenner@google.com> on 2012-07-12
Reviewed by Adrienne Walker.

Source/WebCore:

Use CCTexture to clean up CCPrioritizedTexture::Backing.
Add TextureAllocator.h and remove remainder of TextureManager.h/cpp.
Minor move/refactoring of link/unlink in CCPrioritizedTexture.
Remove double initialization of the default memory limit.

Covered by existing tests (refactoring).

* WebCore.gypi:
* platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.cpp:
* platform/graphics/chromium/BitmapCanvasLayerTextureUpdater.h:
(WebCore):
* platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp:
* platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h:
(WebCore):
* platform/graphics/chromium/ImageLayerChromium.cpp:
* platform/graphics/chromium/LayerRendererChromium.cpp:
(WebCore::LayerRendererChromium::initialize):
* platform/graphics/chromium/ManagedTexture.cpp: Removed.
* platform/graphics/chromium/ManagedTexture.h: Removed.
* platform/graphics/chromium/RenderSurfaceChromium.h:
(WebCore):
* platform/graphics/chromium/TextureAllocator.h: Copied from Source/WebCore/platform/graphics/chromium/cc/CCPriorityCalculator.h.
(WebCore):
(TextureAllocator):
(WebCore::TextureAllocator::~TextureAllocator):
* platform/graphics/chromium/TextureManager.cpp: Removed.
* platform/graphics/chromium/TextureManager.h: Removed.
* platform/graphics/chromium/TiledLayerChromium.cpp:
* platform/graphics/chromium/TrackingTextureAllocator.cpp:
(WebCore::TrackingTextureAllocator::createTexture):
(WebCore::TrackingTextureAllocator::deleteTexture):
* platform/graphics/chromium/TrackingTextureAllocator.h:
* platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
* platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
(WebCore::CCLayerTreeHost::prioritizeTextures):
* platform/graphics/chromium/cc/CCLayerTreeHost.h:
(WebCore):
* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::CCLayerTreeHostImpl):
* platform/graphics/chromium/cc/CCPrioritizedTexture.cpp:
(WebCore::CCPrioritizedTexture::CCPrioritizedTexture):
(WebCore::CCPrioritizedTexture::setDimensions):
(WebCore::CCPrioritizedTexture::textureId):
(WebCore::CCPrioritizedTexture::bindTexture):
(WebCore::CCPrioritizedTexture::framebufferTexture2D):
(WebCore::CCPrioritizedTexture::link):
(WebCore):
(WebCore::CCPrioritizedTexture::unlink):
* platform/graphics/chromium/cc/CCPrioritizedTexture.h:
(WebCore):
(WebCore::CCPrioritizedTexture::bytes):
(CCPrioritizedTexture):
(WebCore::CCPrioritizedTexture::haveBackingTexture):
(WebCore::CCPrioritizedTexture::Backing::Backing):
(WebCore::CCPrioritizedTexture::Backing::~Backing):
(WebCore::CCPrioritizedTexture::Backing::owner):
(Backing):
(WebCore::CCPrioritizedTexture::backing):
* platform/graphics/chromium/cc/CCPrioritizedTextureManager.cpp:
(WebCore::CCPrioritizedTextureManager::prioritizeTextures):
(WebCore::CCPrioritizedTextureManager::requestLate):
(WebCore::CCPrioritizedTextureManager::acquireBackingTextureIfNeeded):
(WebCore::CCPrioritizedTextureManager::reduceMemory):
(WebCore::CCPrioritizedTextureManager::clearAllMemory):
(WebCore::CCPrioritizedTextureManager::registerTexture):
(WebCore::CCPrioritizedTextureManager::returnBackingTexture):
(WebCore::CCPrioritizedTextureManager::createBacking):
(WebCore::CCPrioritizedTextureManager::destroyBacking):
(WebCore::CCPrioritizedTextureManager::assertInvariants):
* platform/graphics/chromium/cc/CCPrioritizedTextureManager.h:
(CCPrioritizedTextureManager):
(WebCore::CCPrioritizedTextureManager::defaultMemoryAllocationLimit):
(WebCore::CCPrioritizedTextureManager::compareBackings):
* platform/graphics/chromium/cc/CCPriorityCalculator.h:
* platform/graphics/chromium/cc/CCScopedTexture.cpp:
* platform/graphics/chromium/cc/CCScopedTexture.h:
* platform/graphics/chromium/cc/CCTexture.h:
(WebCore::CCTexture::CCTexture):
* platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
(WebCore):
* platform/graphics/chromium/cc/CCVideoLayerImpl.cpp:

Source/WebKit/chromium:

Deleting old texture manager tests.

* WebKit.gypi:
* tests/CCLayerTreeHostImplTest.cpp:
* tests/CCPrioritizedTextureTest.cpp:
(WTF::CCPrioritizedTextureTest::texturesMemorySize):
* tests/CCThreadedTest.cpp:
* tests/CCTiledLayerTestCommon.h:
* tests/Canvas2DLayerBridgeTest.cpp:
* tests/TextureManagerTest.cpp: Removed.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122506 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Qt] Increase the drawing performance by merging dirty rects.
https://bugs.webkit.org/show_bug.cgi?id=91075

Patch by Huang Dongsung <luxtella@company100.net> on 2012-07-12
Reviewed by Noam Rosenthal.

QWebFramePrivate calls FrameView::paintContents as many as the number of dirty
rects, so it causes too many redundant render tree traversals.
I changed it to merge dirty rects and call FrameView::paintContents only once.
The algorithm to merge rects is copied from GTK.

When parallel image decoders are in use, each image is independently repainted
when decoding is finished. This creates a lot by repaint requests. So by merging
these repaint requests, I could improve rendering performance.

For example, I tested parallel image decoders on the locally mirrored Pinterest site.
QWebFramePrivate called FrameView::paintContents 165 times after parallel image
decoders decoded all the images. It took about 120ms on my six-core Intel Xeon machine.
This patch decreases painting time from 120ms to 30ms.

* Api/qwebframe.cpp:
(coalesceRectsIfPossible):
(QWebFramePrivate::renderRelativeCoords):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122507 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Implied minimum size of flex items is min-content
https://bugs.webkit.org/show_bug.cgi?id=87546

Reviewed by Tony Chang.

Source/WebCore:

http://dev.w3.org/csswg/css3-flexbox/#min-size-auto
In the main axis direction, min-size of auto means min-content.

Test: css3/flexbox/flex-item-min-size.html

* rendering/RenderBox.cpp:
(WebCore::RenderBox::computeLogicalWidthInRegionUsing):
(WebCore::RenderBox::computeContentLogicalHeightUsing):
(WebCore::RenderBox::computeReplacedLogicalWidthUsing):
(WebCore::RenderBox::computeReplacedLogicalHeightUsing):
(WebCore::RenderBox::computePositionedLogicalWidthUsing):
(WebCore::RenderBox::computePositionedLogicalHeightUsing):
It turned out that these FIXMEs are all unnecessary with the changes to RenderFlexibleBox.

* rendering/RenderFlexibleBox.cpp:
(WebCore::RenderFlexibleBox::computeMainAxisPreferredSizes):
(WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax):

LayoutTests:

Mostly just set min-height/min-width:0 as appropriate to keep the tests testing
what the used to be testing. I made sure that each rendering was correct before
making the changes. In a couple cases, I changed expectations where I thought
the test was still testing was it was intending to test.

* css3/flexbox/child-overflow.html:
* css3/flexbox/columns-auto-size.html:
* css3/flexbox/cross-axis-scrollbar.html:
* css3/flexbox/flex-item-min-size-expected.txt: Added.
* css3/flexbox/flex-item-min-size.html: Added.
* css3/flexbox/flexitem.html:
* css3/flexbox/line-wrapping.html:
* css3/flexbox/perpendicular-writing-modes-inside-flex-item.html:
* css3/flexbox/repaint-rtl-column.html:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@122508 268f45cc-cd09-0410-ab3c-d52691b4dbfc