JSNPObject doesn't always protect its data when calling into plugin code
https://bugs.webkit.org/show_bug.cgi?id=95394

Reviewed by Brady Eidson.

We need to use NPRuntimeObjectMap::PluginProtector when calling into plugin code since 
there's no telling what the plugin will do, including destroying itself.

* WebProcess/Plugins/Netscape/JSNPObject.cpp:
(WebKit::JSNPObject::getOwnPropertySlot):
(WebKit::JSNPObject::getOwnPropertyDescriptor):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127158 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium-Android] Upstream layout test rebaselined expectations
https://bugs.webkit.org/show_bug.cgi?id=94885

Reviewed by Adam Barth.

We rebaselined tests that
- expect different behaviors on Android (but normally don't show FAIL)
- have different layout because of precision, font size, etc.
- have different layout because of different shadow DOM of the media player

We don't rebaseline tests that would expect to output FAIL.

* platform/chromium-android/compositing/layer-creation/overflow-scrolling-touch-expected.txt: Added.
* platform/chromium-android/compositing/layer-creation/overflow-scrolling-touch.html: Added.
* platform/chromium-android/fast/block/positioning/047-expected.txt: Added.
* platform/chromium-android/fast/css/font-family-pictograph-expected.txt: Added.
* platform/chromium-android/fast/css/line-height-determined-by-primary-font-expected.txt: Added.
* platform/chromium-android/fast/css/text-transform-select-expected.txt: Added.
* platform/chromium-android/fast/dom/Orientation/create-event-orientationchange-expected.txt: Added.
* platform/chromium-android/fast/dom/Window/window-lookup-precedence-expected.txt: Added.
* platform/chromium-android/fast/events/context-onmousedown-event-expected.txt: Added.
* platform/chromium-android/fast/events/mouseup-from-button2-expected.txt: Added.
* platform/chromium-android/fast/font-boosting/various-tricky-cases-expected.txt: Added.
* platform/chromium-android/fast/font-boosting/various-tricky-cases.html: Added.
* platform/chromium-android/fast/forms/HTMLOptionElement_label05-expected.txt: Added.
* platform/chromium-android/fast/forms/disabled-select-change-index-expected.txt: Added.
* platform/chromium-android/fast/forms/form-element-geometry-expected.txt: Added.
* platform/chromium-android/fast/forms/hidden-listbox-expected.txt: Added.
* platform/chromium-android/fast/forms/implicit-submission-expected.txt: Added.
* platform/chromium-android/fast/forms/label/labelable-elements-expected.txt: Added.
* platform/chromium-android/fast/forms/listbox-bidi-align-expected.txt: Added.
* platform/chromium-android/fast/forms/listbox-scrollbar-incremental-load-expected.txt: Added.
* platform/chromium-android/fast/forms/listbox-width-change-expected.txt: Added.
* platform/chromium-android/fast/forms/option-strip-whitespace-expected.txt: Added.
* platform/chromium-android/fast/forms/select-block-background-expected.txt: Added.
* platform/chromium-android/fast/forms/select-change-listbox-size-expected.txt: Added.
* platform/chromium-android/fast/forms/select-change-popup-to-listbox-expected.txt: Added.
* platform/chromium-android/fast/forms/select-initial-position-expected.txt: Added.
* platform/chromium-android/fast/forms/select-list-box-with-height-expected.txt: Added.
* platform/chromium-android/fast/forms/select-overflow-scroll-expected.txt: Added.
* platform/chromium-android/fast/forms/select-overflow-scroll-inherited-expected.txt: Added.
* platform/chromium-android/fast/hidpi/video-controls-in-hidpi-expected.txt: Added.
* platform/chromium-android/fast/layers/video-layer-expected.txt: Added.
* platform/chromium-android/fast/preloader/script-expected.txt: Added.
* platform/chromium-android/fast/repaint/moving-shadow-on-container-expected.txt: Added.
* platform/chromium-android/fast/repaint/moving-shadow-on-path-expected.txt: Added.
* platform/chromium-android/fast/replaced/replaced-breaking-expected.txt: Added.
* platform/chromium-android/fast/text/capitalize-boundaries-expected.txt: Added.
* platform/chromium-android/fast/text/cg-fallback-bolding-expected.txt: Added.
* platform/chromium-android/fast/text/complex-text-opacity-expected.txt: Added.
* platform/chromium-android/fast/text/drawBidiText-expected.txt: Added.
* platform/chromium-android/fast/text/international/bidi-listbox-atsui-expected.txt: Added.
* platform/chromium-android/fast/text/international/bidi-listbox-expected.txt: Added.
* platform/chromium-android/fast/text/international/hindi-spacing-expected.txt: Added.
* platform/chromium-android/fast/text/international/thai-line-breaks-expected.txt: Added.
* platform/chromium-android/fast/text/updateNewFont-expected.txt: Added.
* platform/chromium-android/http/tests/security/contentSecurityPolicy/media-src-blocked-expected.txt: Added.
* platform/chromium-android/media/W3C/audio/canPlayType/canPlayType_supported_but_no_codecs_parameter_2-expected.txt: Added.
* platform/chromium-android/media/W3C/video/canPlayType/canPlayType_codecs_order_2-expected.txt: Added.
* platform/chromium-android/media/W3C/video/canPlayType/canPlayType_codecs_order_3-expected.txt: Added.
* platform/chromium-android/media/W3C/video/canPlayType/canPlayType_supported_but_no_codecs_parameter_2-expected.txt: Added.
* platform/chromium-android/media/W3C/video/canPlayType/canPlayType_supported_but_no_codecs_parameter_3-expected.txt: Added.
* platform/chromium-android/media/W3C/video/canPlayType/canPlayType_two_implies_one_3-expected.txt: Added.
* platform/chromium-android/media/W3C/video/canPlayType/canPlayType_two_implies_one_4-expected.txt: Added.
* platform/chromium-android/media/audio-controls-rendering-expected.txt: Added.
* platform/chromium-android/media/controls-after-reload-expected.txt: Added.
* platform/chromium-android/media/controls-strict-expected.txt: Added.
* platform/chromium-android/media/controls-styling-expected.txt: Added.
* platform/chromium-android/media/controls-styling-strict-expected.txt: Added.
* platform/chromium-android/media/controls-without-preload-expected.txt: Added.
* platform/chromium-android/media/csp-blocks-video-expected.txt: Added.
* platform/chromium-android/media/encrypted-media/encrypted-media-can-play-type-expected.txt: Added.
* platform/chromium-android/media/media-can-play-mpeg-audio-expected.txt: Added.
* platform/chromium-android/media/media-can-play-mpeg4-video-expected.txt: Added.
* platform/chromium-android/media/media-can-play-ogg-expected.txt: Added.
* platform/chromium-android/media/media-controls-clone-expected.txt: Added.
* platform/chromium-android/media/media-document-audio-repaint-expected.txt: Added.
* platform/chromium-android/media/track/track-cue-rendering-horizontal-expected.txt: Added.
* platform/chromium-android/media/track/track-cue-rendering-vertical-expected.txt: Added.
* platform/chromium-android/media/video-controls-rendering-expected.txt: Added.
* platform/chromium-android/media/video-currentTime-set-expected.txt: Added.
* platform/chromium-android/media/video-display-toggle-expected.txt: Added.
* platform/chromium-android/media/video-empty-source-expected.txt: Added.
* platform/chromium-android/media/video-no-audio-expected.txt: Added.
* platform/chromium-android/media/video-playing-and-pause-expected.txt: Added.
* platform/chromium-android/media/video-source-error-expected.txt: Added.
* platform/chromium-android/media/video-zoom-controls-expected.txt: Added.
* platform/chromium-android/svg/W3C-SVG-1.1/paths-data-03-f-expected.txt: Added.
* platform/chromium-android/svg/W3C-SVG-1.1/paths-data-12-t-expected.txt: Added.
* platform/chromium-android/svg/css/composite-shadow-example-expected.txt: Added.
* platform/chromium-android/svg/css/composite-shadow-with-opacity-expected.txt: Added.
* platform/chromium-android/svg/css/stars-with-shadow-expected.txt: Added.
* platform/chromium-android/svg/custom/scrolling-embedded-svg-file-image-repaint-problem-expected.txt: Added.
* platform/chromium-android/svg/custom/use-on-symbol-inside-pattern-expected.txt: Added.
* platform/chromium-android/transforms/2d/hindi-rotated-expected.txt: Added.
* platform/chromium/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127159 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[BlackBerry] Remove unneeded force-immediate-repaint from InRegionScroller::setLayerScrollPosition
https://bugs.webkit.org/show_bug.cgi?id=95476
PR #200704

Reviewed by Yong Li.
Patch by Antonio Gomes <agomes@rim.com>

This code is not needed at this point for neither the fast nor slow in-region
scroll codepaths, and it a huge performance beast as it forces all
containers to get full-repainted per scroll call (in webkit thread).

Patch also take this opportunity to remove an early-return we
have in the {i}frame slow scrolling code path so that we can
adjust the selection handles in this case as well.

* Api/InRegionScroller.cpp:
(BlackBerry::WebKit::InRegionScrollerPrivate::setLayerScrollPosition):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127160 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Mac] Registering web views for notifications is unbalanced
https://bugs.webkit.org/show_bug.cgi?id=95465
<rdar://problem/12206765>

