ShadowRoot insertion point change aborts css transition
https://bugs.webkit.org/show_bug.cgi?id=93755

Patch by Takashi Sakamoto <tasak@google.com> on 2012-08-27
Reviewed by Hajime Morita.

Source/WebCore:

ElementShadow always detaches shadow hosts when distribution is
changed, i.e. select attribute's value is changed. However it clears
the style of the shadow host. So when distribution is changed,
no css transition can be started at the same time. To avoid this
problem, invalidateDistribution, i.e. a method for invalidating current
distribution, should not make shadow host reattach. Instead, it should
make distribute nodes reattached and set needsRecalcStyle flag of
shadow host.

Test: transitions/transition-on-shadow-host-with-distributed-node.html

* dom/ElementShadow.cpp:
(WebCore::ElementShadow::addShadowRoot):
To support replaced elements, i.e. IMG, and so on, shadow host's
renderer must be updated when author shadow roots are addded.
So invoke shadow host's reattach instead of shadowRoot's attach.
(WebCore::ElementShadow::invalidateDistribution):
Remove shadow host's lazy reattach (detach and lazyAttach). Instead, do
distributed nodes' lazy reattach and set shadow host's needsRecalcStyle
flag.
* dom/Node.h:
(WebCore::Node::lazyReattach):
Newly added. The method works like Node::reattach, but use
lazyAttach instead of attach.
(WebCore):

LayoutTests:

* fast/dom/shadow/transition-on-shadow-host-with-distributed-node-expected.txt: Added.
* fast/dom/shadow/transition-on-shadow-host-with-distributed-node.html: Added.
* platform/chromium-linux/fast/html/details-nested-2-expected.txt: Added, because of changing the code about adding shadow root.
* platform/chromium-linux/fast/multicol/span/clone-anonymous-block-non-inline-child-crash-expected.txt: Added.
* platform/mac/fast/html/details-nested-2-expected.txt: Rebased, because of changing the code about adding shadow root.
* platform/mac/fast/multicol/span/clone-anonymous-block-non-inline-child-crash-expected.txt: Rebased.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126789 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Have RenderSurface create and add its own generated RenderPass
https://bugs.webkit.org/show_bug.cgi?id=94957

Reviewed by Adrienne Walker.

Source/WebCore:

Have CCRenderSurface create and add its RenderPass to the appropriate
data structures. Previously CCLayerTreeHostImpl had this responsibility
but this limits us to a single RenderPass per RenderSurface. In ubercomp
we have layers that generate many RenderPasses that all contribute to a
single RenderSurface. This target RenderSurface can create all the needed
RenderPasses in the correct order for itself when asked to now.

We invent CCRenderPassSink and make FrameData implement it, so that the
RenderSurface does not need to know the details of how the RenderPasses
it generates will be stored.

Test: CCRenderSurfaceTest.sanityCheckSurfaceCreatesCorrectRenderPass

