2013-04-24 Arvid Nilsson [BlackBerry] Remove the setContentsToColor flavor of LayerTiler::TextureJob https://bugs.webkit.org/show_bug.cgi?id=115092 Reviewed by Carlos Garcia Campos. With the Skia backend, we had an optimization to detect solid color layers. The Skia code has been purged, but these bits remained. With BlackBerry::Platform::Graphics::PlatformGraphicsContext, only the solid color will be drawn anyway, so we don't need to detect such layers at the WebCore level. Fixed by removing the setContentsToColor flavor of LayerTiler::TextureJob. BlackBerry::WebKit::WebOverlay still uses TextureCacheCompositingThread::textureForColor() so that one can stay for now. This was dead code so no new tests. * platform/graphics/blackberry/LayerTile.cpp: * platform/graphics/blackberry/LayerTile.h: (LayerTile): * platform/graphics/blackberry/LayerTiler.cpp: (WebCore::LayerTiler::processTextureJob): (WebCore::LayerTiler::performTileJob): * platform/graphics/blackberry/LayerTiler.h: (WebCore::LayerTiler::TextureJob::setContents): (TextureJob): 2013-04-24 Zan Dobersek [GTK] Move image decoders, some other GStreamer, Cairo and Soup sources to libPlatform https://bugs.webkit.org/show_bug.cgi?id=115050 Reviewed by Martin Robinson. No new tests - no new functionality. * GNUmakefile.list.am: Move the image decoders source files and a couple of GStreamer, Cairo and Libsoup source files under the libPlatform's list of files to build. All of these are already free of platform layer violations. 2013-04-23 Kent Tamura Remove TextFieldDecoration feature https://bugs.webkit.org/show_bug.cgi?id=115068 Reviewed by Andreas Kling. Only Chromium port used this feature. * dom/Element.h: Remove isTextFieldDecoration. * html/InputType.cpp: (WebCore::InputType::destroyShadowSubtree): Update a comment. * html/TextFieldInputType.cpp: (WebCore::TextFieldInputType::createShadowSubtree): Remove call sites of willAddTextFieldDecorationsTo and addTextFieldDecorationsTo. * html/shadow/TextFieldDecorationElement.cpp: Removed. * html/shadow/TextFieldDecorationElement.h: Removed. * page/ChromeClient.h: (ChromeClient): Remove willAddTextFieldDecorationsTo and addTextFieldDecorationsTo 2013-04-23 Andreas Kling Micro-optimize Length::initFromLength(). From Blink r148621 by : This appears to improve html5-full-render by 1-2% on my system (gcc 4.6.3) by using memcpy instead of copying members (and branching to copy the union). * platform/Length.h: (WebCore::Length::initFromLength): 2013-04-23 Kent Tamura Add missing copyright header to ColorChooserClient.h https://bugs.webkit.org/show_bug.cgi?id=115067 Reviewed by Andreas Kling. * platform/ColorChooserClient.h: This was added in 2011 by a Google employee. http://trac.webkit.org/changeset/103168 2013-04-23 Andreas Kling Call the correct superclass in RenderSlider::layout(). From Blink r147850 by : The superclass is RenderFlexibleBox, not RenderBlock. * rendering/RenderSlider.cpp: (WebCore::RenderSlider::layout): 2013-04-23 Mihai Tica Add platform support for -webkit-background-blend-mode to CG context with background color https://bugs.webkit.org/show_bug.cgi?id=114412 Reviewed by Darin Adler. Tests: css3/compositing/effect-background-blend-mode-color.html, css3/compositing/effect-background-blend-mode-color2.html This patch adds support for blending on background colors to the Core Graphics port of WebKit. * platform/graphics/GraphicsContext.cpp: (WebCore::GraphicsContext::fillRect): (WebCore::GraphicsContext::fillRoundedRect): * platform/graphics/GraphicsContext.h: * rendering/RenderBoxModelObject.cpp: (WebCore::RenderBoxModelObject::paintFillLayerExtended): 2013-04-23 Ryosuke Niwa Remove an unused member variable erroneously added in r149007. * rendering/LogicalSelectionOffsetCaches.h: (WebCore::LogicalSelectionOffsetCaches::LogicalSelectionOffsetCaches): (LogicalSelectionOffsetCaches): 2013-04-22 Ryosuke Niwa logicalLeftSelectionGap and logicalRightSelectionGap call availableLogicalWidth() multiple times https://bugs.webkit.org/show_bug.cgi?id=113479 Reviewed by David Hyatt. Introduced LogicalSelectionOffsetCaches to cache the containing blocks and their logical left and right selection offsets in computing selection gaps. An instance of this class stores the containing block for each position type and caches their logical selection offsets when none of their block ancestors up until its nearest selection root do no have any floating objects or regions and exclusions. When blockSelectionGaps recurses to another level, it creates a new cache instance by "inheriting" (like RenderStyle) from the old cache, overriding those containing blocks that are replaced by "this". This eliminates the need to traverse containing block ancestors in RenderBlock::logicalLeftSelectionOffset and RenderBlock::logicalRightSelectionOffset, and improves WebKit's performance by roughly 20%. Performance Tests: Interactive/SelectAll.html * GNUmakefile.list.am: * Target.pri: * WebCore.xcodeproj/project.pbxproj: * rendering/LogicalSelectionOffsetCaches.h: Added. (WebCore::isContainingBlockCandidateForAbsolutelyPositionedObject): Moved from RenderObject.h. (WebCore::isNonRenderBlockInline): Ditto. (WebCore::containingBlockForFixedPosition): Extracted from RenderObject::containingBlock. (WebCore::containingBlockForAbsolutePosition): Ditto. (WebCore::containingBlockForObjectInFlow): Ditto. (WebCore::LogicalSelectionOffsetCaches): Added. (WebCore::LogicalSelectionOffsetCaches::ContainingBlockInfo::ContainingBlockInfo): Added. (WebCore::LogicalSelectionOffsetCaches::ContainingBlockInfo::setBlock): Added. m_hasFloatsOrRegions is or'ed with itself when ContainingBlockInfo is copy constructed since m_hasFloatsOrRegions needs be true for a block when any of its containing block ancestors have floats or regions. (WebCore::LogicalSelectionOffsetCaches::ContainingBlockInfo::block): Added. (WebCore::LogicalSelectionOffsetCaches::ContainingBlockInfo::cache): Added. (WebCore::LogicalSelectionOffsetCaches::ContainingBlockInfo::logicalLeftSelectionOffset): Added. Caches the logical selection offset if it hasn't. (WebCore::LogicalSelectionOffsetCaches::ContainingBlockInfo::logicalRightSelectionOffset): Ditto. (WebCore::LogicalSelectionOffsetCaches::LogicalSelectionOffsetCaches): The first constructor is used for a selection root. The second one is used for inheriting from another cache. In the latter case, copy all containing block information except ones that need to be overridden by this block. (WebCore::LogicalSelectionOffsetCaches::containingBlockInfo): Returns a ContainingBlockInfo based on object's position value. * rendering/RenderBlock.cpp: (WebCore::RenderBlock::selectionGapRectsForRepaint): (WebCore::RenderBlock::paintSelection): (WebCore::RenderBlock::selectionGaps): (WebCore::RenderBlock::inlineSelectionGaps): (WebCore::RenderBlock::blockSelectionGaps): Exit before instantiating a new LogicalSelectionOffsetCaches if there is no child to recurse. (WebCore::RenderBlock::blockSelectionGap): (WebCore::RenderBlock::logicalLeftSelectionGap): (WebCore::RenderBlock::logicalRightSelectionGap): (WebCore::RenderBlock::logicalLeftSelectionOffset): Use LogicalSelectionOffsetCaches to get its containing block and its logical selection offset. (WebCore::RenderBlock::logicalRightSelectionOffset): Ditto. * rendering/RenderBlock.h: (WebCore::RenderBlock): * rendering/RenderObject.cpp: (WebCore::RenderObject::containingBlock): Extracted code into LogicalSelectionOffsetCaches.h. * rendering/RootInlineBox.cpp: (WebCore::RootInlineBox::lineSelectionGap): * rendering/RootInlineBox.h: (WebCore::RootInlineBox): 2013-04-23 Eric Carlson [Mac] forced subtitle track should change when audio track language changes https://bugs.webkit.org/show_bug.cgi?id=115043 Reviewed by Jer Noble. No new tests, it isn't possible to test this automatically because there is currently no way to enable/disable audio tracks. * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::configureTextTrackGroup): Set m_forcedOrAutomaticSubtitleTrackLanguage. (WebCore::HTMLMediaElement::mediaPlayerCharacteristicChanged): Call markCaptionAndSubtitleTracksAsUnconfigured after a delay if the language of the primary audio track changes. (WebCore::HTMLMediaElement::setClosedCaptionsVisible): markCaptionAndSubtitleTracksAsUnconfigured API change. (WebCore::HTMLMediaElement::markCaptionAndSubtitleTracksAsUnconfigured): Take parameter to allow the reconfiguration to happen after a delay to avoid doing it during a callback from the media engine. Clear the ConfigureTextTracks bit in m_pendingActionFlags to cancel any pending asynch configuration. * html/HTMLMediaElement.h: * page/CaptionUserPreferencesMac.mm: (WebCore::CaptionUserPreferencesMac::textTrackSelectionScore): Clean up logic. * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Call characteristicChanged when the primary audio track language changes. 2013-04-23 Hans Muller [CSS Exclusions] Improve ExclusionPolygon smart pointer safety https://bugs.webkit.org/show_bug.cgi?id=114984 Reviewed by Dirk Schulze. Assign newly allocated objects to PassOwnPtrs as early as possible to reduce the chances of future leaks. No new tests were added, this change adds no new functionality. * rendering/ExclusionPolygon.cpp: (WebCore::computeShapePaddingBounds): (WebCore::computeShapeMarginBounds): (WebCore::ExclusionPolygon::shapePaddingBounds): (WebCore::ExclusionPolygon::shapeMarginBounds): * rendering/ExclusionShape.cpp: (WebCore::ExclusionShape::createExclusionShape): 2013-04-23 Andreas Kling Revert "Throttle resize events during live window resize." Reviewed by Geoffrey Garen. It appears that this caused more glitches than it helped resize performance. * page/FrameView.h: * page/FrameView.cpp: (WebCore::FrameView::FrameView): (WebCore::FrameView::performPostLayoutTasks): (WebCore::FrameView::sendResizeEvent): Turn the null-check of m_frame into an assertion since this method is no longer called asynchronously. (WebCore::FrameView::willEndLiveResize): Ninja fix: call up to the closest superclass implementation. 2013-04-23 Christophe Dumez Global constructors should be configurable and not enumerable https://bugs.webkit.org/show_bug.cgi?id=110573 Reviewed by Geoffrey Garen. Update JSC Code generator so that global constructors now have the following attributes: { [[Writable]]: true, [[Enumerable]]: false, [[Configurable]]: true } instead of previously: { [[Writable]]: true, [[Enumerable]]: true, [[Configurable]]: false } The new behavior is according to the Web IDL specification (section 4.4): http://dev.w3.org/cvsweb/~checkout~/2006/webapi/WebIDL/Overview.html?rev=1.617;content-type=text%2Fhtml#es-interfaces This also matches the behavior of Firefox. Tests: fast/js/global-constructors-attributes.html fast/js/global-constructors-deletable.html * bindings/scripts/CodeGeneratorJS.pm: (GenerateAttributesHashTable): 2013-04-23 Simon Fraser Don't create compositing layers for sticky position unless using the ScrollingCoordinator https://bugs.webkit.org/show_bug.cgi?id=115060 Reviewed by Tim Horton. Creating compositing layers for sticky position elements is only useful when we're using a ScrollingCoordinator, so don't create them if we're not in a frame that uses a scrolling coordinator. Tests: compositing/layer-creation/no-compositing-for-sticky.html platform/mac-wk2/tiled-drawing/sticky/sticky-layers.html * rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::requiresCompositingForPosition): 2013-04-23 Christophe Dumez 'length' property of DOM bindings functions returns wrong value https://bugs.webkit.org/show_bug.cgi?id=110569 Reviewed by Geoffrey Garen. Make the 'length' property of Function objects and Interface objects behave according to the latest Web IDL specification editor draft: http://dev.w3.org/2006/webapi/WebIDL/#es-interface-call http://dev.w3.org/2006/webapi/WebIDL/#es-operations As a result, only mandatory arguments are taken into account when computing the value for the 'length' property. This behavior is consistent with Firefox and Blink. Tests: fast/js/constructor-length.html fast/js/function-length.html * bindings/scripts/CodeGeneratorJS.pm: (GenerateImplementation): (GenerateConstructorHelperMethods): Update the JSC code generator to only account for mandatory parameters when computing the value for the 'length' property of Function objects and constructors. * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp: (WebCore::JSTestActiveDOMObjectConstructor::finishCreation): * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp: (WebCore::JSTestCustomNamedGetterConstructor::finishCreation): * bindings/scripts/test/JS/JSTestEventConstructor.cpp: (WebCore::JSTestEventConstructorConstructor::finishCreation): * bindings/scripts/test/JS/JSTestEventTarget.cpp: (WebCore::JSTestEventTargetConstructor::finishCreation): (WebCore): * bindings/scripts/test/JS/JSTestException.cpp: (WebCore::JSTestExceptionConstructor::finishCreation): * bindings/scripts/test/JS/JSTestInterface.cpp: (WebCore::JSTestInterfaceConstructor::finishCreation): * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp: (WebCore::JSTestMediaQueryListListenerConstructor::finishCreation): * bindings/scripts/test/JS/JSTestNamedConstructor.cpp: (WebCore::JSTestNamedConstructorConstructor::finishCreation): (WebCore::JSTestNamedConstructorNamedConstructor::finishCreation): * bindings/scripts/test/JS/JSTestObj.cpp: (WebCore): * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp: (WebCore::JSTestSerializedScriptValueInterfaceConstructor::finishCreation): (WebCore): * bindings/scripts/test/JS/JSTestTypedefs.cpp: (WebCore): Rebaseline bindings tests results. * fileapi/Blob.idl: Remove 'ConstructorParameters=2' extended attribute as the correct value is 0, given that a Blob can be constructed without parameter. * html/canvas/DataView.idl: Update ConstructorParameters extended attribute value from 3 to 1 as only one of the 3 parameters is mandatory. * html/canvas/Float32Array.idl: * html/canvas/Float64Array.idl: * html/canvas/Int16Array.idl: * html/canvas/Int32Array.idl: * html/canvas/Int8Array.idl: * html/canvas/Uint16Array.idl: * html/canvas/Uint32Array.idl: * html/canvas/Uint8Array.idl: * html/canvas/Uint8ClampedArray.idl: Remove 'ConstructorParameters=1' extended attribute from interfaces using 'ConstructorTemplate=TypedArray' as the bindings generator now properly compute the number of constructor parameters for such interfaces. * page/WebKitPoint.idl: Remove 'ConstructorParameters=2' extended attribute as the correct value should be 0, given that a WebKitPoint can be constructed without parameters. 2013-04-23 Benjamin Poulain Minor String usage fixes in WebCore/platform https://bugs.webkit.org/show_bug.cgi?id=115021 Reviewed by Andreas Kling. Use ASCIILiteral when possible + minor fixes. * platform/ContentType.cpp: (WebCore::ContentType::codecs): * platform/ContentType.h: (ContentType): * platform/Decimal.cpp: (WebCore::Decimal::toString): * platform/KURL.cpp: (WebCore::KURL::setProtocol): 2013-04-23 Dirk Schulze Pick up color and mat values in custom shaders https://bugs.webkit.org/show_bug.cgi?id=115046 Reviewed by Dean Jackson. The custom filter functions accept color values and mat2-4 functions as parameter types. These were implemented in CSS already. This patch picks up the values and applies them as uniforms to the custom shader program. Tests: css3/filters/custom/custom-filter-color.html css3/filters/custom/custom-filter-matN.html * platform/graphics/filters/CustomFilterRenderer.cpp: (WebCore::CustomFilterRenderer::bindProgramColorParameters): Set uniform for color values. (WebCore): (WebCore::CustomFilterRenderer::bindProgramMatrixParameters): Set uniform for mat2-4 values. (WebCore::CustomFilterRenderer::bindProgramParameters): Call color and matrix functions. * platform/graphics/filters/CustomFilterRenderer.h: (WebCore): (CustomFilterRenderer): 2013-04-23 Jacky Jiang Remove redundant code in ViewportArguments::resolve https://bugs.webkit.org/show_bug.cgi?id=115054 Reviewed by Kenneth Rohde Christiansen. Remove redundant code "result.orientation = orientation;". * dom/ViewportArguments.cpp: (WebCore::ViewportArguments::resolve): 2013-04-23 Simon Fraser Tiled layers clipped inside nested transform/preserve-3d hierarchies https://bugs.webkit.org/show_bug.cgi?id=115044 Reviewed by Dean Jackson. The optimization added in r139479 to call move() for integral translation transforms hit a bug in TransformState::move(). If m_accumulatedTransform is not null, we have to apply it. Test: compositing/visible-rect/flipped-preserve-3d.html * platform/graphics/transforms/TransformState.cpp: (WebCore::TransformState::move): 2013-04-23 Claudio Saavedra Ctrl+Shift+Right in Windows should select the spacing after the word https://bugs.webkit.org/show_bug.cgi?id=110487 Reviewed by Ryosuke Niwa. Tests: editing/deleting/smart-editing-disabled-win.html editing/execCommand/remove-format-multiple-elements-win.html editing/execCommand/toggle-link-win.html editing/execCommand/toggle-unlink-win.html editing/selection/extend-selection-enclosing-block-win.html editing/style/make-text-writing-direction-inline-win.html editing/style/push-down-font-styles-win.html editing/style/push-down-implicit-styles-around-list-win.html * editing/FrameSelection.cpp: (WebCore::FrameSelection::nextWordPositionForPlatform): New method that takes platform-specific editing behaviour in order to decide what the next word position is, that is, for Windows, skip spacing, for all other platforms, behave as currently. (WebCore::FrameSelection::modifyExtendingRight): (WebCore::FrameSelection::modifyExtendingForward): (WebCore::FrameSelection::modifyMovingForward): (WebCore::FrameSelection::modifyExtendingLeft): Use the new method in all of the above. * editing/FrameSelection.h: Declare the new method. 2013-04-23 Benjamin Poulain Inline SelectorQuery::matches, SelectorQuery::queryAll, SelectorQuery::queryFirst https://bugs.webkit.org/show_bug.cgi?id=115012 Reviewed by Andreas Kling. Each of these function has a single call site: -SelectorQuery::matches from Element::webkitMatchesSelector. -SelectorQuery::queryAll from Node::querySelectorAll. -SelectorQuery::queryFirst from Node::querySelector. Having a dedicated method to jump to was a little overkill. * dom/SelectorQuery.cpp: * dom/SelectorQuery.h: (WebCore::SelectorQuery::matches): (WebCore::SelectorQuery::queryAll): (WebCore::SelectorQuery::queryFirst): 2013-04-23 Benjamin Poulain Remove wxWebKit's folders from WebCore https://bugs.webkit.org/show_bug.cgi?id=115007 Reviewed by Andreas Kling. The wxWebKit port is no longer actively maintained by Kevin on webkit.org. Remove the code until new maintainers resume the work. * accessibility/wx/AccessibilityObjectWx.cpp: Removed. * editing/wx/EditorWx.cpp: Removed. * page/wx/DragControllerWx.cpp: Removed. * page/wx/EventHandlerWx.cpp: Removed. * platform/graphics/wx/ColorWx.cpp: Removed. * platform/graphics/wx/FloatRectWx.cpp: Removed. * platform/graphics/wx/FontCacheWx.cpp: Removed. * platform/graphics/wx/FontCustomPlatformData.cpp: Removed. * platform/graphics/wx/FontCustomPlatformData.h: Removed. * platform/graphics/wx/FontPlatformData.h: Removed. * platform/graphics/wx/FontPlatformDataWx.cpp: Removed. * platform/graphics/wx/FontPlatformDataWxMac.mm: Removed. * platform/graphics/wx/FontWx.cpp: Removed. * platform/graphics/wx/GlyphMapWx.cpp: Removed. * platform/graphics/wx/GradientWx.cpp: Removed. * platform/graphics/wx/GraphicsContextWx.cpp: Removed. * platform/graphics/wx/IconWx.cpp: Removed. * platform/graphics/wx/ImageBufferDataWx.h: Removed. * platform/graphics/wx/ImageBufferWx.cpp: Removed. * platform/graphics/wx/ImageWx.cpp: Removed. * platform/graphics/wx/IntPointWx.cpp: Removed. * platform/graphics/wx/IntRectWx.cpp: Removed. * platform/graphics/wx/IntSizeWx.cpp: Removed. * platform/graphics/wx/PathWx.cpp: Removed. * platform/graphics/wx/SimpleFontDataWx.cpp: Removed. * platform/graphics/wx/TransformationMatrixWx.cpp: Removed. * platform/image-decoders/wx/ImageDecoderWx.cpp: Removed. * platform/wx/ClipboardWx.cpp: Removed. * platform/wx/ClipboardWx.h: Removed. * platform/wx/ContextMenuItemWx.cpp: Removed. * platform/wx/ContextMenuWx.cpp: Removed. * platform/wx/CursorWx.cpp: Removed. * platform/wx/DragDataWx.cpp: Removed. * platform/wx/DragImageWx.cpp: Removed. * platform/wx/EventLoopWx.cpp: Removed. * platform/wx/FileSystemWx.cpp: Removed. * platform/wx/KeyEventWin.cpp: Removed. * platform/wx/KeyboardEventWx.cpp: Removed. * platform/wx/LanguageWx.cpp: Removed. * platform/wx/LocalDC.h: Removed. * platform/wx/LocalizedStringsWx.cpp: Removed. * platform/wx/LoggingWx.cpp: Removed. * platform/wx/MimeTypeRegistryWx.cpp: Removed. * platform/wx/MouseEventWx.cpp: Removed. * platform/wx/MouseWheelEventWx.cpp: Removed. * platform/wx/PasteboardWx.cpp: Removed. * platform/wx/PopupMenuWx.cpp: Removed. * platform/wx/PopupMenuWx.h: Removed. * platform/wx/RenderThemeWx.cpp: Removed. * platform/wx/RunLoopWx.cpp: Removed. * platform/wx/SSLKeyGeneratorWx.cpp: Removed. * platform/wx/ScreenWx.cpp: Removed. * platform/wx/ScrollViewWx.cpp: Removed. * platform/wx/ScrollbarThemeWx.cpp: Removed. * platform/wx/ScrollbarThemeWx.h: Removed. * platform/wx/SearchPopupMenuWx.cpp: Removed. * platform/wx/SearchPopupMenuWx.h: Removed. * platform/wx/SharedBufferWx.cpp: Removed. * platform/wx/SharedTimerWx.cpp: Removed. * platform/wx/SoundWx.cpp: Removed. * platform/wx/SystemTimeWx.cpp: Removed. * platform/wx/TemporaryLinkStubs.cpp: Removed. * platform/wx/TextBreakIteratorInternalICUWx.cpp: Removed. * platform/wx/WidgetWx.cpp: Removed. * platform/wx/wxcode/cairo/non-kerned-drawing.cpp: Removed. * platform/wx/wxcode/fontprops.cpp: Removed. * platform/wx/wxcode/fontprops.h: Removed. * platform/wx/wxcode/gdiplus/non-kerned-drawing.cpp: Removed. * platform/wx/wxcode/gtk/fontprops.cpp: Removed. * platform/wx/wxcode/gtk/non-kerned-drawing.cpp: Removed. * platform/wx/wxcode/gtk/scrollbar_render.cpp: Removed. * platform/wx/wxcode/mac/carbon/fontprops.mm: Removed. * platform/wx/wxcode/mac/carbon/non-kerned-drawing.cpp: Removed. * platform/wx/wxcode/mac/carbon/scrollbar_render.cpp: Removed. * platform/wx/wxcode/non-kerned-drawing.h: Removed. * platform/wx/wxcode/scrollbar_render.h: Removed. * platform/wx/wxcode/win/fontprops.cpp: Removed. * platform/wx/wxcode/win/non-kerned-drawing.cpp: Removed. * platform/wx/wxcode/win/scrollbar_render.cpp: Removed. * plugins/wx/PluginDataWx.cpp: Removed. 2013-04-23 Roger Fong AppleWin build fix. * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: 2013-04-23 Roger Fong AppleWin build fix. * inspector/InspectorAllInOne.cpp: * inspector/InspectorMemoryAgent.cpp: (WebCore::InspectorMemoryAgent::create): (WebCore): * inspector/InspectorMemoryAgent.h: (InspectorMemoryAgent): 2013-04-23 Zoltan Horvath [CSS Exclusions] shape-inside overflow should be pushed to the outside of the content box https://bugs.webkit.org/show_bug.cgi?id=114526 Reviewed by David Hyatt. The specification has changed to define shape-outside as the inverse of an exclusion. Overflowing content should not overlap the shape, and it should be pushed outside the content box. This change affects several tests, but only one new has been added. In this change I'm not intended to include the behavior change for shape-inside on CSS Regions, I'm going to fix that in a follow up patch. Tests: fast/exclusions/shape-inside/shape-inside-overflow-fixed-dimensions.html: Modified. fast/exclusions/shape-inside/shape-inside-bottom-edge.html: Modified. fast/exclusions/shape-inside/shape-inside-empty.html: Modified. fast/exclusions/shape-inside/shape-inside-overflow-fixed-dimensions.html: Added. fast/exclusions/shape-inside/shape-inside-overflow.html: Modified. fast/exclusions/shape-inside/shape-inside-percentage.html: Modified. fast/exclusions/shape-inside/shape-inside-rounded-rectangle-004.html: Modified. * rendering/ExclusionShapeInfo.h: (WebCore::ExclusionShapeInfo::clearSegments): Shape-outside's code uses shape-inside codepaths, when that happens we need to provide a way to reset the m_segments member. (WebCore::ExclusionShapeInfo::shapeContainingBlockHeight): The containing block's height is stored in m_shapeLogicalHeight, I added a function to get this value when we need it to calculate the content box's bottom position. (ExclusionShapeInfo): (WebCore::ExclusionShapeInfo::lineOverlapsShapeBounds): (WebCore::ExclusionShapeInfo::lineWithinShapeBounds): Add function to test whether a whole line is within a shape or not. * rendering/RenderBlockLineLayout.cpp: (WebCore::RenderBlock::layoutRunsAndFloatsInRange): Overflowing content should start under the content box. (WebCore::RenderBlock::LineBreaker::nextLineBreak): Since we use shape-inside codepaths for shape-outside in layoutRunsAndFloatsInRange function and for shape-outside is not a requirement to check the line's bottom position is within the shape we might end up with some extra segments here. In this case we should clear segments, since we don't want to apply any horizontal offsets on the overflowing content. 2013-04-23 Antti Koivisto Avoid computing style twice when element has no existing style https://bugs.webkit.org/show_bug.cgi?id=115042 Reviewed by Andreas Kling. We currently compute element style twice if we end up having to reattach, first in recalcStyle and then again during attach(). We can easily avoid this in common case where the element has no existing style (usually because it is display:none). * dom/Element.cpp: (WebCore::Element::recalcStyle): Don't compute the style and diff if there is no existing style. There is nothing to diff against. Instead just call reattach() directly, we ended up doing that anyway with the existing code. 2013-04-23 Lamarque V. Souza WebSocket: Return type of send() should be void if hybi-10 protocol is chosen https://bugs.webkit.org/show_bug.cgi?id=65850 Reviewed by Alexey Proskuryakov. WebSocket API draft changed the return type of send() from boolean to void based on Simon Pieters' post to WHATWG. Firefox 8 and IE 10 already follow the specification, hence it should make sense for us to do the same when hybi protocol is used. Original patch by Yuta Kitamura Tests: http/tests/websocket/tests/hybi/bufferedAmount-after-close.html (updated) http/tests/websocket/tests/hybi/send-after-close-on-unload.html (updated) * Modules/websockets/WebSocket.cpp: (WebCore::WebSocket::send): * Modules/websockets/WebSocket.h: * Modules/websockets/WebSocket.idl: 2013-04-23 Carlos Garcia Campos ScrollbarThemeComposite depends on Page/FrameView/ChromeClient https://bugs.webkit.org/show_bug.cgi?id=21361 Reviewed by Andreas Kling. Remove unused header includes. * platform/ScrollbarThemeComposite.cpp: 2013-04-23 Carlos Garcia Campos [GTK] Add webkit_uri_request_get_http_headers to WebKit2 GTK+ API https://bugs.webkit.org/show_bug.cgi?id=112160 Reviewed by Andreas Kling. * platform/network/soup/GOwnPtrSoup.cpp: (WTF::SoupMessageHeaders): Add freeOwnedGPtr implementation for SoupMessageHeaders. (WTF): * platform/network/soup/GOwnPtrSoup.h: (WTF): * platform/network/soup/ResourceRequest.h: (ResourceRequest): * platform/network/soup/ResourceRequestSoup.cpp: (WebCore::ResourceRequest::updateSoupMessageHeaders): New function to update the given SoupMessageHeaders with the ResourceRequest headers. (WebCore::ResourceRequest::updateFromSoupMessageHeaders): New function to update the ResourceRequest headers with the given SoupMessageHeaders. (WebCore::ResourceRequest::updateSoupMessage): Use updateSoupMessageHeaders() to update the headers. (WebCore::ResourceRequest::toSoupMessage): Ditto. (WebCore::ResourceRequest::updateFromSoupMessage): Use updateFromSoupMessageHeaders to update the headers. 2013-04-23 Andreas Kling Clear StyleResolver state before returning from styleForElement(). Reviewed by Antti Koivisto. From Blink r148687 by . A cached element pointer in the resolver state was causing confusion because in some cases a subsequent call to styleForElement() would use a pointer to a different object that is at the same memory address as the previous one. Test: fast/css/reload-non-styled-element-crash.html * css/StyleResolver.cpp: (WebCore::StyleResolver::styleForElement): 2013-04-23 Andreas Kling XSSAuditor performance regression due to threaded parser changes. Reviewed by Anders Carlsson. From Blink r148792 by : The refactoring we did for the threaded parser introduced a performance regression in innerHTML because we'd boot up the XSSAuditor for fragment parsing. This CL returns to our earlier behavior of not booting up the XSSAuditor when parsing fragments. * html/parser/HTMLDocumentParser.cpp: (WebCore::HTMLDocumentParser::HTMLDocumentParser): * html/parser/XSSAuditor.cpp: (WebCore::XSSAuditor::initForFragment): * html/parser/XSSAuditor.h: (XSSAuditor): 2013-04-23 Andreas Kling Speed up ElementData::getAttributeItem(), which is hot. Reviewed by Antti Koivisto. From Blink r148622 by . The previous version had a couple of issues: - Incurred new WTF::Vector::operator[] checks. - Had a branch in _every_ loop iteration that checked whether the storage was Vector or array[] backed. Both these issues are fixed, and CloneNodes.html seems reliably at +2%. I also believe GetElement.html is maybe +1%. For WebKit, also applied the same optimization to getAttributeItemIndex(). * dom/Element.h: (WebCore::ElementData::attributeBase): (WebCore::ElementData::getAttributeItemIndex): (WebCore::ElementData::getAttributeItem): (WebCore::ElementData::attributeItem): 2013-04-23 Antoine Quint Initial advance of text runs should be taken into account https://bugs.webkit.org/show_bug.cgi?id=114949 Reviewed by Darin Adler. Keep track of complex text runs' initial advance by adding a new member to GlyphBuffer and adding the initial advance of any non-first text run to the advance of the last glyph added for the previous text run. Additionally, we now correctly handle advance values in the y-axis. Test: fast/text/complex-initial-advance.html * WebCore.exp.in: Add support for new WebKitSystemInterface API. * platform/graphics/FontFastPath.cpp: (WebCore::Font::drawGlyphBuffer): Take into account the buffer's initial advance in the y-axis to adjust the point at which to draw the buffers. Additionally, keep track of advances on the y-axis as well as the x-axis (which we already were doing) as we iterate through glyphs and adjust the start point. (WebCore::Font::drawEmphasisMarks): Adopt change of GlyphBuffer::advanceAt() return type. * platform/graphics/GlyphBuffer.h: Removing the WINCE-specific GlyphBufferAdvance struct since heights are now necessary. (WebCore::GlyphBufferAdvance::GlyphBufferAdvance): New default constructor for GlyphBufferAdvance to support the m_initialAdvance member. (WebCore::GlyphBuffer::setInitialAdvance): (WebCore::GlyphBuffer::initialAdvance): New APIs to get and set the initial advance for a glyph buffer. (WebCore::GlyphBuffer::advanceAt): Return a GlyphBufferAdvance rather than a float which used to be only the glyph buffer's x-axis advance. This is necessary to handle deltas on the y-axis as well (see WebCore::Font::drawGlyphBuffer). * platform/graphics/GlyphBuffer.h: (GlyphBuffer): (WebCore::GlyphBuffer::setInitialAdvance): * platform/graphics/WidthIterator.cpp: (WebCore::WidthIterator::advanceInternal): (WebCore::WidthIterator::advanceOneCharacter): Adopt change of GlyphBuffer::advanceAt() return type. * platform/graphics/cairo/FontCairo.cpp: (WebCore::Font::drawGlyphs): Adopt change of GlyphBuffer::advanceAt() return type. * platform/graphics/mac/ComplexTextController.cpp: (WebCore::ComplexTextController::advance): When processing the first text run, set that run's initial advance as the glyph buffer's initial advance. (WebCore::ComplexTextController::adjustGlyphsAndAdvances): Represent the initial advance for a text run by adjusting the advance of the last glyph of the previous text run in the glyph buffer. * platform/graphics/mac/ComplexTextController.h: (WebCore::ComplexTextController::ComplexTextRun::initialAdvance): (ComplexTextRun): New API to read the inital advance of a complex text run. * platform/graphics/mac/ComplexTextControllerCoreText.mm: (WebCore::ComplexTextController::ComplexTextRun::ComplexTextRun): Obtain the text run's initial advance via the new wkCTRunGetInitialAdvance WebKitSystemInterface API. * platform/graphics/qt/FontQt.cpp: (WebCore::Font::drawGlyphs): Adopt change of GlyphBuffer::advanceAt() return type. * platform/mac/WebCoreSystemInterface.h: * platform/mac/WebCoreSystemInterface.mm: Add support for the new wkCTRunGetInitialAdvance WebKitSystemInterface API. * platform/wx/wxcode/cairo/non-kerned-drawing.cpp: (WebCore::drawTextWithSpacing): Adopt change of GlyphBuffer::advanceAt() return type. * rendering/svg/SVGTextRunRenderingContext.cpp: (WebCore::SVGTextRunRenderingContext::drawSVGGlyphs): Adopt change of GlyphBuffer::advanceAt() return type. 2013-04-23 Noam Rosenthal [Texmap] Don't paint to an intermediate surface when the result is going to be clipped out completely. https://bugs.webkit.org/show_bug.cgi?id=115015 Reviewed by Allan Sandfeld Jensen. Maintain a clipBounds rectangle in TextureMapper, and test it against the bounds of an intermediate surface before it is painted. This allows us to opt out completely of painting into the surface if the result is going to be optimized out by the GPU clipping. Covered by tests in compositing/overlap-blending. * platform/graphics/texmap/TextureMapper.h: (TextureMapper): * platform/graphics/texmap/TextureMapperGL.cpp: (WebCore::TextureMapperGL::clipBounds): (WebCore): * platform/graphics/texmap/TextureMapperGL.h: * platform/graphics/texmap/TextureMapperImageBuffer.h: * platform/graphics/texmap/TextureMapperLayer.cpp: (WebCore::TextureMapperLayer::paintUsingOverlapRegions): 2013-04-23 Noam Rosenthal [Coordinated Graphics] Remove the lockAnimations code path https://bugs.webkit.org/show_bug.cgi?id=114899 Reviewed by Benjamin Poulain. Remove locking/unlocking animations and checks for the lock state. The animation locking has been tested to create not-so-smooth animations, while the use case where the composited animations run out of sync from the non-composited animations is very rare and unnoticeable. No new tests, removing functionality that wasn't tested in the first place. * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp: (WebCore::CoordinatedGraphicsScene::CoordinatedGraphicsScene): (WebCore::CoordinatedGraphicsScene::paintToCurrentGLContext): (WebCore::CoordinatedGraphicsScene::commitSceneState): * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h: (CoordinatedGraphicsScene): 2013-04-23 Allan Sandfeld Jensen Respect image-rendering setting for determing image-rendering quality https://bugs.webkit.org/show_bug.cgi?id=113405 Reviewed by Benjamin Poulain. Remove the CSS4 values as they are not ready for implementation yet. We still parse the -webkit-crisp-edges and SVG compatibility values to be closer to the the partial support in Gecko and Presto. Tests: fast/css/image-rendering-canvas.html fast/css/image-rendering-parsing.html fast/css/image-rendering.html fast/css/optimize-contrast-image.html * css/CSSParser.cpp: (WebCore::isValidKeywordPropertyAndValue): * css/CSSPrimitiveValueMappings.h: (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): (WebCore::CSSPrimitiveValue::operator EImageRendering): * css/CSSValueKeywords.in: * css/SVGCSSParser.cpp: (WebCore::CSSParser::parseSVGValue): * rendering/RenderBoxModelObject.cpp: (WebCore::ImageQualityController::shouldPaintAtLowQuality): * rendering/RenderHTMLCanvas.cpp: (WebCore::RenderHTMLCanvas::paintReplaced): * rendering/style/RenderStyleConstants.h: 2013-04-23 Commit Queue Unreviewed, rolling out r148923. http://trac.webkit.org/changeset/148923 https://bugs.webkit.org/show_bug.cgi?id=115020 The patch causes multiple failures in CSS, canvas tests (Requested by zdobersek on #webkit). * platform/graphics/cairo/PlatformContextCairo.cpp: (WebCore::PlatformContextCairo::drawSurfaceToContext): 2013-04-22 Noam Rosenthal [EFL] Assertion Failures in Coordinated Graphics after r148433 https://bugs.webkit.org/show_bug.cgi?id=114731 Reviewed by Gyuyoung Kim. The assert is incorrect. In some cases in coordinated graphics we may have a backing store and drawsContent would be set to false. No new tests. * platform/graphics/texmap/TextureMapperLayer.cpp: (WebCore::TextureMapperLayer::paintSelf): 2013-04-22 Suchit Agrawal table's text aligned on top instead of center because of rowspan https://bugs.webkit.org/show_bug.cgi?id=18092 Reviewed by Beth Dakin. Last row in the rowspan is not getting the height of rowspan cell because there is not enough rows present below rowspan cell and we are strictly applying height of rowspan to the row which should lay last in the rowspan based of rowspan value. When row contains rowspan cell and it is last row of the table then rowspan height is adding to last row of the table. Test: fast/table/Rowspan-value-more-than-number-of-rows-present.html It calculates logical height of the rows in the table. * rendering/RenderTableSection.cpp: (WebCore::RenderTableSection::calcRowLogicalHeight): 2013-04-22 Mihnea Ovidenie [CSS Regions] Region's float parent doesn't size according to region size but to content node size https://bugs.webkit.org/show_bug.cgi?id=111332 Reviewed by David Hyatt. Tests: fast/regions/intrinsic-sized-regions.html fast/regions/region-with-float-parent.html The patch ensures that the computation of region's preferred widths takes into account the region width/min-width if these values are specified. Also implemented the computation of intrinsic widths for a region, based on the min/max preferred widths of the associated flow thread. * rendering/RenderRegion.cpp: (WebCore::RenderRegion::computeIntrinsicLogicalWidths): (WebCore): (WebCore::RenderRegion::computePreferredLogicalWidths): * rendering/RenderRegion.h: (RenderRegion): 2013-04-22 Jessie Berlin Debug build fix. Rubber-stamped by Ryosuke Niwa. * inspector/InspectorController.cpp: (WebCore::InspectorController::InspectorController): * inspector/InspectorMemoryAgent.cpp: (WebCore::InspectorMemoryAgent::InspectorMemoryAgent): * inspector/InspectorMemoryAgent.h: (WebCore): (WebCore::InspectorMemoryAgent::create): (InspectorMemoryAgent): 2013-04-22 Brady Eidson Address review feedback I forgot to address in r148929 https://bugs.webkit.org/show_bug.cgi?id=114480 * loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::willSendRequest): Rework the "what" comment into a more useful "why" comment. 2013-04-22 Benjamin Poulain Second Mac debug build fix after r148921 Unreviewed. * inspector/InspectorMemoryAgent.cpp: (WebCore::InspectorMemoryAgent::InspectorMemoryAgent): * inspector/InspectorMemoryAgent.h: (InspectorMemoryAgent): 2013-04-22 Brady Eidson REGRESSION (r141136): Wiki "Random article" function very broken. and https://bugs.webkit.org/show_bug.cgi?id=114480 Reviewed by Alexey Proskuryakov. Test: http/tests/navigation/redirect-to-random-url-versus-memory-cache.html If we are performing a conditional GET to revalidate a resource and there's a redirect, check to see if the redirect is to a different URL than the final URL of the resource. If the URLs differ then we should make the redirect-request unconditional and do a normal load. * loader/SubresourceLoader.cpp: (WebCore::SubresourceLoader::willSendRequest): * platform/network/ResourceRequestBase.cpp: (WebCore::ResourceRequestBase::makeUnconditional): * platform/network/ResourceRequestBase.h: (ResourceRequestBase): 2013-04-22 Benjamin Poulain Mac debug build fix after r148921 Unreviewed. * page/animation/CompositeAnimation.cpp: 2013-04-22 Rashmi Shyamasundar [Cairo] Canvas-shadow behavior is not being as expected https://bugs.webkit.org/show_bug.cgi?id=108897 Reviewed by Martin Robinson. Use the pattern-extend-mode "CAIRO_EXTEND_NONE" instead of "CAIRO_EXTEND_PAD" in PlatformContextCairo::drawSurfaceToContext(). In the function PlatformContextCairo::drawSurfaceToContext(), a pattern is being created from the source surface and this pattern is drawn onto the destination context. There is no gradient involved. Hence the extend mode for filling the pattern should be "CAIRO_EXTEND_NONE". If we use the extend mode "CAIRO_EXTEND_PAD" in PlatformContextCairo::drawSurfaceToContext(), the original image area is also filled with the shadow color which is not the expected behavior. Test: fast/canvas/canvas-image-shadow.html * platform/graphics/cairo/PlatformContextCairo.cpp: (WebCore::PlatformContextCairo::drawSurfaceToContext): 2013-04-22 Benjamin Poulain Remove the memory instrumentation code https://bugs.webkit.org/show_bug.cgi?id=114931 Reviewed by Andreas Kling. The Memory Instrumentation code is unfinished and has already become out of sync the objects it is supposed to represent. The current approach does not seem maintainable, it is better to remove it before someone gets hurt. By removing the code, the binary become 1240976 bytes smaller. Yep, almost 1 Mb, bringing WebCore to the size it has 5 months ago :) * MostWebCoreFiles: remove the support for memory instrumentation. 2013-04-22 Bear Travis Do not reuse ExclusionShapeInsideInfo in a recursive region layout https://bugs.webkit.org/show_bug.cgi?id=114467 Reviewed by David Hyatt. Elements that respect shape-inside that have inline children should not reuse an ExclusionShapeInsideInfo for their children's layout. This patch adds the test for regions. See the details for non-region layout in bug 104582. https://bugs.webkit.org/show_bug.cgi?id=104582 Test: fast/regions/shape-inside/shape-inside-recursive-layout.html * rendering/RenderBlockLineLayout.cpp: (WebCore::RenderBlock::layoutExclusionShapeInsideInfo): Do not look up a region's ExclusionShapeInsideInfo if a block is already respecting shape-inside. 2013-04-22 Martin Robinson [GTK] Fix remaining introspection warnings https://bugs.webkit.org/show_bug.cgi?id=114980 Reviewed by Gustavo Noronha Silva. * bindings/gobject/WebKitDOMCustom.h: Add scope and transfer annotations and flesh out gtkdoc for completeness. * bindings/gobject/WebKitDOMEventTarget.h: (_WebKitDOMEventTargetIface): Ditto and also align virtual method names with those used for the concrete ones. 2013-04-22 Tim Horton PDFPlugin: Support unlocking encrypted PDFs https://bugs.webkit.org/show_bug.cgi?id=114938 Reviewed by Alexey Proskuryakov. Export HTMLNames::typeAttr. * WebCore.exp.in: 2013-04-22 Ryosuke Niwa Use-after-free in CompositeEditCommand::cloneParagraphUnderNewElement https://bugs.webkit.org/show_bug.cgi?id=114911 Reviewed by Oliver Hunt. Back ported https://src.chromium.org/viewvc/blink?revision=148680&view=revision. * editing/CompositeEditCommand.cpp: (WebCore::CompositeEditCommand::cloneParagraphUnderNewElement): 2013-04-22 Eric Carlson [Mac] "automatic" track selection should only select a track that matches user language https://bugs.webkit.org/show_bug.cgi?id=114976 Reviewed by Jer Noble. Test: media/track/track-automatic-subtitles.html * page/CaptionUserPreferencesMac.mm: (WebCore::CaptionUserPreferencesMac::textTrackSelectionScore): When in "automatic" mode, only consider text tracks that match the user's preferred language when the primary audio track does not. 2013-04-22 Jer Noble Cancelling load may cause deadlock in -[AVPlayerItem release] https://bugs.webkit.org/show_bug.cgi?id=114962 Reviewed by Eric Carlson. Work around a bug in AVAssetResourceLoader by using a generic, non-main dispatch queue to recieve AVAssetResourceLoaderDelegate callbacks, and then marshalling those callbacks to the main thread asynchronously. * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::globalLoaderDelegateQueue): Added. (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Use the new global queue. (-[WebCoreAVFLoaderDelegate resourceLoader:shouldWaitForLoadingOfRequestedResource:]): Marshall the request to the main queue, and return YES (wait) immediately. 2013-04-22 Zan Dobersek [GTK] Set up libPlatform.la https://bugs.webkit.org/show_bug.cgi?id=114168 Reviewed by Martin Robinson. No new tests - no new functionality. * GNUmakefile.am: Also add the LevelDB-specific cppflags to the platform_cppflags if required as the LevelDB code is now built into the new libPlatform.la library. * GNUmakefile.list.am: Build a small set of non-GTK-specific platform source files that are already free of platform violations into the new libPlatform.la library. 2013-04-22 Andy Estes Range.getClientRects() should not include rects for partially selected elements https://bugs.webkit.org/show_bug.cgi?id=76839 Reviewed by Sam Weinig. CSSOM says that Range.getClientRects() should include the border boxes of each element selected by the range. However, we were also incorrectly including border boxes for partially selected elements. For instance, consider the following selection:
line one
line two
------------- The
is two lines tall, but only the first line is selected. Despite this, we'd include the
's border box since its start tag was included in the selection. Fix this by excluding partially selected elements. This is accomplished by skipping over elements that come after the start boundary point of the range but are ancestors of the end boundary point. Added test cases to LayoutTests/fast/dom/Range/getClientRects.html. * dom/Range.cpp: (WebCore::Range::getBorderAndTextQuads): 2013-04-22 Yi Shen Crash on OS X when shift clicking outside of input https://bugs.webkit.org/show_bug.cgi?id=104058 Reviewed by Chang Shu. Shift clicking outside of a focused div while removing the focused div from the dom tree at the same time may hit a null visible position, which should not be used to calculate the text distance with the new selection's start and end position. Otherwise, the browser may crash. Test: editing/selection/crash-on-shift-click.html * page/EventHandler.cpp: (WebCore::EventHandler::handleMousePressEventSingleClick): 2013-04-22 Carlos Garcia Campos Scrollbar should not depend on EventHandler, Frame and FrameView https://bugs.webkit.org/show_bug.cgi?id=114941 Reviewed by Darin Adler. It's a layering violation that Scrollbar uses EventHandler, Frame and FrameView. Frame is used to get the EventHandler that is used to set mousePressed to false after a Scrollbar::mouseUp(). This is not really needed, since EventHandler already sets m_mousePressed to false when calling Scrollbar::mouseUp(). The PopupMenu windows implementation also calls Scrollbar::mouseUp(), but that scrollbar is not inside a FrameView. * platform/Scrollbar.cpp: (WebCore::Scrollbar::isScrollViewScrollbar): isScrollViewScrollbar() is a method of ScrollView so we don't need to cast to FrameView. (WebCore::Scrollbar::mouseUp): Remove EventHandler ussage. 2013-04-22 Andreas Kling Shrink baseline size of WTF::Vector on 64-bit by switching to unsigned capacity and size. Reviewed by Sam Weinig. * CMakeLists.txt: Add a workaround for GCC 4.6.x in Release mode so it does not crash. 2013-04-22 John Griggs [BlackBerry] URL decode data: URLs before passing to the platform media player. https://bugs.webkit.org/show_bug.cgi?id=114887 Reviewed by Rob Buis. Pass data URL through URL decoding before passing to platform media player. PR 313635. Reviewed internally by Liam Quinn * platform/graphics/blackberry/MediaPlayerPrivateBlackBerry.cpp: (WebCore::MediaPlayerPrivate::load): 2013-04-22 Xuefei Ren fix build warning(unused parameter) https://bugs.webkit.org/show_bug.cgi?id=114855 Reviewed by Rob Buis. remove warning(unused parameter) in Source/WebCore/platform/graphics/blackberry * platform/graphics/blackberry/CanvasLayerWebKitThread.cpp: (WebCore::CanvasLayerCompositingThreadClient::drawTextures): (WebCore::CanvasLayerCompositingThreadClient::deleteTextures): (WebCore::CanvasLayerCompositingThreadClient::commitPendingTextureUploads): * platform/graphics/blackberry/FontBlackBerry.cpp: (WebCore::Font::offsetForPositionForComplexText): * platform/graphics/blackberry/FontCacheBlackBerry.cpp: (WebCore::FontCache::getSimilarFontPlatformData): (WebCore::FontCache::getTraitsInFamily): * platform/graphics/blackberry/GlyphPageTreeNodeBlackBerry.cpp: (WebCore::GlyphPage::fill): * platform/graphics/blackberry/GraphicsContext3DBlackBerry.cpp: (WebCore::GraphicsContext3D::ImageExtractor::extractImage): * platform/graphics/blackberry/GraphicsContextBlackBerry.cpp: (WebCore::GraphicsContext::drawConvexPolygon): (WebCore::GraphicsContext::fillRect): (WebCore::GraphicsContext::fillRoundedRect): (WebCore::GraphicsContext::roundToDevicePixels): (WebCore::GraphicsContext::setPlatformShadow): (WebCore::GraphicsContext::clipConvexPolygon): (WebCore::GraphicsContext::setURLForRect): (WebCore::GraphicsContext::setPlatformStrokeColor): (WebCore::GraphicsContext::setPlatformFillColor): (WebCore::GraphicsContext::setPlatformCompositeOperation): * platform/graphics/blackberry/ImageBlackBerry.cpp: (WebCore::BitmapImage::draw): (WebCore::Image::drawPattern): * platform/graphics/blackberry/ImageBufferBlackBerry.cpp: (WebCore::flushAndDraw): (WebCore::ImageBuffer::ImageBuffer): (WebCore::ImageBuffer::copyImage): (WebCore::ImageBuffer::draw): (WebCore::ImageBuffer::platformTransformColorSpace): * platform/graphics/blackberry/LayerTiler.cpp: (WebCore::LayerTiler::drawTile): * platform/graphics/blackberry/PathBlackBerry.cpp: (WebCore::GraphicsContext::drawFocusRing): (WebCore::GraphicsContext::clipPath): * platform/graphics/blackberry/PatternBlackBerry.cpp: (WebCore::Pattern::platformPattern): 2013-04-22 Mike Fenton [BlackBerry] Add additional datalist support. https://bugs.webkit.org/show_bug.cgi?id=114883 Reviewed by Rob Buis. PR 210083. Extend support for datalist to include all non-popup input types. Re-enabling fast/forms/datalist/input-list Internally Reviewed by Otto Cheung. * platform/blackberry/RenderThemeBlackBerry.cpp: (WebCore::RenderThemeBlackBerry::supportsDataListUI): 2013-04-22 Alberto Garcia [BlackBerry] Add dummy implementations of DragData::droppedFileSystemId() https://bugs.webkit.org/show_bug.cgi?id=114861 Reviewed by Carlos Garcia Campos. * platform/blackberry/DragDataBlackBerry.cpp: (WebCore): (WebCore::DragData::droppedFileSystemId): 2013-04-22 Mihai Maerean [CSS Regions] Elements in a region should be assignable to a named flow https://bugs.webkit.org/show_bug.cgi?id=74144 Reviewed by David Hyatt. DOM children of a region must not be rendered as children of the region, but can be collected in flow threads. NodeRenderingContext::parentRenderer now creates the parent render flow thread if it doesn't exist. Element::moveToFlowThreadIsNeeded is a virtual method that is overriden in PseudoElement to return false and in SVGElement so only svg root elements can directly be collected by a render flow thread. RenderObject::canDOMChildrenHaveRenderParent exists to optimize the code so nodes inside regions (and maybe other types of renderers in the future) can still have renderers if they need to be in a flow thread while the rest of renderers that can't have children skip the new instructions. Tests: fast/regions/flow-body-in-html.html . To test the duplicate bug #103685. fast/regions/region-content-flown-into-region.html fast/regions/universal-selector-children-to-the-same-region.html . To test the duplicate bug #103685. * dom/Element.cpp: (WebCore::Element::moveToFlowThreadIsNeeded): * dom/Element.h: * dom/NodeRenderingContext.cpp: (WebCore::NodeRenderingContext::parentRenderer): the renderer that will be the parent for this node's renderer. In the case of RenderFlowThreads, it may need to create it. (WebCore::NodeRenderingContext::shouldCreateRenderer): In a region, only the children that need to be in a flow thread should have a renderer. (WebCore::NodeRenderingContext::moveToFlowThreadIfNeeded): (WebCore::NodeRenderingContext::moveToFlowThread): * dom/NodeRenderingContext.h: (NodeRenderingContext): * dom/PseudoElement.h: pseudo-elements cannot be directly collected into a named flow. * dom/Text.cpp: (WebCore::Text::textRendererIsNeeded): (WebCore::Text::updateTextRenderer): Because calling textRendererIsNeeded(NodeRenderingContext(...)) on a non-const l-value NodeRenderingContext cannot be done on a temporary object on the stack. * dom/Text.h: * rendering/FlowThreadController.cpp: (WebCore::FlowThreadController::isContentNodeRegisteredWithAnyNamedFlow): * rendering/FlowThreadController.h: * rendering/RenderObject.h: (WebCore::RenderObject::canDOMChildrenHaveRenderParent): Even if this render object can't have render children, the children in the DOM tree may have a render parent (that is different from this render object). * rendering/RenderRegion.h: * svg/SVGElement.cpp: (WebCore::SVGElement::moveToFlowThreadIsNeeded): Allow only svg root elements to be directly collected by a render flow thread. * svg/SVGElement.h: 2013-04-22 Alberto Garcia Gradient: add PlatformGradient definition for BlackBerry https://bugs.webkit.org/show_bug.cgi?id=114727 Reviewed by Carlos Garcia Campos. * platform/graphics/Gradient.h: (Graphics): 2013-04-22 Andrei Bucur Use DOM ordering for list counts https://bugs.webkit.org/show_bug.cgi?id=110352 Reviewed by Elliott Sprehn. Currently the list items ordering is made by traversing the render tree. This gives bad results for: - list items flown inside regions because they are not rendered as descendants of their DOM list ancestors. - list items matched to insertion points inside a shadow tree. The insertion point may be a child of a list so the numbering gets broken. To implement correct DOM ordering I've taken into account the fact that pseudo-elements can have display: list-item so they should be included when traversing the DOM tree. I've added helper methods on the NodeTraversal namespace that should allow easily traversing the tree including the pseudo-elements (e.g. firstChildWithPseudo for an element with pseudo-before will return the before PseudoElement). Using these helper methods I've implemented pre-order traversal methods aware of the pseudo-elements. An effect of this change is how the list items inside shadow tree update their counting. With the patch, if there's no
    or