Reviewed by Darin Adler.

Setting the notification provider for a WK1 WebView registers that web view to the
provider. When the WebView is closed, WebCore is essentially responsible for
unregistering the web view. This leads to an imbalance on Lion since notifications are
not supported, and the NotificationController responsible for making the unregistration
call doesn't exist.

Instead, the unregisterWebView method should be called when the web view is closed.

* WebView/WebViewPrivate.h: Remove _notificationControllerDestroyed, since it is
unneeded.

* WebCoreSupport/WebNotificationClient.mm:
(WebNotificationClient::notificationControllerDestroyed):
* WebView/WebView.mm:
(-[WebView _close]): Unregister the web view from the assigned provider here.
(-[WebView _setNotificationProvider:]): Only allow setting the provider once, to avoid
registering the web view to multiple providers.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127161 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Add support for blendmode to webkit rendering engine
https://bugs.webkit.org/show_bug.cgi?id=95258

Patch by Rik Cabanier <cabanier@adobe.com> on 2012-08-30
Reviewed by Simon Fraser.

Source/WebCore:

This code adds support for blendmodes to the WebCore engine. The CSS parser already
supported this keyword but didn't pass it along. Support for rendering blending will
be provided in subsequent patches

Test: css3/compositing/should-have-compositing-layer.html