* WebCore.gypi:
* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::FrameData::appendRenderPass):
(WebCore):
(WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
* platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
(FrameData):
* platform/graphics/chromium/cc/CCRenderPassSink.h: Added.
(WebCore):
(CCRenderPassSink):
* platform/graphics/chromium/cc/CCRenderSurface.cpp:
(WebCore::CCRenderSurface::appendRenderPasses):
(WebCore):
* platform/graphics/chromium/cc/CCRenderSurface.h:
(WebCore):
(CCRenderSurface):

Source/WebKit/chromium:

Test that a RenderSurface generates the RenderPass that we expect.

* tests/CCRenderSurfaceTest.cpp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126790 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Prevent scrollbar thumb size from changing during compositor zoom
https://bugs.webkit.org/show_bug.cgi?id=94859

Reviewed by James Robinson.

Source/WebCore:

During a pinch zoom, the total size of a scrollable area will change,
causing the thumb to become a different size. This will cause the
thumb texture (painted at a specific size) to stretch. To fix this,
add a new CCScrollbarGeometryFixedThumb class which behaves just like
a normal WebScrollbarThemeGeometry class, but constrains the thumb to
be a fixed size.

* WebCore.gypi:
* platform/graphics/chromium/ScrollbarLayerChromium.cpp:
(WebCore::ScrollbarLayerChromium::pushPropertiesTo):
* platform/graphics/chromium/cc/CCScrollbarGeometryFixedThumb.cpp: Added.
(WebCore):
(WebCore::CCScrollbarGeometryFixedThumb::create):
(WebCore::CCScrollbarGeometryFixedThumb::~CCScrollbarGeometryFixedThumb):
(WebCore::CCScrollbarGeometryFixedThumb::update):
(WebCore::CCScrollbarGeometryFixedThumb::clone):
(WebCore::CCScrollbarGeometryFixedThumb::thumbLength):
(WebCore::CCScrollbarGeometryFixedThumb::thumbPosition):
(WebCore::CCScrollbarGeometryFixedThumb::splitTrack):
(WebCore::CCScrollbarGeometryFixedThumb::CCScrollbarGeometryFixedThumb):
* platform/graphics/chromium/cc/CCScrollbarGeometryFixedThumb.h: Added.
(WebCore):
(CCScrollbarGeometryFixedThumb):
* platform/graphics/chromium/cc/CCScrollbarGeometryStub.cpp: Added.
(WebCore):
(WebCore::CCScrollbarGeometryStub::CCScrollbarGeometryStub):
(WebCore::CCScrollbarGeometryStub::~CCScrollbarGeometryStub):
(WebCore::CCScrollbarGeometryStub::clone):
(WebCore::CCScrollbarGeometryStub::thumbPosition):
(WebCore::CCScrollbarGeometryStub::thumbLength):
(WebCore::CCScrollbarGeometryStub::trackPosition):
(WebCore::CCScrollbarGeometryStub::trackLength):
(WebCore::CCScrollbarGeometryStub::hasButtons):
(WebCore::CCScrollbarGeometryStub::hasThumb):
(WebCore::CCScrollbarGeometryStub::trackRect):
(WebCore::CCScrollbarGeometryStub::thumbRect):
(WebCore::CCScrollbarGeometryStub::minimumThumbLength):
(WebCore::CCScrollbarGeometryStub::scrollbarThickness):
(WebCore::CCScrollbarGeometryStub::backButtonStartRect):
(WebCore::CCScrollbarGeometryStub::backButtonEndRect):
(WebCore::CCScrollbarGeometryStub::forwardButtonStartRect):
(WebCore::CCScrollbarGeometryStub::forwardButtonEndRect):
(WebCore::CCScrollbarGeometryStub::constrainTrackRectToTrackPieces):
(WebCore::CCScrollbarGeometryStub::splitTrack):
* platform/graphics/chromium/cc/CCScrollbarGeometryStub.h: Added.
(WebCore):
(CCScrollbarGeometryStub):
(WebCore::CCScrollbarGeometryStub::update):
* platform/graphics/chromium/cc/CCScrollbarLayerImpl.cpp:
(WebCore::CCScrollbarLayerImpl::setScrollbarGeometry):
(WebCore::CCScrollbarLayerImpl::setScrollbarData):
* platform/graphics/chromium/cc/CCScrollbarLayerImpl.h:
(WebCore::CCScrollbarLayerImpl::scrollbarGeometry):
(CCScrollbarLayerImpl):

Source/WebKit/chromium:

Update test.

* tests/CCLayerTreeHostImplTest.cpp:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126791 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[webkit-patch] Don't crash chrome-channels command when a previously unknown platform shows up.
https://bugs.webkit.org/show_bug.cgi?id=95104

Reviewed by Adam Barth.

Today I found out this command was broken by the new iOS platform showing up on omahaproxy. Now the webkit-patch chrome-channels command gracefully handles new, previously unknown platforms. Also, it prints iOS in the proper mixed case.

* Scripts/webkitpy/common/net/omahaproxy.py:
(OmahaProxy):
(OmahaProxy.get_revisions):
* Scripts/webkitpy/common/net/omahaproxy_unittest.py:
(OmahaProxyTest):
(OmahaProxyTest.test_get_revisions):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126792 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed rebaselining after r126683.

* platform/chromium/TestExpectations:
Removed 4 entries that were rebaselined.

* fast/block/float/avoidance-rtl-expected.txt: Replaced.
* fast/borders/border-radius-wide-border-01-expected.txt: Replaced.
* fast/borders/only-one-border-with-width-expected.txt: Replaced.
* fast/multicol/progression-reverse-expected.txt: Replaced.
Common baseline updates now that we always dump the first border.

* platform/efl/fast/block/float/avoidance-rtl-expected.txt: Removed.
* platform/efl/fast/borders/border-radius-wide-border-01-expected.txt: Removed.
* platform/efl/fast/borders/only-one-border-with-width-expected.txt: Removed.
* platform/efl/fast/multicol/progression-reverse-expected.txt: Removed.
* platform/gtk/fast/block/float/avoidance-rtl-expected.txt: Removed.
* platform/gtk/fast/borders/border-radius-wide-border-01-expected.txt: Removed.
* platform/gtk/fast/borders/only-one-border-with-width-expected.txt: Removed.
* platform/gtk/fast/multicol/progression-reverse-expected.txt: Removed.
* platform/mac-lion/fast/block/float/avoidance-rtl-expected.txt: Removed.
* platform/mac-lion/fast/borders: Removed.
* platform/mac-lion/fast/borders/border-radius-wide-border-01-expected.txt: Removed.
* platform/mac-lion/fast/borders/only-one-border-with-width-expected.txt: Removed.
* platform/mac-lion/fast/multicol/progression-reverse-expected.txt: Removed.
* platform/mac/fast/block/float/avoidance-rtl-expected.txt: Removed.
* platform/mac/fast/borders/border-radius-wide-border-01-expected.txt: Removed.
* platform/mac/fast/borders/only-one-border-with-width-expected.txt: Removed.
* platform/mac/fast/multicol/progression-reverse-expected.txt: Removed.
* platform/qt/fast/block/float/avoidance-rtl-expected.txt: Removed.
* platform/qt/fast/borders/border-radius-wide-border-01-expected.txt: Removed.
* platform/qt/fast/borders/only-one-border-with-width-expected.txt: Removed.
Removed those baselines now that they can be shared with the common one above.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126793 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Unreviewed, remove OVERRIDE from non-virtual function.
https://bugs.webkit.org/show_bug.cgi?id=94859

Unreviewed build fix.

* platform/graphics/chromium/cc/CCScrollbarGeometryFixedThumb.h:
(CCScrollbarGeometryFixedThumb):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126794 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Skia/Chromium] Remove use of deprecated Skia names
https://bugs.webkit.org/show_bug.cgi?id=95108