* css/StyleBuilder.cpp:
(WebCore::StyleBuilder::StyleBuilder):
* css/StyleResolver.cpp:
(WebCore::StyleResolver::collectMatchingRulesForList):
* rendering/RenderBox.h:
* rendering/RenderBoxModelObject.h:
(RenderBoxModelObject):
(WebCore::RenderBoxModelObject::requiresLayer):
* rendering/RenderInline.h:
(WebCore::RenderInline::requiresLayer):
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::RenderLayer):
(WebCore):
(WebCore::RenderLayer::updateBlendMode):
(WebCore::RenderLayer::ensureBacking):
(WebCore::RenderLayer::shouldBeNormalFlowOnly):
(WebCore::RenderLayer::styleChanged):
* rendering/RenderLayer.h:
(RenderLayer):
(WebCore::RenderLayer::hasBlendMode):
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::requiresCompositingLayer):
(WebCore::RenderLayerCompositor::requiresOwnBackingStore):
(WebCore::RenderLayerCompositor::reasonForCompositing):
(WebCore::RenderLayerCompositor::requiresCompositingForIndirectReason):
(WebCore::RenderLayerCompositor::requiresCompositingForBlending):
(WebCore):
* rendering/RenderLayerCompositor.h:
(RenderLayerCompositor):
* rendering/RenderObject.h:
(RenderObject):
(WebCore::RenderObject::hasBlendMode):
(WebCore::RenderObject::createsGroup):
* rendering/RenderTableRow.h:
* rendering/style/RenderStyle.h:

LayoutTests:

Enable test to verify that blending modes introduce a new compositing layer

* css3/compositing/resources: Added.
* css3/compositing/resources/reference.png: Added.
* css3/compositing/should-have-compositing-layer-expected.txt: Added.
* css3/compositing/should-have-compositing-layer.html: Added.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127162 268f45cc-cd09-0410-ab3c-d52691b4dbfc
CSS 2.1 failure: margin-collapse-clear-012 fails
https://bugs.webkit.org/show_bug.cgi?id=80394

Reviewed by David Hyatt.

Source/WebCore:

CSS2.1 states: "If the top and bottom margins of an element with clearance are adjoining, its margins collapse with
the adjoining margins of following siblings but that resulting margin does not collapse with the bottom margin of the parent block."
This is a change in the spec since http://trac.webkit.org/changeset/47678, so prevent the margins of collapsed blocks from collapsing
with parent margins.

Also, in the case of self-collapsing blocks adjust the clearance so that it is equal to [height of float to clear] - margin-top of the
self-collapsing block. (See the 'Explanation' section near the end of http://www.w3.org/TR/CSS21/visuren.html#clearance). This allows
the correct value of any margins collapsed with subsequent siblings to contribute to the height of the parent. For example if a block
with margin-top of 40px has to clear a float of 100px, the clearance is now 60px so set that as the height of the parent. If a subsequent
sibling has a collapsed margin value of 140px (e.g. from a margin-top of 80px and a margin-bottom of 140px) then the height of the parent
becomes 200px by adding on that collapsed margin.

Tests: css2.1/20110323/margin-collapse-clear-012.htm
       css2.1/20110323/margin-collapse-clear-013.htm
       css2.1/20110323/margin-collapse-027.htm
       fast/css/margin-collapse-013-reduction.html
       fast/css/margin-collapse-top-margin-clearance.html
       fast/css/margin-collapse-top-margin-clearance-with-sibling.html

* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::clearFloatsIfNeeded):
(WebCore::RenderBlock::handleAfterSideOfBlock): Without this margin-collapse/block-inside-inline/025.html adds in the margin to
  an anonymous block containing a block child. FF does this, Opera does not. The spec is not crystal-clear but Opera's behaviour
  seems correct - it's totally unintuitive to think the margins of an anonymous block and its block-flow child should be considered adjoining.
  Maybe this is a FIXME pending clarification in the spec?
* rendering/RenderBlock.h:
(WebCore::RenderBlock::MarginInfo::setCanCollapseMarginAfterWithChildren):

LayoutTests:

* css2.1/20110323/margin-collapse-027-expected.html: Added.
* css2.1/20110323/margin-collapse-027.htm: Added.
* css2.1/20110323/margin-collapse-clear-012-expected.html: Added.
* css2.1/20110323/margin-collapse-clear-012.htm: Added.
* css2.1/20110323/margin-collapse-clear-013-expected.html: Added.
* css2.1/20110323/margin-collapse-clear-013.htm: Added.
* css2.1/20110323/margin-collapse-clear-014-expected.html: Added.
* css2.1/20110323/margin-collapse-clear-014.htm: Added.
* css2.1/20110323/margin-collapse-clear-015-expected.html: Added.
* css2.1/20110323/margin-collapse-clear-015.htm: Added.
* css2.1/20110323/margin-collapse-clear-016-expected.html: Added.
* css2.1/20110323/margin-collapse-clear-016.htm: Added.
* css2.1/20110323/margin-collapse-clear-017-expected.html: Added.
* css2.1/20110323/margin-collapse-clear-017.htm: Added.
* fast/block/margin-collapse/empty-clear-blocks.html:
  Modified the test to reflect the new expected result. The text in the third paragraph avoids
  the float rather than sitting underneath it. The text in the third last paragraph is 20 px below
  the float rather than immediately beneath it. Both of these are a consequence of the revised treatment
  of clearance when margin collapsing. This is consistent with the spec and FF and Opera.