Patch by Brian Salomon <bsalomon@google.com> on 2012-08-27
Reviewed by Eric Seidel.

kSkia8888_PM_GrPixelConfig has been deprecated in favor of kSkia8888_GrPixelConfig.
SkGrTexturePixelRef has been deprecated in favor of SkGrPixelRef.

Covered by existing tests (image filter and canvas tests).

* platform/graphics/chromium/FrameBufferSkPictureCanvasLayerTextureUpdater.cpp:
(WebCore::createAcceleratedCanvas):
* platform/graphics/chromium/cc/CCRenderSurfaceFilters.cpp:
* platform/graphics/skia/ImageBufferSkia.cpp:
(WebCore::createAcceleratedCanvas):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126795 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[V8] initContextIfNeeded is overly specific
https://bugs.webkit.org/show_bug.cgi?id=95120

Reviewed by Eric Seidel.

This patch is part of a series to clean up V8DOMWindowShell.  This
patch renames initContextIfNeeded to initializeIfNeeded because callers
shouldn't need to worry about what V8DOMWindow needs to initialize.

* bindings/scripts/CodeGeneratorV8.pm:
(GenerateToV8Converters):
* bindings/scripts/test/V8/V8TestActiveDOMObject.cpp:
(WebCore::V8TestActiveDOMObject::wrapSlow):
* bindings/v8/ScriptController.cpp:
(WebCore::ScriptController::evaluateInIsolatedWorld):
(WebCore::ScriptController::mainWorldContext):
(WebCore::ScriptController::matchesCurrentContext):
* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::V8DOMWindowShell::initializeIfNeeded):
(WebCore::V8DOMWindowShell::updateDocument):
(WebCore::V8DOMWindowShell::namedItemAdded):
(WebCore::V8DOMWindowShell::namedItemRemoved):
* bindings/v8/V8DOMWindowShell.h:
(V8DOMWindowShell):
* bindings/v8/WorkerContextExecutionProxy.cpp:
(WebCore::WorkerContextExecutionProxy::initializeIfNeeded):
(WebCore::WorkerContextExecutionProxy::evaluate):
* bindings/v8/WorkerContextExecutionProxy.h:
(WorkerContextExecutionProxy):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@126796 268f45cc-cd09-0410-ab3c-d52691b4dbfc
The static functions in V8DOMWindowShell.cpp are poorly named
https://bugs.webkit.org/show_bug.cgi?id=95122

Reviewed by Eric Seidel.

This patch cleans up the naming of the static functions in
V8DOMWindowShell.cpp.

I've inlined handleFatalErrorInV8 into its one caller.

* bindings/v8/V8DOMWindowShell.cpp:
(WebCore::reportFatalError):
    - Removed V8 from the name becaues this entire file is about V8.
(WebCore::reportUncaughtException):
    - Ditto.
(WebCore::findFrame):
    - Remove the "get" prefix because it's a weak verb.
(WebCore::reportUnsafeJavaScriptAccess):
(WebCore::initializeV8IfNeeded):
(WebCore::checkDocumentWrapper):
    - Move this function up to the top of the file with the rest of the
      static functions.
(WebCore):


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