* fast/css/margin-collapse-013-reduction.html: Added.
   Sourced from https://bugzilla.mozilla.org/show_bug.cgi?id=493380
* fast/css/margin-collapse-top-margin-clearance-with-sibling-expected.html: Added.
* fast/css/margin-collapse-top-margin-clearance-with-sibling.html: Added.
    Ensure we only avoid collapsing the margins of a self-collapsing block with the parent if we don't
    have a subsequent sibling with height.
* fast/css/margin-collapse-top-margin-clearance.html: Added.

* platform/chromium-linux/fast/block/float/024-expected.png:
* platform/chromium-linux/fast/block/margin-collapse/empty-clear-blocks-expected.png:
  These two progress to the same rendering used by FF and Opera. It is a consequence of calculating
  clearance as "clearance = [height of float] - margin-top" when margin-top is a negative value.

* platform/chromium-win/fast/block/float/024-expected.txt:
* platform/chromium-win/fast/block/margin-collapse/025-expected.txt:
* platform/chromium-win/fast/block/margin-collapse/block-inside-inline/025-expected.txt:
    The change in result for these three is a consequence of self-collapsing blocks with clearance moving their top up past the float by the value
    of their top margin. Unlike the block-inside-inline case the 'clear' has no intrinsic height so the uncollapsed margin value has
    no effect on its height.

* platform/chromium-win/fast/block/margin-collapse/empty-clear-blocks-expected.txt: See the png result above for comment.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127163 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Fixing two inspector tests that fail on Mac WK1.

* inspector/timeline/timeline-animation-frame-expected.txt:
* inspector/timeline/timeline-paint-expected.txt:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127164 268f45cc-cd09-0410-ab3c-d52691b4dbfc
MediaStream API: Introduce MediaConstraints
https://bugs.webkit.org/show_bug.cgi?id=95198

Reviewed by Adam Barth.

Source/Platform:

Adds WebMediaConstraints.

* Platform.gypi:
* chromium/public/WebMediaConstraints.h: Copied from Source/Platform/chromium/public/WebRTCPeerConnectionHandler.h.
(WebCore):
(WebKit):
(WebMediaConstraints):
(WebKit::WebMediaConstraints::WebMediaConstraints):
(WebKit::WebMediaConstraints::~WebMediaConstraints):
(WebKit::WebMediaConstraints::operator=):
* chromium/public/WebRTCPeerConnectionHandler.h:
(WebKit):
(WebRTCPeerConnectionHandler):

Source/WebCore:

This introduces MediaConstraints together with relevant infrastructure, a chromium mock and LayoutTests.

Patch covered by expanded existing tests.

* CMakeLists.txt:
* GNUmakefile.list.am:
* Modules/mediastream/MediaConstraintsImpl.cpp: Added.
(WebCore):
(WebCore::MediaConstraintsImpl::create):
(WebCore::MediaConstraintsImpl::initialize):
(WebCore::MediaConstraintsImpl::~MediaConstraintsImpl):
(WebCore::MediaConstraintsImpl::getMandatoryConstraintNames):
(WebCore::MediaConstraintsImpl::getOptionalConstraintNames):
(WebCore::MediaConstraintsImpl::getMandatoryConstraintValue):
(WebCore::MediaConstraintsImpl::getOptionalConstraintValue):
* Modules/mediastream/MediaConstraintsImpl.h: Copied from Source/WebCore/platform/mediastream/RTCPeerConnectionHandler.h.
(WebCore):
(MediaConstraintsImpl):
(WebCore::MediaConstraintsImpl::MediaConstraintsImpl):
* Modules/mediastream/RTCPeerConnection.cpp:
(WebCore::RTCPeerConnection::create):
(WebCore::RTCPeerConnection::RTCPeerConnection):
* Modules/mediastream/RTCPeerConnection.h:
(WebCore):
(RTCPeerConnection):
* WebCore.gypi:
* bindings/js/Dictionary.cpp:
(WebCore::Dictionary::getOwnPropertyNames):
(WebCore):
* bindings/js/Dictionary.h:
(Dictionary):
* bindings/v8/Dictionary.cpp:
(WebCore::Dictionary::getOwnPropertyNames):
(WebCore):
* bindings/v8/Dictionary.h:
(Dictionary):
* platform/chromium/support/WebMediaConstraints.cpp: Copied from Source/WebCore/platform/mediastream/RTCPeerConnectionHandler.cpp.
(WebKit):
(WebKit::WebMediaConstraints::WebMediaConstraints):
(WebKit::WebMediaConstraints::assign):
(WebKit::WebMediaConstraints::reset):
(WebKit::WebMediaConstraints::isNull):
(WebKit::WebMediaConstraints::getMandatoryConstraintNames):
(WebKit::WebMediaConstraints::getOptionalConstraintNames):
(WebKit::WebMediaConstraints::getMandatoryConstraintValue):
(WebKit::WebMediaConstraints::getOptionalConstraintValue):
* platform/mediastream/MediaConstraints.h: Copied from Source/WebCore/platform/mediastream/RTCPeerConnectionHandler.h.
(WebCore):
(MediaConstraints):
(WebCore::MediaConstraints::~MediaConstraints):
(WebCore::MediaConstraints::MediaConstraints):
* platform/mediastream/RTCPeerConnectionHandler.cpp:
(RTCPeerConnectionHandlerDummy):
(WebCore::RTCPeerConnectionHandlerDummy::initialize):
* platform/mediastream/RTCPeerConnectionHandler.h:
(WebCore):
(RTCPeerConnectionHandler):
* platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.cpp:
(WebCore::RTCPeerConnectionHandlerChromium::initialize):
* platform/mediastream/chromium/RTCPeerConnectionHandlerChromium.h:
(RTCPeerConnectionHandlerChromium):

Tools:

Extending the MockWebRTCPeerConnectionHandler with MediaConstraints functionality.

* DumpRenderTree/chromium/MockWebRTCPeerConnectionHandler.cpp:
(MockWebRTCPeerConnectionHandler::MockWebRTCPeerConnectionHandler):
(isSupportedConstraint):
(isValidConstraint):
(MockWebRTCPeerConnectionHandler::initialize):
* DumpRenderTree/chromium/MockWebRTCPeerConnectionHandler.h:
(MockWebRTCPeerConnectionHandler):

LayoutTests:

* fast/mediastream/RTCPeerConnection-expected.txt:
* fast/mediastream/RTCPeerConnection.html:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127165 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Assertion failure in MessagePort::contextDestroyed in
http/tests/security/MessagePort/event-listener-context.html, usually attributed to later tests.
https://bugs.webkit.org/show_bug.cgi?id=94458

fast/events/message-port-constructor-for-deleted-document.html also asserts in
MessagePort::contextDestroyed, and it is usually attributed to later tests as well. Skip it.

* platform/mac/TestExpectations:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127166 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Build warning : -Wsign-compare on DFGByteCodeParser.cpp.
https://bugs.webkit.org/show_bug.cgi?id=95418

Patch by Byungwoo Lee <bw80.lee@samsung.com> on 2012-08-30
Reviewed by Filip Pizlo.

There is a build warning '-Wsign-compare' on
findArgumentPositionForLocal() in DFGByteCodeParser.cpp.

For removing this warning, casting statement is added explicitly.

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::findArgumentPositionForLocal):
(JSC::DFG::ByteCodeParser::findArgumentPosition):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127167 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] The CC button is not painted
https://bugs.webkit.org/show_bug.cgi?id=95395

Reviewed by Eric Carlson.

Source/WebCore:

The actual Chromium resource for the CC button was not used by the Chromium theme.

Existing track rendering tests will be rebaselined and contain the new CC button.

* rendering/RenderMediaControlsChromium.cpp:
(WebCore::paintMediaClosedCaptionsButton): Added for proper painting of the resource.
(WebCore):
(WebCore::RenderMediaControlsChromium::paintMediaControlsPart):
Changed to call paintMediaClosedCaptionsButton when the control is the CC button.
* rendering/RenderThemeChromiumSkia.cpp:
(WebCore::RenderThemeChromiumSkia::paintMediaToggleClosedCaptionsButton):
Implemented proper behaviour.
(WebCore):
* rendering/RenderThemeChromiumSkia.h:
(RenderThemeChromiumSkia):

LayoutTests:

No new tests, the existing ones will need to be rebaselined and include the CC button.

* platform/chromium/TestExpectations: Marked tests failing accordingly for rebaselining.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127168 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed rebaseline after r127101.

The Mac 10.6 results are slightly different--decoding about 10% less of the image.
After some discussion with Adam Barth we determined to rebaseline these.

* platform/chromium-mac-snowleopard/http/tests/images: Added.
* platform/chromium-mac-snowleopard/http/tests/images/webp-partial-load-expected.png: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127169 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CG] ImageCG.cpp contains a mix of Image and BitmapImage functions
https://bugs.webkit.org/show_bug.cgi?id=95470

Reviewed by Darin Adler.

* WebCore.gypi: Added BitmapImageCG.cpp.
* WebCore.vcproj/WebCore.vcproj: Ditto.
* WebCore.xcodeproj/project.pbxproj: Ditto.
* platform/graphics/cg/BitmapImageCG.cpp: Copied from Source/WebCore/platform/graphics/cg/ImageCG.cpp
then deleted Image function implementations.
* platform/graphics/cg/ImageCG.cpp: Deleted BitmapImage and FrameData function implementations.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127170 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Mac] Add testRunner.dumpWebNotificationCallbacks() to DRT
https://bugs.webkit.org/show_bug.cgi?id=95232
<rdar://problem/12190776>

Reviewed by Alexey Proskuryakov.

Source/WebKit/mac:

* WebKit.exp: Export WebNotification class.

Tools:

Add additional output when running test, if testRunner.dumpWebNotificationCallbacks() is called.

* DumpRenderTree/TestRunner.cpp:
(TestRunner::TestRunner):
(dumpWebNotificationCallbacksCallback):
(TestRunner::staticFunctions):
* DumpRenderTree/TestRunner.h:
(TestRunner):
(TestRunner::dumpWebNotificationCallbacks):
(TestRunner::setDumpWebNotificationCallbacks):
* DumpRenderTree/mac/MockWebNotificationProvider.mm:
(-[WebNotification _drt_descriptionSuitableForTestResult]):
(-[MockWebNotificationProvider webView:didShowNotification:]):
(-[MockWebNotificationProvider webView:didClickNotification:]):
(-[MockWebNotificationProvider webView:didCloseNotifications:]):
* DumpRenderTree/mac/UIDelegate.mm:
(-[UIDelegate webView:decidePolicyForNotificationRequestFromOrigin:listener:]):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127171 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Add CompositorSupport interface for constructing compositor classes
https://bugs.webkit.org/show_bug.cgi?id=95040

Reviewed by Darin Fisher.

Source/Platform:

Adds a WebCompositorSupport interface as a tear-off of PlatformSupport so the embedder can handle provide
implementations of compositor interfaces.

Adds a new WebPassOwnPtr<> type for use when the caller of an API must take ownership of the provided parameter.

* Platform.gypi:
* chromium/public/Platform.h:
(WebKit):
(WebKit::Platform::compositorSupport):
(Platform):
* chromium/public/WebCompositorSupport.h: Added.
(WebKit):
(WebCompositorSupport):
(WebKit::WebCompositorSupport::~WebCompositorSupport):

Source/WebCore:

Uses WebCompositorSupport interfaces where appropriate to construct compositor types.

* platform/graphics/chromium/AnimationTranslationUtil.cpp:
(WebCore::createWebAnimation):
* platform/graphics/chromium/Canvas2DLayerBridge.cpp:
(WebCore::Canvas2DLayerBridge::Canvas2DLayerBridge):
* platform/graphics/chromium/DrawingBufferChromium.cpp:
(WebCore::DrawingBufferPrivate::DrawingBufferPrivate):
* platform/graphics/chromium/GraphicsLayerChromium.cpp:
(WebCore::GraphicsLayerChromium::GraphicsLayerChromium):
(WebCore::GraphicsLayerChromium::setContentsToImage):
(WebCore::GraphicsLayerChromium::setContentsTo):
(WebCore::GraphicsLayerChromium::addAnimation):
(WebCore::GraphicsLayerChromium::updateLayerPreserves3D):

Source/WebKit/chromium:

* src/LinkHighlight.cpp:
(WebKit::LinkHighlight::LinkHighlight):
(WebKit::LinkHighlight::startHighlightAnimation):
* src/WebMediaPlayerClientImpl.cpp:
(WebKit::WebMediaPlayerClientImpl::readyStateChanged):
* src/WebMediaPlayerClientImpl.h:
(WebKit):
* src/WebPluginContainerImpl.cpp:
(WebKit::WebPluginContainerImpl::setBackingTextureId):
(WebKit::WebPluginContainerImpl::setBackingIOSurfaceId):
* src/WebPluginContainerImpl.h:
(WebKit):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127172 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[CSS Shaders] Update css3/filters/custom/effect-custom-transform-parameters.html to remove anti-aliasing issues
https://bugs.webkit.org/show_bug.cgi?id=95407

Reviewed by Dean Jackson.

The initial test had a white border to prevent anti-aliasing effects, but that doesn't seem to
help on some platforms. Removed the border in this patch.

* css3/filters/custom/effect-custom-transform-parameters-expected.html:
* css3/filters/custom/effect-custom-transform-parameters.html:
* platform/mac-lion/TestExpectations: Un-skipping the test.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127173 268f45cc-cd09-0410-ab3c-d52691b4dbfc
NRWT should look in mac-wk2 for a TestExpecations file
https://bugs.webkit.org/show_bug.cgi?id=95370

Reviewed by Ojan Vafai.

Adds support for mac-wk2 and win-wk2 to expectations_files()
for the apple mac and apple win ports.

* Scripts/webkitpy/layout_tests/port/apple.py:
(ApplePort.expectations_files):
* Scripts/webkitpy/layout_tests/port/mac_unittest.py:
(MacTest.test_expectations_files):
* Scripts/webkitpy/layout_tests/port/win_unittest.py:
(WinTest.test_expectations_files):
* Scripts/webkitpy/layout_tests/port/port_testcase.py:
(PortTestCase.test_expectations_files):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127174 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[chromium] Make webkit_compositor specific unit test compilation conditional on gyp var
https://bugs.webkit.org/show_bug.cgi?id=95401

Reviewed by Dirk Pranke.

If use_libcc_for_compositor is set, these tests are being compiled and run elsewhere.

* WebKit.gyp:
* WebKit.gypi:
* WebKitUnitTests.gyp:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127175 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[Chromium] Layout Test media/track/track-cue-rendering-snap-to-lines-not-set.html is flaky
https://bugs.webkit.org/show_bug.cgi?id=89167

Reviewed by Eric Carlson.

Source/WebCore:

Fix for rendering tracks when snap-to-lines not set.

No new tests. Removed from TestExpectations existing test.

* html/track/TextTrackCue.cpp:
(WebCore::TextTrackCue::TextTrackCue):
(WebCore::TextTrackCue::calculateDisplayParameters): Updated the place
where m_computedLinePosition is determined.

LayoutTests:

Removed possible flaky test from TestExceptations.

* platform/chromium/TestExpectations:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@127176 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Unreviewed update of TestExpectations.

These tests are awaiting a rebaseline after r127168 but have the wrong modifiers on them. They
are failing for Image but have Image+Text. Updating to fix that.

* platform/chromium/TestExpectations:


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