2013-12-18 Carlos Garcia Campos Unreviewed. Fix make distcheck. * GNUmakefile.am: * GNUmakefile.list.am: 2013-12-18 Dániel Bátyai [soup] Fix unused parameter warnings in ResourceHandleSoup. https://bugs.webkit.org/show_bug.cgi?id=125918 Reviewed by Martin Robinson. Comment out the method parameters to avoid the warnings. No tests required. * platform/network/soup/ResourceHandleSoup.cpp: (WebCore::WebCoreSynchronousLoader::didReceiveData): 2013-12-17 Jer Noble [MSE] Periodically monitor source buffers. https://bugs.webkit.org/show_bug.cgi?id=125898 Reviewed by Eric Carlson. Test: media/media-source/media-source-monitor-source-buffers.html The MSE spec requires that the SourceBuffer Monitoring step is run periodically during playback. No specific update interval is specified so we will re-use the existing HTMLMediaElement playback progress timer to signal the media source monitoring. * html/HTMLMediaElement.cpp: (HTMLMediaElement::playbackProgressTimerFired): 2013-12-17 Jer Noble [MSE] Add per-track signalling between SourceBuffer and SourceBufferPrivate. https://bugs.webkit.org/show_bug.cgi?id=125899 Reviewed by Eric Carlson. To accommodate the future addition of audio support to MSE in the Mac port, add the concept of trackIDs to the communication between SourceBuffer and SourceBufferPrivate. The following virtual methods now take a trackID parameter: * platform/graphics/SourceBufferPrivate.h: (WebCore::SourceBufferPrivate::isReadyForMoreSamples): (WebCore::SourceBufferPrivate::stopAskingForMoreSamples): (WebCore::SourceBufferPrivate::notifyClientWhenReadyForMoreSamples): * platform/graphics/SourceBufferPrivateClient.h: (WebCore::SourceBufferPrivateClient::sourceBufferPrivateDidBecomeReadyForMoreSamples): Update overridden methods in subclasses: * Modules/mediasource/SourceBuffer.cpp: (WebCore::SourceBuffer::sourceBufferPrivateDidBecomeReadyForMoreSamples): * Modules/mediasource/SourceBuffer.h: * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h: * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::trackDidChangeEnabled): (WebCore::SourceBufferPrivateAVFObjC::isReadyForMoreSamples): * platform/mock/mediasource/MockSourceBufferPrivate.h: Change the logic in provideMediaData to update a single TrackBuffer rather than iterating over all of them: * Modules/mediasource/SourceBuffer.cpp: (WebCore::SourceBuffer::sourceBufferPrivateSeekToTime): (WebCore::SourceBuffer::appendBufferTimerFired): (WebCore::SourceBuffer::provideMediaData): 2013-12-17 Joseph Pecoraro Web Inspector: Remove InspectorAgent::hasFrontend https://bugs.webkit.org/show_bug.cgi?id=125907 Reviewed by Timothy Hatcher. Remove InspectorAgent::hasFrontend only used by InspectorInstrumentation::collectingHTMLParseErrors. However, following the single callers of that, the result is unused in the HTMLDocumentParser and HTMLTreeBuilder. So remove more stale / unused code. * html/FTPDirectoryDocument.cpp: (WebCore::FTPDirectoryDocumentParser::FTPDirectoryDocumentParser): * html/HTMLDocument.cpp: (WebCore::HTMLDocument::createParser): * html/parser/HTMLDocumentParser.cpp: (WebCore::HTMLDocumentParser::HTMLDocumentParser): * html/parser/HTMLDocumentParser.h: (WebCore::HTMLDocumentParser::create): * html/parser/HTMLTreeBuilder.cpp: (WebCore::HTMLTreeBuilder::HTMLTreeBuilder): * html/parser/HTMLTreeBuilder.h: (WebCore::HTMLTreeBuilder::create): * html/parser/TextDocumentParser.cpp: (WebCore::TextDocumentParser::TextDocumentParser): * inspector/DOMPatchSupport.cpp: (WebCore::DOMPatchSupport::patchDocument): * inspector/InspectorAgent.h: * inspector/InspectorInstrumentation.cpp: * inspector/InspectorInstrumentation.h: 2013-12-17 Joseph Pecoraro Web Inspector: Some basic InjectedScriptHost cleanup https://bugs.webkit.org/show_bug.cgi?id=125902 Reviewed by Timothy Hatcher. Remove InjectedScriptHost::scriptDebugServer. Nobody accesses the ScriptDebugServer through the injected script host. This also lets us remove the reference to the DebuggerAgent. * inspector/InjectedScriptHost.cpp: * inspector/InjectedScriptHost.h: (WebCore::InjectedScriptHost::init): * inspector/InspectorController.cpp: (WebCore::InspectorController::InspectorController): * inspector/WorkerInspectorController.cpp: (WebCore::WorkerInspectorController::WorkerInspectorController): 2013-12-17 Joseph Pecoraro Web Inspector: Remove InspectorFrontendHost.setInjectedScriptForOrigin https://bugs.webkit.org/show_bug.cgi?id=125906 Reviewed by Timothy Hatcher. Remove stale code related to a since removed feature, Inspector extensions. This allows us to remove a number of entry points into InspectorAgent. * inspector/InspectorAgent.cpp: (WebCore::InspectorAgent::InspectorAgent): (WebCore::InspectorAgent::willDestroyFrontendAndBackend): * inspector/InspectorAgent.h: (WebCore::InspectorAgent::create): Remove setInjectedScriptForOrigin and InjectedScript management. * inspector/InspectorController.cpp: (WebCore::InspectorController::InspectorController): * inspector/InspectorController.h: * inspector/InspectorFrontendHost.cpp: * inspector/InspectorFrontendHost.h: * inspector/InspectorFrontendHost.idl: Remove the API and calling through InspectorController. * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::didClearWindowObjectInWorldImpl): (WebCore::InspectorInstrumentation::domContentLoadedEventFiredImpl): (WebCore::InspectorInstrumentation::didCommitLoadImpl): Remove now unnecessary calls into InspectorAgent. 2013-12-17 Jer Noble Fix TimeRanges::intersectWith https://bugs.webkit.org/show_bug.cgi?id=118802 Test: TestWebKitAPI/Tests/WebCore/TimeRanges.cpp. Reviewed by Eric Carlson. * WebCore.exp.in: * WebCore.xcodeproj/project.pbxproj: * html/TimeRanges.cpp: (TimeRanges::invert): (TimeRanges::intersectWith): Merge https://chromium.googlesource.com/chromium/blink/+/f557582b6c6283a8b165514f52d01cfd98130e85 2013-12-17 Eric Carlson ASSERT setting pseudoID with registered DOMSubtreeModified listener https://bugs.webkit.org/show_bug.cgi?id=125900 Reviewed by Ryosuke Niwa. Test: fast/dom/attribute-set-before-element-in-tree.html * dom/Node.cpp: (WebCore::Node::dispatchSubtreeModifiedEvent): Return early if the node does not have a parent and does not have a DOMSubtreeModified listener. 2013-12-17 Ryosuke Niwa Remove dead code for reflected attributes from audio, video, and track elements https://bugs.webkit.org/show_bug.cgi?id=125838 Reviewed by Eric Carlson. Merge https://chromium.googlesource.com/chromium/blink/+/310514e2f0fd934975b841d463bad0cd62e6fd64 Where [Reflect] is used in the IDL, the getters and setters in C++ are only for internal convenience, and these were unused. * html/HTMLMediaElement.cpp: * html/HTMLMediaElement.h: * html/HTMLTrackElement.cpp: * html/HTMLTrackElement.h: * html/HTMLVideoElement.cpp: * html/HTMLVideoElement.h: 2013-12-17 Simon Fraser Rename "canRubberBands" to "canRubberBand" https://bugs.webkit.org/show_bug.cgi?id=125897 Reviewed by Anders Carlsson. Rename "canRubberBands" to "canRubberBand" in various places. * page/scrolling/ScrollingTree.cpp: (WebCore::ScrollingTree::setCanRubberBandState): * page/scrolling/ScrollingTree.h: 2013-12-17 Jer Noble [MSE] Update duration after appending samples, per spec. https://bugs.webkit.org/show_bug.cgi?id=125703 Reviewed by Eric Carlson. Test: media/media-source/media-source-duration-after-append.html After appending a sample, update the MediaSource duration if the sample's presentation end time is greater than the existing duration. * Modules/mediasource/SourceBuffer.cpp: (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h: * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm: (WebCore::MediaSourcePrivateAVFObjC::setDuration): Notify the MediaPlayer. 2013-12-17 Jer Noble [MSE][Mac] Null-deref in CMSampleBufferIsRandomAccess(). https://bugs.webkit.org/show_bug.cgi?id=125698 Reviewed by Sam Weinig. If a given CMSampleBufferRef does not have a sample attachments array (which is unlikely, but possible), CMSampleBufferGetAttachmentsArray() will return a null value. Additionally, the CMSampleBuffer documentation states that "samples are assumed to be sync samples by default", so the absence of an attachment array (or the absense of a kCMSampleAttachmentKey_NotSync entry in any of the attachment dictionaries) indicates the sample is sync. * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::CMSampleBufferIsRandomAccess): 2013-12-17 Ryosuke Niwa Video element's width and height content attributes should not influence intrinsic width and height https://bugs.webkit.org/show_bug.cgi?id=125822 Reviewed by Darin Adler. Merge https://chromium.googlesource.com/chromium/blink/+/022ce34efb5b70cb964c3ca29f23c8980ffaef05 The width/height content attributes already influence specified style via HTMLVideoElement::collectStyleForPresentationAttribute, to also influence the intrinsic size has never been part of the spec: http://www.w3.org/TR/2013/WD-html51-20130528/embedded-content-0.html#dom-dim-width The test case passes in Firefox Nightly and IE11 Release Preview, but fails in Opera Presto, which has no default intrinsic size. Test: media/video-intrinsic-width-height.html * rendering/RenderVideo.cpp: (WebCore::RenderVideo::calculateIntrinsicSize): 2013-12-16 Daniel Bates [iOS] Upstream WebCore/html changes https://bugs.webkit.org/show_bug.cgi?id=125765 Reviewed by Darin Adler. * WebCore.xcodeproj/project.pbxproj: * html/Autocapitalize.cpp: Added. * html/Autocapitalize.h: Added. Also, added FIXME comment to forward declare AtomicString once we upstream more of the iOS port. * html/BaseChooserOnlyDateAndTimeInputType.cpp: (WebCore::BaseChooserOnlyDateAndTimeInputType::handleDOMActivateEvent): Opt out of code when building for iOS. * html/BaseDateAndTimeInputType.cpp: (WebCore::BaseDateAndTimeInputType::isKeyboardFocusable): Added; iOS-specific. * html/BaseDateAndTimeInputType.h: * html/FileInputType.cpp: (WebCore::FileInputType::FileInputType): Added iOS-specific code. (WebCore::FileInputType::~FileInputType): Opt out of code when building for iOS. Also, added FIXME comment. (WebCore::FileInputType::requestIcon): Ditto. (WebCore::FileInputType::filesChosen): Added; iOS-specific. (WebCore::FileInputType::displayString): Added; iOS-specific. (WebCore::FileInputType::receiveDroppedFiles): Guarded code with ENABLE(DRAG_SUPPORT). * html/FileInputType.h: * html/FormController.cpp: (WebCore::FormController::formElementsCharacterCount): Added. * html/FormController.h: * html/HTMLAppletElement.cpp: (WebCore::HTMLAppletElement::updateWidget): Opt out of code when building for iOS. * html/HTMLAreaElement.cpp: (WebCore::HTMLAreaElement::computePath): Changed argument datatype from RenderElement* to RenderObject*. Also, added FIXME comment to fix this up once we upstream iOS's DOMUIKitExtensions.{h, mm}. (WebCore::HTMLAreaElement::computeRect): Ditto. * html/HTMLAreaElement.h: * html/HTMLAttributeNames.in: Added attributes ongesture{start, change, end}, autocorrect, autocapitalize, data-youtube-id, onwebkit{currentplaybacktargetiswirelesschanged, playbacktargetavailabilitychanged}, webkit-playsinline, x-webkit-airplay, and x-webkit-wirelessvideoplaybackdisabled. * html/HTMLBodyElement.cpp: (WebCore::HTMLBodyElement::scrollLeft): Added iOS-specific code. (WebCore::HTMLBodyElement::scrollTop): Ditto. * html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::HTMLCanvasElement): Added iOS-specific code and FIXME comment. (WebCore::HTMLCanvasElement::createImageBuffer): Added iOS-specific code. * html/HTMLCanvasElement.h: Added iOS-specific code and FIXME comment. * html/HTMLDocument.cpp: (WebCore::HTMLDocument::HTMLDocument): Added argument isSynthesized (default to false), which is passed through to Document::Document(), to create a synthesized document. * html/HTMLDocument.h: (WebCore::HTMLDocument::createSynthesizedDocument): Added. * html/HTMLElement.cpp: (WebCore::HTMLElement::collectStyleForPresentationAttribute): Added iOS-specific code. (WebCore::populateEventNameForAttributeLocalNameMap): Ditto. (WebCore::HTMLElement::willRespondToMouseMoveEvents): Added; iOS-specific. (WebCore::HTMLElement::willRespondToMouseWheelEvents): Added; iOS-specific. (WebCore::HTMLElement::willRespondToMouseClickEvents): Added; iOS-specific. * html/HTMLElement.h: * html/HTMLFormControlElement.cpp: Added FIXME comment to share more code with class HTMLFormElement. (WebCore::HTMLFormControlElement::autocorrect): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormControlElement::setAutocorrect): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormControlElement::autocapitalizeType): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormControlElement::autocapitalize): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormControlElement::setAutocapitalize): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). * html/HTMLFormControlElement.h: * html/HTMLFormElement.cpp: Added FIXME comment to share more code with class HTMLFormControlElement. (WebCore::HTMLFormElement::submitImplicitly): Modified to code to allow implicit submission of multi-input forms only if Settings::allowMultiElementImplicitSubmission() returns true. Such behavior is expected by older iOS apps. Also, changed datatype of variable submissionTriggerCount from int to unsigned because it represents a non-negative value. (WebCore::HTMLFormElement::autocorrect): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormElement::setAutocorrect): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormElement::autocapitalizeType): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormElement::autocapitalize): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). (WebCore::HTMLFormElement::setAutocapitalize): Added; guarded by PLATFORM(IOS_AUTOCORRECT_AND_AUTOCAPITALIZE). * html/HTMLFormElement.h: * html/HTMLFormElement.idl: Added iOS-specific attributes: autocorrect and autocapitalize. * html/HTMLIFrameElement.h: * html/HTMLInputElement.cpp: (WebCore::HTMLInputElement::displayString): Added; guarded by PLATFORM(IOS). (WebCore::HTMLInputElement::dateType): Added; guarded by PLATFORM(IOS). * html/HTMLInputElement.h: * html/HTMLInputElement.idl: Added iOS-specific attributes: autocorrect and autocapitalize. * html/HTMLLabelElement.cpp: (WebCore::HTMLLabelElement::willRespondToMouseClickEvents): Added iOS-specific code. * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::HTMLMediaElement): Added iOS-specific code and FIXME comment. (WebCore::HTMLMediaElement::~HTMLMediaElement): Added iOS-specific code. (WebCore::HTMLMediaElement::parseMediaPlayerAttribute): Added; iOS-specific. (WebCore::HTMLMediaElement::parseAttribute): Added iOS-specific code. (WebCore::HTMLMediaElement::insertedInto): Ditto. (WebCore::HTMLMediaElement::load): Ditto. (WebCore::HTMLMediaElement::prepareForLoad): Ditto. (WebCore::HTMLMediaElement::autoplay): Ditto. (WebCore::HTMLMediaElement::play): Ditto. (WebCore::HTMLMediaElement::playInternal): Ditto. (WebCore::HTMLMediaElement::pauseInternal): Ditto. (WebCore::HTMLMediaElement::setVolumne): Opt out of code when building for iOS. (WebCore::HTMLMediaElement::setMuted): Ditto. (WebCore::HTMLMediaElement::mediaPlayerTimeChanged): Added iOS-specific code. (WebCore::HTMLMediaElement::updateVolume): Ditto. (WebCore::HTMLMediaElement::updatePlayState): Ditto. (WebCore::HTMLMediaElement::userCancelledLoad): Added iOS-specific code and FIXME comment. (WebCore::HTMLMediaElement::resume): Added iOS-specific comment. See . (WebCore::HTMLMediaElement::deliverNotification): Added iOS-specific code. (WebCore::HTMLMediaElement::getPluginProxyParams): Added iOS-specific code. Also, changed src() to getNonEmptyURLAttribute() in the non-iOS code as their doesn't exist a method called src in this class or its superclasses. (WebCore::HTMLMediaElement::webkitShowPlaybackTargetPicker): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::webkitCurrentPlaybackTargetIsWireless): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::mediaPlayerCurrentPlaybackTargetIsWirelessChanged): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::mediaPlayerPlaybackTargetAvailabilityChanged): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::addEventListener): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::removeEventListener): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::enqueuePlaybackTargetAvailabilityChangedEvent): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLMediaElement::enterFullscreen): Added iOS-specific code. (WebCore::HTMLMediaElement::exitFullscreen): Ditto. (WebCore::HTMLMediaElement::createMediaPlayer): Added ENABLE(IOS_AIRPLAY)-guarded code. (WebCore::HTMLMediaElement::userRequestsMediaLoading): Added; guarded by PLATFORM(IOS). (WebCore::HTMLMediaElement::shouldUseVideoPluginProxy): Use dot operator instead of dereference operator (->) when accessing Document::settings(). (WebCore::HTMLMediaElement::didAddUserAgentShadowRoot): Added ENABLE(PLUGIN_PROXY_FOR_VIDEO)-guarded code. * html/HTMLMediaElement.h: (WebCore::HTMLMediaElement::userGestureRequiredToShowPlaybackTargetPicker): Added; guarded by ENABLE(IOS_AIRPLAY). * html/HTMLMediaElement.idl: Added ENABLE_IOS_AIRPLAY-guarded attributes and functions:webkitCurrentPlaybackTargetIsWireless, onwebkit{currentplaybacktargetiswirelesschanged, playbacktargetavailabilitychanged}, and webkitShowPlaybackTargetPicker(). * html/HTMLMetaElement.cpp: (WebCore::HTMLMetaElement::process): Added iOS-specific code. * html/HTMLObjectElement.cpp: (WebCore::shouldNotPerformURLAdjustment): Added; iOS-specific. (WebCore::HTMLObjectElement::parametersForPlugin): Modified to call shouldNotPerformURLAdjustment() when building for iOS. * html/HTMLPlugInElement.h: * html/HTMLPlugInImageElement.cpp: (WebCore::HTMLPlugInImageElement::createRenderer): Added iOS-specific code. (WebCore::HTMLPlugInImageElement::createShadowIFrameSubtree): Added; iOS-specific. * html/HTMLPlugInImageElement.h: * html/HTMLSelectElement.cpp: (WebCore::HTMLSelectElement::usesMenuList): Added iOS-specific code. (WebCore::HTMLSelectElement::createRenderer): Ditto. (WebCore::HTMLSelectElement::childShouldCreateRenderer): Ditto. (WebCore::HTMLSelectElement::willRespondToMouseClickEvents): Added; iOS-specific. (WebCore::HTMLSelectElement::updateListBoxSelection): Added iOS-specific code. (WebCore::HTMLSelectElement::scrollToSelection): Ditto. (WebCore::HTMLSelectElement::setOptionsChangedOnRenderer): Ditto. (WebCore::HTMLSelectElement::menuListDefaultEventHandler): Opt out of code when building for iOS. (WebCore::HTMLSelectElement::defaultEventHandler): Added iOS-specific code. * html/HTMLSelectElement.h: * html/HTMLTextAreaElement.cpp: (WebCore::HTMLTextAreaElement::willRespondToMouseClickEvents): Added; iOS-specific. * html/HTMLTextAreaElement.h: * html/HTMLTextAreaElement.idl: Added iOS-specific attributes: autocorrect and autocapitalize. * html/HTMLTextFormControlElement.cpp: (WebCore::HTMLTextFormControlElement::select): Added iOS-specific code and FIXME comment. (WebCore::HTMLTextFormControlElement::setSelectionRange): Opt out of code when building for iOS. (WebCore::HTMLTextFormControlElement::hidePlaceholder): Added; guarded by PLATFORM(IOS). (WebCore::HTMLTextFormControlElement::showPlaceholderIfNecessary): Added; guarded by PLATFORM(IOS). * html/HTMLTextFormControlElement.h: * html/HTMLVideoElement.cpp: (WebCore::HTMLVideoElement::createRenderer): Fix up call to HTMLMediaElement::createRenderer(). (WebCore::HTMLVideoElement::parseAttribute): Added iOS-specific code. (WebCore::HTMLVideoElement::supportsFullscreen): Ditto. (WebCore::HTMLVideoElement::webkitWirelessVideoPlaybackDisabled): Added; guarded by ENABLE(IOS_AIRPLAY). (WebCore::HTMLVideoElement::setWebkitWirelessVideoPlaybackDisabled): Added; guarded by ENABLE(IOS_AIRPLAY). * html/HTMLVideoElement.h: * html/HTMLVideoElement.idl: Added ENABLE_IOS_AIRPLAY-guarded attribute: webkitWirelessVideoPlaybackDisabled. * html/ImageDocument.cpp: (WebCore::ImageDocument::createDocumentStructure): Added iOS-specific code. (WebCore::ImageDocument::scale): Ditto. (WebCore::ImageDocument::resizeImageToFit): Ditto. (WebCore::ImageDocument::imageClicked): Ditto. (WebCore::ImageDocument::imageFitsInWindow): Ditto. (WebCore::ImageDocument::windowSizeChanged): Ditto. * html/InputType.cpp: (WebCore::InputType::dateType): Added; guarded by PLATFORM(IOS). (WebCore::InputType::isKeyboardFocusable): Added iOS-specific code. (WebCore::InputType::displayString): Added; guarded by PLATFORM(IOS). * html/InputType.h: * html/PluginDocument.cpp: (WebCore::PluginDocumentParser::createDocumentStructure): Added iOS-specific code. * html/RangeInputType.cpp: (WebCore::RangeInputType::handleTouchEvent): Ditto. (WebCore::RangeInputType::disabledAttributeChanged): Added; iOS-specific. * html/RangeInputType.h: * html/SearchInputType.cpp: (WebCore::SearchInputType::addSearchResult): Opt out of code when building for iOS. * html/TextFieldInputType.cpp: (WebCore::TextFieldInputType::isKeyboardFocusable): Added iOS-specific code. * html/TextFieldInputType.h: * html/WebAutocapitalize.h: Added. * html/canvas/CanvasRenderingContext2D.cpp: (WebCore::CanvasRenderingContext2D::createImageData): Added iOS-specific code. (WebCore::CanvasRenderingContext2D::getImageData): Ditto. * html/parser/HTMLConstructionSite.h: (WebCore::HTMLConstructionSite::isTelephoneNumberParsingEnabled): Added; guarded by PLATFORM(IOS). * html/parser/HTMLParserScheduler.h: (WebCore::HTMLParserScheduler::checkForYieldBeforeToken): Added iOS-specific code. * html/parser/HTMLTreeBuilder.cpp: (WebCore::HTMLTreeBuilder::insertPhoneNumberLink): Added; guarded by PLATFORM(IOS). (WebCore::HTMLTreeBuilder::linkifyPhoneNumbers): Added; guarded by PLATFORM(IOS). (WebCore::disallowTelephoneNumberParsing): Added; guarded by PLATFORM(IOS). (WebCore::shouldParseTelephoneNumbersInNode): Added; guarded by PLATFORM(IOS). (WebCore::HTMLTreeBuilder::processCharacterBufferForInBody): Added iOS-specific code. * html/parser/HTMLTreeBuilder.h: * html/shadow/MediaControlElements.cpp: (WebCore::MediaControlClosedCaptionsTrackListElement::MediaControlClosedCaptionsTrackListElement): Guarded member initialization of m_controls with ENABLE(VIDEO_TRACK). Also added UNUSED_PARAM(event) when building with VIDEO_TRACK disabled. (WebCore::MediaControlClosedCaptionsTrackListElement::defaultEventHandler): Added UNUSED_PARAM(event) when building with VIDEO_TRACK disabled. * html/shadow/MediaControls.h: * html/shadow/SliderThumbElement.cpp: (WebCore::SliderThumbElement::SliderThumbElement): Added iOS-specific code. (WebCore::SliderThumbElement::dragFrom): Opt out of code when building for iOS. (WebCore::SliderThumbElement::willDetachRenderers): Added iOS-specific code. (WebCore::SliderThumbElement::exclusiveTouchIdentifier): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::setExclusiveTouchIdentifier): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::clearExclusiveTouchIdentifier): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::findTouchWithIdentifier): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::handleTouchStart): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::handleTouchMove): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::handleTouchEndAndCancel): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::didAttachRenderers): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::handleTouchEvent): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::shouldAcceptTouchEvents): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::registerForTouchEvents): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::unregisterForTouchEvents): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). (WebCore::SliderThumbElement::disabledAttributeChanged): Added; guarded by ENABLE(TOUCH_EVENTS) && PLATFORM(IOS). * html/shadow/SliderThumbElement.h: * html/shadow/TextControlInnerElements.cpp: (WebCore::SearchFieldResultsButtonElement::defaultEventHandler): Opt out of code when building for iOS. * html/shadow/TextControlInnerElements.h: * page/Settings.in: Added setting allowMultiElementImplicitSubmission to enable/disable multi-input implicit form submission (disabled by default). Also added FIXME comment to rename this setting to allowMultiElementImplicitFormSubmission once we upstream the iOS changes to WebView.mm. 2013-12-17 Brady Eidson DatabaseProcess: Pipe through object store IDs and transaction mode for "openTransaction" https://bugs.webkit.org/show_bug.cgi?id=125872 Reviewed by Alexey Proskuryakov. Make these enums into enum classes. Add const maximums for each enum class that might be serialized to allow for conversion later: * Modules/indexeddb/IndexedDB.h: Add cross-thread copying for these new enum classes. * platform/CrossThreadCopier.cpp: (WebCore::::copy): * platform/CrossThreadCopier.h: Adopt the new enum classes throughout the rest of WebCore: * Modules/indexeddb/IDBCursor.cpp: (WebCore::IDBCursor::continueFunction): (WebCore::IDBCursor::stringToDirection): (WebCore::IDBCursor::directionToString): * Modules/indexeddb/IDBCursor.h: * Modules/indexeddb/IDBCursorBackend.cpp: (WebCore::IDBCursorBackend::deleteFunction): * Modules/indexeddb/IDBCursorBackend.h: (WebCore::IDBCursorBackend::value): * Modules/indexeddb/IDBDatabaseBackend.cpp: (WebCore::IDBDatabaseBackend::createObjectStore): (WebCore::IDBDatabaseBackend::deleteObjectStore): (WebCore::IDBDatabaseBackend::createIndex): (WebCore::IDBDatabaseBackend::deleteIndex): (WebCore::IDBDatabaseBackend::get): (WebCore::IDBDatabaseBackend::put): (WebCore::IDBDatabaseBackend::setIndexKeys): (WebCore::IDBDatabaseBackend::openCursor): (WebCore::IDBDatabaseBackend::deleteRange): (WebCore::IDBDatabaseBackend::clearObjectStore): (WebCore::IDBDatabaseBackend::transactionStarted): (WebCore::IDBDatabaseBackend::transactionFinished): (WebCore::IDBDatabaseBackend::transactionFinishedAndAbortFired): (WebCore::IDBDatabaseBackend::transactionFinishedAndCompleteFired): (WebCore::IDBDatabaseBackend::createTransaction): (WebCore::IDBDatabaseBackend::runIntVersionChangeTransaction): (WebCore::IDBDatabaseBackend::deleteDatabase): * Modules/indexeddb/IDBDatabaseBackend.h: * Modules/indexeddb/IDBFactory.cpp: (WebCore::IDBFactory::open): (WebCore::IDBFactory::openInternal): (WebCore::IDBFactory::deleteDatabase): * Modules/indexeddb/IDBIndex.cpp: (WebCore::IDBIndex::openCursor): (WebCore::IDBIndex::openKeyCursor): * Modules/indexeddb/IDBObjectStore.cpp: (WebCore::IDBObjectStore::openCursor): * Modules/indexeddb/IDBOpenDBRequest.cpp: (WebCore::IDBOpenDBRequest::onUpgradeNeeded): * Modules/indexeddb/IDBRequest.cpp: (WebCore::IDBRequest::IDBRequest): (WebCore::IDBRequest::setResultCursor): (WebCore::IDBRequest::onSuccess): * Modules/indexeddb/IDBTransaction.cpp: (WebCore::IDBTransaction::create): (WebCore::IDBTransaction::IDBTransaction): (WebCore::IDBTransaction::stringToMode): (WebCore::IDBTransaction::modeToString): * Modules/indexeddb/IDBTransaction.h: * Modules/indexeddb/IDBTransactionBackendOperations.cpp: (WebCore::PutOperation::perform): * Modules/indexeddb/IDBTransactionCoordinator.cpp: (WebCore::IDBTransactionCoordinator::processStartedTransactions): (WebCore::IDBTransactionCoordinator::canRunTransaction): * Modules/indexeddb/IDBVersionChangeEvent.h: (WebCore::IDBVersionChangeEvent::create): (WebCore::IDBVersionChangeEvent::newVersion): * Modules/indexeddb/leveldb/IDBBackingStoreLevelDB.cpp: (WebCore::objectStoreCursorOptions): (WebCore::indexCursorOptions): * Modules/indexeddb/leveldb/IDBServerConnectionLevelDB.cpp: (WebCore::IDBServerConnectionLevelDB::get): (WebCore::IDBServerConnectionLevelDB::openCursor): (WebCore::IDBServerConnectionLevelDB::count): (WebCore::IDBServerConnectionLevelDB::deleteRange): (WebCore::IDBServerConnectionLevelDB::cursorPrefetchIteration): * WebCore.exp.in: 2013-12-17 Gavin Barraclough Remove PageVisibilityStateUnloaded https://bugs.webkit.org/show_bug.cgi?id=125869 Reviewed by Anders Carlsson. This is not currently supported by WebKit, remove this enum value. We can always add this back later if/when we add support for this state. * page/PageVisibilityState.cpp: (WebCore::pageVisibilityStateString): * page/PageVisibilityState.h: - removed PageVisibilityStateUnloaded 2013-12-12 Martin Robinson [GTK] [CMake] Build the plugin process against GTK+ 2 https://bugs.webkit.org/show_bug.cgi?id=116374 Reviewed by Gustavo Noronha Silva. * PlatformGTK.cmake: Split off the GTK+-dependent sources into libWebCorePlatformGTK and compile libWebCorePlatformGTK2 when WebKit2 is enabled. 2013-12-17 Alex Christensen Compile fix for WebGL on Windows without GRAPHICS_SURFACE. https://bugs.webkit.org/show_bug.cgi?id=125867 Reviewed by Martin Robinson. * platform/graphics/opengl/GLPlatformSurface.cpp: (WebCore::GLPlatformSurface::createOffScreenSurface): Protect reference to EGLOffScreenSurface with USE(GRAPHICS_SURFACE). 2013-12-17 Radu Stavila [CSS Regions] Positioned elements in regions get clipped if they fall outside the region https://bugs.webkit.org/show_bug.cgi?id=117120 Reviewed by Mihnea Ovidenie. Fixed the computing of the box decorations clip rect when having statically positioned elements inside positioned elements. The existing algorithm computed the rect in a loop running up the containing block chain and only checked for positioned elements before starting the loop. If a positioned elements was found in the middle of a loop (as would be the case with a positioned element parenting a non-positioned element), it was not correctly handled. Also changed it so the clip is only performed in the fragmentation direction as that was the original purpose of this method. Tests: fast/regions/absolute-in-relative-overflow.html fast/regions/static-in-relative-overflow.html fast/regions/sticky-border-overflow.html * rendering/RenderFlowThread.cpp: (WebCore::RenderFlowThread::decorationsClipRectForBoxInRegion): 2013-12-17 Commit Queue Unreviewed, rolling out r160717. http://trac.webkit.org/changeset/160717 https://bugs.webkit.org/show_bug.cgi?id=125863 New tests are failing, and possibly broke an existing test (Requested by ap on #webkit). * rendering/FlowThreadController.cpp: (WebCore::FlowThreadController::collectFixedPositionedLayers): * rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintFixedLayersInNamedFlows): (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows): 2013-12-17 Ryosuke Niwa Invalid dir attributes should resolve to ltr https://bugs.webkit.org/show_bug.cgi?id=125830 Reviewed by Darin Adler. Merge https://chromium.googlesource.com/chromium/blink/+/2d592d1c998bec9438e421e1ce1ee6caba05a884 The dir attribute should resolve to direction: ltr by default when the attribute value is "not in a defined state": http://www.w3.org/TR/2013/WD-html51-20130528/dom.html#the-directionality Test: fast/dom/HTMLElement/set-and-clear-dir-attribute.html * html/HTMLElement.cpp: (WebCore::isLTROrRTLIgnoringCase): Extracted from HTMLElement::directionality. (WebCore::HTMLElement::collectStyleForPresentationAttribute): (WebCore::HTMLElement::directionality): 2013-12-17 Mihnea Ovidenie [CSSRegions] Incorrect repaint of fixed element with transformed parent https://bugs.webkit.org/show_bug.cgi?id=125756 Reviewed by Darin Adler. When collecting the layers for fixed positioned elements with named flow as a containing block, use layers collection at named flow layer level instead of relying on the positioned elements collection. Modified also FlowThreadController::collectFixedPositionedLayers function to always return the layers sorted by z-index, as this operation was always done at the call sites. Tests: fast/regions/repaint/fixed-in-named-flow-cb-changed.html fast/regions/repaint/fixed-in-named-flow-cb-changed2.html * rendering/FlowThreadController.cpp: (WebCore::compareZIndex): (WebCore::FlowThreadController::collectFixedPositionedLayers): * rendering/RenderLayer.cpp: (WebCore::RenderLayer::paintFixedLayersInNamedFlows): (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows): 2013-12-17 Bem Jones-Bey REGRESSION(r159166?): fast/block/float/float-with-fractional-height-vertical-lr.html, fast/block/float/float-with-fractional-height.html are failing https://bugs.webkit.org/show_bug.cgi?id=124506 Reviewed by Dirk Schulze. Floor the endpoints of the floating object interval to keep the old behavior until a better fix can be created. No new tests, fixes regression in existing tests. * rendering/FloatingObjects.cpp: (WebCore::FloatingObjects::intervalForFloatingObject): 2013-12-17 Alex Christensen [Win] Visual Studio workaround for compiling WebGL. https://bugs.webkit.org/show_bug.cgi?id=125808 Reviewed by Darin Adler. * platform/graphics/GraphicsContext3D.cpp: Don't inline outermost function to prevent Visual Studio crash. 2013-12-17 Mario Sanchez Prada [ATK] Expose accessibility objects for
,
and
https://bugs.webkit.org/show_bug.cgi?id=125857 Reviewed by Chris Fleizach. Map description lists to the newly introduced ATK roles ATK_ROLE_DESCRIPTION_LIST, ATK_ROLE_DESCRIPTION_TERM and ATK_ROLE_DESCRIPTION_VALUE, introduced in ATK 2.11.4. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): Do the right mapping. (webkitAccessibleGetRole): Update call to atkRole, now that it receives an AccessibilityObject* as parameter. 2013-12-17 Frédéric Wang Ensure inferred mrows for msqrt, mstyle, merror, mphantom and math. https://bugs.webkit.org/show_bug.cgi?id=124841 Reviewed by Darin Adler. Tests: mathml/presentation/inferred-mrow-baseline.html mathml/presentation/inferred-mrow-stretchy.html * css/mathml.css: make merror, mphantom and mstyle behave like an mrow. (mo, mrow, mfenced, mfrac, msub, msup, msubsup, mmultiscripts, mprescripts, none, munder, mover, munderover, msqrt, mroot, merror, mphantom, mstyle): (math, mrow, mfenced, msqrt, mroot, merror, mphantom, mstyle): * mathml/MathMLInlineContainerElement.cpp: ditto (WebCore::MathMLInlineContainerElement::createRenderer): * mathml/mathtags.in: ditto * rendering/mathml/RenderMathMLOperator.cpp: (WebCore::RenderMathMLOperator::paint): fix failure in mathml/presentation/phantom.html now that phantom can stretch operators. 2013-12-17 Simon Pena [NIX] Enable full debug builds by having ar creating thin archives https://bugs.webkit.org/show_bug.cgi?id=125850 Reviewed by Csaba Osztrogonác. By default, CMake uses ar to generate libWebCore.a with cr parameters (do not warn if the library has to be created, and replace existing files in the archive). That results in a very large file, and ar fails with sizes over 4GB. By using thin archives (the T option of ar), the generated libWebCore.a is much smaller, and can be successfully archived. As a result, we can generate a full debug build. This patch is based on Xan López's webkit.org/b/110580. * PlatformNix.cmake: Instruct cmake to invoke ar with T option. 2013-12-17 Carlos Garcia Campos Unreviewed. Update GObject DOM symbols file after r160336. * bindings/gobject/webkitdom.symbols: Add new methods exposed for VideoPlaybackQuality. 2013-12-17 Mihai Maerean Fix hit testing for divs with a hierarchy of css transformed and non-transformed elements https://bugs.webkit.org/show_bug.cgi?id=124777 Reviewed by Darin Adler. After bug #124647, the hit test will still behave incorrectly for transformed divs with non transformed siblings that are all inside a transformed element (tested by the hover-rotated-with-children-negative-z.html layout test). The fix is to not take zOffset into account during hit-testing when child layers are in the same 3D rendering context. Only when preserve3d is true, should hit-testing compute the zOffset of the layers with transformations and, when two layers overlap, to return the layer with the highest zOffset. The patch includes the work of a.renevier from https://codereview.chromium.org/79943002/ Tests: transforms/3d/hit-testing/hover-rotated-with-children-negative-z.html transforms/3d/hit-testing/negative-zoffset-hit-test.html transforms/3d/hit-testing/overlapping-layers-hit-test.html * rendering/RenderLayer.cpp: (WebCore::computeZOffset): (WebCore::RenderLayer::hitTestLayer): 2013-12-17 Carlos Garcia Campos Remove a few more guards mistakenly added in r160367 Reviewed by Martin Robinson. r160367 was too liberal in hiding APIs from the GObject DOM bindings. * Modules/battery/NavigatorBattery.idl: Expose NavigatorBattery. 2013-12-17 Benjamin Poulain Add a simple register allocator to WebCore for x86_64 https://bugs.webkit.org/show_bug.cgi?id=125771 Reviewed by Geoffrey Garen. Add a brain dead register allocator to simplify the use of registers when writting code generators. RegisterAllocator has two purposes: -make it easy to name registers properly. -make it hard to reuse a register accidentally. A helper class LocalRegister is also defined to provide an easy way to work with registers within a C++ scope. For example: LocalRegister elementPointer(allocator); assembler.load(address, elementPointer); RegisterAllocator makes no attempt at optimizing register allocations, but it reduces implicit dependencies by returning used register at the end of the queue, making it less likely they will be reused before their last instruction is executed. The current implementation only support unix x86_64, it only uses caller saved registers. * WebCore.xcodeproj/project.pbxproj: * cssjit/RegisterAllocator.h: Added. (WebCore::RegisterAllocator::allocateRegister): Provides any available register. To restrict runtime exploitation of compiler bugs, the method crashes in release if the register pool is empty. (WebCore::RegisterAllocator::reserveRegister): Reserve a particular register. (WebCore::RegisterAllocator::returnRegister): Return a previously allocated or reserved register. (WebCore::RegisterAllocator::allocatedRegisters): (WebCore::LocalRegister::LocalRegister): (WebCore::LocalRegister::~LocalRegister): (WebCore::LocalRegister::operator JSC::MacroAssembler::RegisterID): (WebCore::RegisterAllocator::RegisterAllocator): 2013-12-16 Thiago de Barros Lacerda Checking RTCPeerConnection signalingState before setting local/remoteDescription https://bugs.webkit.org/show_bug.cgi?id=125655 Reviewed by Eric Carlson. Before setting a session description RTCPeerConnection must check if it is in valid state for that SDP type. New tests: fast/mediastream/RTCPeerConnection-have-local-answer.html fast/mediastream/RTCPeerConnection-have-local-offer.html fast/mediastream/RTCPeerConnection-have-local-pranswer.html fast/mediastream/RTCPeerConnection-have-remote-offer.html fast/mediastream/RTCPeerConnection-have-remote-pranswer.html fast/mediastream/RTCPeerConnection-stable.html Modified: fast/mediastream/RTCPeerConnection-remoteDescription.html * Modules/mediastream/RTCPeerConnection.cpp: (WebCore::RTCPeerConnection::checkStateForLocalDescription): Checks if the current state of RTCPeerConnection is valid for the local SDP that is being set. (WebCore::RTCPeerConnection::checkStateForRemoteDescription): Checks if the current state of RTCPeerConnection is valid for the remote SDP that is being set. (WebCore::RTCPeerConnection::setLocalDescription): Now calls checkStateForLocalDescription prior to set the local SDP. (WebCore::RTCPeerConnection::setRemoteDescription): Now Calls checkStateForRemoteDescription prior to set the remote SDP. * Modules/mediastream/RTCPeerConnection.h: * platform/mock/RTCNotifiersMock.cpp: Adding new class to notify RTCPeerConnection about a signaling state change: SignalingStateNotifier. (WebCore::SignalingStateNotifier::SignalingStateNotifier): (WebCore::SignalingStateNotifier::fire): * platform/mock/RTCNotifiersMock.h: * platform/mock/RTCPeerConnectionHandlerMock.cpp: (WebCore::RTCPeerConnectionHandlerMock::signalingStateFromSDP): Defines the new state that RTCPeerConnection should be, according the SDP that is being set. (WebCore::RTCPeerConnectionHandlerMock::setLocalDescription): Calls signalingStateFromSDP, in order to get the new signaling state and notify RTCPeerConnection object. (WebCore::RTCPeerConnectionHandlerMock::setRemoteDescription): Ditto. * platform/mock/RTCPeerConnectionHandlerMock.h: 2013-12-16 Tim Horton Revert a mysterious and inexplicable part of http://trac.webkit.org/changeset/160685 * platform/KeyedCoding.h: (WebCore::KeyedEncoder::encodeEnum): (WebCore::KeyedEncoder::encodeObject): (WebCore::KeyedEncoder::encodeConditionalObject): (WebCore::KeyedEncoder::encodeObjects): 2013-12-16 Anders Carlsson Remove EnumClass.h from WTF https://bugs.webkit.org/show_bug.cgi?id=125820 Reviewed by Darin Adler. Replace uses of ENUM_CLASS with real enum class declarations. * Modules/webdatabase/DatabaseBasicTypes.h: * Modules/webdatabase/DatabaseError.h: * Modules/webdatabase/SQLTransactionState.h: * bindings/js/JSSubtleCryptoCustom.cpp: * bindings/js/SerializedScriptValue.cpp: * crypto/CryptoAlgorithmIdentifier.h: * crypto/CryptoAlgorithmParameters.h: * crypto/CryptoKey.h: * crypto/CryptoKeyData.h: * crypto/CryptoKeyType.h: * crypto/keys/CryptoKeyDataRSAComponents.h: * inspector/InspectorTimelineAgent.h: 2013-12-16 Tim Horton WebKit2 View Gestures: Pinching beyond the extremes doesn't animate back to the min/max https://bugs.webkit.org/show_bug.cgi?id=125750 Reviewed by Simon Fraser. * WebCore.exp.in: Export a few things so WebKit2 can use them. 2013-12-16 Joseph Pecoraro Fix some whitespace issues in inspector code https://bugs.webkit.org/show_bug.cgi?id=125814 Reviewed by Darin Adler. * inspector/protocol/DOM.json: * inspector/protocol/DOMStorage.json: * inspector/protocol/Timeline.json: 2013-12-16 Joseph Pecoraro Web Inspector: Use JSC::SourceID and JSC::BreakpointID instead of WebCore dups https://bugs.webkit.org/show_bug.cgi?id=125818 Reviewed by Mark Lam. Remove the WebCore typedefs of JSC types. Prefer JSC namespace prefixed types throughout WebCore's Inspector code. * GNUmakefile.list.am: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.xcodeproj/project.pbxproj: * bindings/js/BreakpointID.h: Removed. * bindings/js/ScriptDebugServer.cpp: (WebCore::ScriptDebugServer::setBreakpoint): (WebCore::ScriptDebugServer::removeBreakpoint): (WebCore::ScriptDebugServer::dispatchDidParseSource): * bindings/js/ScriptDebugServer.h: * bindings/js/SourceID.h: Removed. * inspector/InspectorDebuggerAgent.cpp: (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent): (WebCore::parseLocation): (WebCore::InspectorDebuggerAgent::setBreakpoint): (WebCore::InspectorDebuggerAgent::continueToLocation): (WebCore::InspectorDebuggerAgent::resolveBreakpoint): (WebCore::InspectorDebuggerAgent::searchInContent): (WebCore::InspectorDebuggerAgent::getScriptSource): (WebCore::InspectorDebuggerAgent::didParseSource): (WebCore::InspectorDebuggerAgent::didPause): (WebCore::InspectorDebuggerAgent::clear): * inspector/InspectorDebuggerAgent.h: * inspector/ScriptDebugListener.h: 2013-12-16 Daniel Bates [iOS] Upstream WebCore/dom changes https://bugs.webkit.org/show_bug.cgi?id=125646 Reviewed by David Kilzer. * WebCore.exp.in: Added symbol __ZN7WebCore8Settings17setLayoutIntervalEi and removed symbol __ZN7WebCore24cLayoutScheduleThresholdE. * dom/ActiveDOMObject.h: Add suspension reason DocumentWillBePaused. * dom/DOMImplementation.cpp: (WebCore::DOMImplementation::createDocument): Opt-out of ENABLE(VIDEO) logic when building for iOS. * dom/DeviceMotionClient.h: Made class non-copyable. (WebCore::DeviceMotionClient::DeviceMotionClient): Added; * dom/DeviceMotionController.cpp: Added FIXME comment to reconcile iOS and OpenSource differences. (WebCore::DeviceMotionController::suspendUpdates): Added; guarded by PLATFORM(IOS). (WebCore::DeviceMotionController::resumeUpdates): Added; guarded by PLATFORM(IOS). * dom/DeviceMotionController.h: Added FIXME comment to reconcile iOS and OpenSource differences. * dom/DeviceOrientationClient.h: Made class non-copyable. (WebCore::DeviceOrientationClient::DeviceOrientationClient): Added. * dom/DeviceOrientationController.cpp: Added FIXME comment to reconcile iOS and OpenSource differences. (WebCore::DeviceOrientationController::DeviceOrientationController): (WebCore::DeviceOrientationController::suspendUpdates): Added; guarded by PLATFORM(IOS). (WebCore::DeviceOrientationController::resumeUpdates): Added; guarded by PLATFORM(IOS). * dom/DeviceOrientationController.h: Added FIXME comment to reconcile iOS and OpenSource differences. * dom/DeviceOrientationData.cpp: (WebCore::DeviceOrientationData::create): Added; iOS-specific. Added FIXME comment. (WebCore::DeviceOrientationData::DeviceOrientationData): Added iOS-specific code. (WebCore::DeviceOrientationData::compassHeading): Added; guarded by PLATFORM(IOS). (WebCore::DeviceOrientationData::compassAccuracy): Added; guarded by PLATFORM(IOS). (WebCore::DeviceOrientationData::canProvideCompassHeading): Added; guarded by PLATFORM(IOS). (WebCore::DeviceOrientationData::canProvideCompassAccuracy): Added; guarded by PLATFORM(IOS). * dom/DeviceOrientationData.h: * dom/DeviceOrientationEvent.idl: Added iOS-specific code. * dom/Document.cpp: Moved constant cLayoutScheduleThreshold to Settings.cpp and renamed it layoutScheduleThreshold towards allowing a port to configure the layout interval. (WebCore::Document::Document): Added optional argument isSynthesized, defaults false. (WebCore::Document::~Document): Added iOS-specific code to destroy the device motion and device orientation controllers. (WebCore::Document::didBecomeCurrentDocumentInFrame): Added iOS-specific code with FIXME comment. (WebCore::Document::prepareForDestruction): Added iOS-specific touch event code. (WebCore::Document::removeAllEventListeners): Ditto. (WebCore::Document::platformSuspendOrStopActiveDOMObjects): Added; compiles to an empty function on non-iOS port. (WebCore::Document::suspendActiveDOMObjects): Modified to call platformSuspendOrStopActiveDOMObjects(). (WebCore::Document::resumeActiveDOMObjects): Ditto. (WebCore::Document::stopActiveDOMObjects): Added. (WebCore::Document::implicitClose): Modified to query Settings::layoutInterval(). (WebCore::Document::minimumLayoutDelay): Ditto. (WebCore::Document::processViewport): Added iOS-specific code. (WebCore::Document::updateViewportArguments): Ditto. (WebCore::setParserFeature): Added; guarded by PLATFORM(IOS). (WebCore::Document::processFormatDetection): Added; guarded by PLATFORM(IOS). (WebCore::Document::processWebAppOrientations): Added; guarded by PLATFORM(IOS). (WebCore::Document::isTelephoneNumberParsingEnabled): Added; guarded by PLATFORM(IOS). (WebCore::Document::setIsTelephoneNumberParsingAllowed): Added; guarded by PLATFORM(IOS). (WebCore::Document::isTelephoneNumberParsingAllowed): Added; guarded by PLATFORM(IOS). (WebCore::Document::initSecurityContext): Added iOS-specific code. (WebCore::Document::suspendScheduledTasks): Added; guarded by PLATFORM(IOS). (WebCore::Document::deviceMotionController): Added; iOS-specific. (WebCore::Document::deviceOrientationController): Added; iOS-specific. (WebCore::Document::adjustFloatQuadsForScrollAndAbsoluteZoomAndFrameScale): Added iOS-specific code. (WebCore::Document::adjustFloatRectForScrollAndAbsoluteZoomAndFrameScale): Added iOS-specific code. * dom/Document.h: Register gesture events gesture{change, end, start}; guarded by ENABLE(IOS_GESTURE_EVENTS). (WebCore::Document::isSynthesized): Added. (WebCore::Document::platformSuspendOrStopActiveDOMObjects): Added. * dom/Document.idl: * dom/DocumentMarker.h: Added iOS-specific changes. We should look to reconcile the differences between iOS and OpenSource. See . (WebCore::DocumentMarker::AllMarkers::AllMarkers): (WebCore::DocumentMarker::DocumentMarker): Added; iOS-specific. (WebCore::DocumentMarker::alternatives): Added; iOS-specific. (WebCore::DocumentMarker::setAlternative): Added; iOS-specific. (WebCore::DocumentMarker::metadata): Added; iOS-specific. (WebCore::DocumentMarker::setMetadata): Added; iOS-specific. * dom/DocumentMarkerController.cpp: (WebCore::DocumentMarkerController::addMarker): (WebCore::DocumentMarkerController::addDictationPhraseWithAlternativesMarker): (WebCore::DocumentMarkerController::addDictationResultMarker): (WebCore::DocumentMarkerController::shiftMarkers): * dom/DocumentMarkerController.h: * dom/Element.cpp: (WebCore::Element::focus): Add iOS-specific workaround for . * dom/Element.h: Register gesture events gesture{change, end, start}; guarded by ENABLE(IOS_GESTURE_EVENTS). * dom/EventContext.cpp: Opt-out of ENABLE(TOUCH_EVENTS)-guarded code when building the iOS port. * dom/EventContext.h: Ditto. * dom/EventDispatcher.cpp: (WebCore::EventRelatedNodeResolver::EventRelatedNodeResolver): Ditto. (WebCore::EventDispatcher::dispatchEvent): Ditto. (WebCore::EventPath::EventPath): Ditto. * dom/EventNames.h: Added events webkit{currentplaybacktargetiswirelesschanged, playbacktargetavailabilitychanged} and gesture{change, end, start}. * dom/EventNames.in: Added event names GestureEvent and WebKitPlaybackTargetAvailabilityEvent conditioned on the macro defines ENABLE_IOS_GESTURE_EVENTS and ENABLE_IOS_AIRPLAY. * dom/MouseRelatedEvent.cpp: (WebCore::contentsScrollOffset): Added iOS-specific code. (WebCore::MouseRelatedEvent::MouseRelatedEvent): Ditto. * dom/Node.cpp: (WebCore::Node::willBeDeletedFrom): Ditto. (WebCore::Node::isDescendantOf): Fixed style issue in function prototype; moved '*' to the left side. (WebCore::Node::isDescendantOrShadowDescendantOf): Added. (WebCore::tryAddEventListener): Added iOS-specific code; also added FIXME comment. (WebCore::tryRemoveEventListener): Ditto. (WebCore::Node::dispatchEvent): Opt-out of ENABLE(TOUCH_EVENTS)-guarded code when building the iOS port. (WebCore::Node::defaultEventHandler): Added iOS-specific code. (WebCore::Node::willRespondToMouseMoveEvents): Added iOS-specific code; also added FIXME comment. (WebCore::Node::willRespondToMouseClickEvents): Added iOS-specific code; also added FIXME comment. (WebCore::Node::willRespondToMouseWheelEvents): Added. * dom/Node.h: * dom/Position.h: (WebCore::operator<): Added. (WebCore::operator>): Added. (WebCore::operator>=): Added. (WebCore::operator<=): Added. * dom/Range.cpp: (WebCore::Range::create): Added iOS-specific code; also added FIXME comment. (WebCore::intervalsSufficientlyOverlap): Added; guarded by PLATFORM(IOS). (WebCore::printRects): Added; guarded by PLATFORM(IOS). (WebCore::adjustLineHeightOfSelectionRects): Added; guarded by PLATFORM(IOS). (WebCore::coalesceSelectionRects): Added; guarded by PLATFORM(IOS). (WebCore::Range::collectSelectionRects): Added; guarded by PLATFORM(IOS). * dom/Range.h: * dom/ScriptExecutionContext.cpp: (WebCore::ScriptExecutionContext::suspendActiveDOMObjects): Added iOS-specific code. (WebCore::ScriptExecutionContext::dispatchErrorEvent): Ditto. * dom/TreeScope.cpp: (WebCore::nodeFromPoint): Ditto. * dom/ViewportArguments.cpp: (WebCore::computeViewportAttributes): Ditto. (WebCore::setViewportFeature): Added iOS-specific code. (WebCore::finalizeViewportArguments): Added; iOS-specific. * dom/ViewportArguments.h: * dom/make_names.pl: Added support to find the path to gcc with respect to the environment variable SDKROOT. * html/HTMLMediaElement.cpp: (HTMLMediaElement::suspend): * page/Settings.cpp: (WebCore::Settings::Settings): Initialize setting m_layoutInterval to layoutScheduleThreshold. (WebCore::Settings::setLayoutInterval): Added. * page/Settings.h: (WebCore::Settings::layoutInterval): Added. 2013-12-16 Simon Fraser Attempt to fix the Windows build after r160672. * platform/graphics/ca/win/PlatformCALayerWin.cpp: (PlatformCALayerWin::PlatformCALayerWin): * platform/graphics/ca/win/PlatformCALayerWin.h: 2013-12-16 Simon Fraser Apply overhang shadow and linen to UI-side layers https://bugs.webkit.org/show_bug.cgi?id=125807 Reviewed by Tim Horton. With UI-side compositing, we need to apply the overhang shadow and linen background to layers in the UI process. Achieve this by setting a "custom appearance" flag on layers that need a shadow or linen background, and migrating this flag to the UI process. Static functions on ScrollbarThemeMac are exposed to do the actual setting. * WebCore.exp.in: Export ScrollbarThemeMac and GraphicsLayerCA functions. * WebCore.xcodeproj/project.pbxproj: ScrollbarThemeMac.h and ScrollbarThemeComposite.h need to be Private. * platform/graphics/GraphicsLayer.cpp: Initialize m_customAppearance. (WebCore::GraphicsLayer::GraphicsLayer): * platform/graphics/GraphicsLayer.h: Getter/setter for CustomAppearance. (WebCore::GraphicsLayer::setCustomAppearance): (WebCore::GraphicsLayer::customAppearance): * platform/graphics/ca/GraphicsLayerCA.cpp: Update CustomAppearanceChanged as we do other properties. (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): (WebCore::GraphicsLayerCA::updateCustomAppearance): (WebCore::GraphicsLayerCA::setCustomAppearance): * platform/graphics/ca/GraphicsLayerCA.h: * platform/graphics/ca/PlatformCALayer.h: * platform/graphics/ca/mac/PlatformCALayerMac.h: * platform/graphics/ca/mac/PlatformCALayerMac.mm: When we have a custom appearance, use ScrollbarThemeMac functions to update the layer. Ensure that if the bounds change, we update the shadow (whose path depends on the bounds). (PlatformCALayerMac::PlatformCALayerMac): (PlatformCALayerMac::clone): (PlatformCALayerMac::setBounds): (PlatformCALayerMac::requiresCustomAppearanceUpdateOnBoundsChange): (PlatformCALayerMac::updateCustomAppearance): * platform/mac/ScrollbarThemeMac.h: Export some static functions. * platform/mac/ScrollbarThemeMac.mm: Change code to use static functions. (WebCore::ScrollbarThemeMac::setUpOverhangAreaBackground): (WebCore::ScrollbarThemeMac::removeOverhangAreaBackground): (WebCore::ScrollbarThemeMac::setUpOverhangAreaShadow): (WebCore::ScrollbarThemeMac::removeOverhangAreaShadow): (WebCore::ScrollbarThemeMac::setUpOverhangAreasLayerContents): (WebCore::ScrollbarThemeMac::setUpContentShadowLayer): * rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::updateRootLayerPosition): No need to call setUpContentShadowLayer() now when size changes; PlatformCALayer takes care of that. (WebCore::RenderLayerCompositor::updateOverflowControlsLayers): Now set custom appearance via GraphicsLayer. 2013-12-16 Brent Fulgham [Win] Remove dead code after converstion to VS2013 https://bugs.webkit.org/show_bug.cgi?id=125795 Reviewed by Darin Adler. * WebCorePrefix.h: Remove VS2012 include kludge. * loader/FTPDirectoryParser.cpp: Remove gmtime workaround code. * page/DOMWindow.cpp: Remove older pointer-based open implementation. * page/DOMWindow.h: Ditto * platform/text/TextEncodingRegistry.cpp: (WebCore::TextEncodingNameHash::equal): Remove optimization bug workaround * testing/Internals.cpp: (WebCore::Internals::openDummyInspectorFrontend): Remove compiler workaround 2013-12-16 Daniel Bates [iOS] Upstream WebCore/history changes https://bugs.webkit.org/show_bug.cgi?id=125769 Reviewed by Darin Adler. * history/BackForwardClient.h: * history/BackForwardList.cpp: (WebCore::BackForwardList::current): Added; guard by PLATFORM(IOS). Also added FIXME comment. (WebCore::BackForwardList::setCurrent): Added; guard by PLATFORM(IOS). Also added FIXME comment. (WebCore::BackForwardList::clearAllPageCaches): Added; guarded by PLATFORM(IOS). * history/BackForwardList.h: * history/CachedFrame.cpp: (WebCore::CachedFrameBase::restore): Added iOS-specific code. (WebCore::CachedFrame::CachedFrame): Ditto. * history/CachedPage.cpp: (WebCore::CachedPage::restore): Ditto. * history/HistoryItem.cpp: (WebCore::HistoryItem::HistoryItem): Ditto. * history/HistoryItem.h: (WebCore::HistoryItem::scale): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::scaleIsInitial): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::setScale): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::viewportArguments): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::setViewportArguments): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::bookmarkID): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::setBookmarkID): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::sharedLinkUniqueIdentifier): Added; guarded by PLATFORM(IOS). (WebCore::HistoryItem::setSharedLinkUniqueIdentifier): Added; guarded by PLATFORM(IOS). * history/PageCache.cpp: (WebCore::logCanCacheFrameDecision): Added iOS-specific code. (WebCore::logCanCachePageDecision): Ditto. (WebCore::PageCache::canCachePageContainingThisFrame): Ditto. (WebCore::PageCache::canCache): Ditto. (WebCore::PageCache::pruneToCapacityNow): Added. * history/PageCache.h: 2013-12-16 Daniel Bates [iOS] Upstream WebCore/svg changes https://bugs.webkit.org/show_bug.cgi?id=125784 Reviewed by Darin Adler. * svg/SVGAElement.cpp: (WebCore::SVGAElement::willRespondToMouseClickEvents): Added. * svg/SVGAElement.h: * svg/SVGElement.cpp: (WebCore::SVGElement::parseAttribute): Added attribute listeners for touch{cancel, end, move, start}, and gesture{change, end, start}. 2013-12-13 Jeffrey Pfau [Mac] Cache partitioning asserts when associated NSURLRequest is nil https://bugs.webkit.org/show_bug.cgi?id=125716 Reviewed by Darin Adler. * platform/network/mac/ResourceRequestMac.mm: (WebCore::ResourceRequest::doUpdateResourceRequest): 2013-12-16 Brady Eidson DatabaseProcess: Fix a few bugs with opening an IDB connection https://bugs.webkit.org/show_bug.cgi?id=125798 Reviewed by Alexey Proskuryakov. * Modules/indexeddb/IDBDatabaseBackend.cpp: (WebCore::IDBDatabaseBackend::processPendingCalls): As the comment says, we should only early return when there *are* pending delete calls. The logic here was backwards, preventing the backend from ever getting to processPendingOpenCalls(). 2013-12-16 Alex Christensen Fixed Win64 build on VS2013. https://bugs.webkit.org/show_bug.cgi?id=125753 Reviewed by Brent Fulgham. * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCoreTestSupport.vcxproj: Added correct PlatformToolset for 64-bit builds. 2013-12-16 Simon Fraser Package up some data about scrollability into a struct for use in the scrolling tree https://bugs.webkit.org/show_bug.cgi?id=125792 Reviewed by Beth Dakin. Both scrolling state nodes and scrolling nodes share a set of parameters relating to scrollability and rubberbanding, so package them into a struct for re-use. Send the struct wholesale to the scrolling thread. * page/scrolling/ScrollingCoordinator.h: (WebCore::ScrollableAreaParameters::ScrollableAreaParameters): New struct. (WebCore::ScrollableAreaParameters::operator==): * page/scrolling/ScrollingStateScrollingNode.cpp: (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode): Reordering. (WebCore::ScrollingStateScrollingNode::setScrollOrigin): Moved. (WebCore::ScrollingStateScrollingNode::setScrollableAreaParameters): Set the parameters all at once. (WebCore::ScrollingStateScrollingNode::setRequestedScrollPosition): * page/scrolling/ScrollingStateScrollingNode.h: Getters access the struct. Reorder member variables. * page/scrolling/ScrollingTreeScrollingNode.cpp: (WebCore::ScrollingTreeScrollingNode::ScrollingTreeScrollingNode): (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren): * page/scrolling/ScrollingTreeScrollingNode.h: (WebCore::ScrollingTreeScrollingNode::scrollOrigin): (WebCore::ScrollingTreeScrollingNode::horizontalScrollElasticity): (WebCore::ScrollingTreeScrollingNode::verticalScrollElasticity): (WebCore::ScrollingTreeScrollingNode::hasEnabledHorizontalScrollbar): (WebCore::ScrollingTreeScrollingNode::hasEnabledVerticalScrollbar): (WebCore::ScrollingTreeScrollingNode::canHaveScrollbars): * page/scrolling/mac/ScrollingCoordinatorMac.h: * page/scrolling/mac/ScrollingCoordinatorMac.mm: Removed setScrollParametersForNode(). (WebCore::ScrollingCoordinatorMac::frameViewLayoutUpdated): Set the params in this function. Reordering. 2013-12-16 Sam Weinig CTTE: Convert more of SVG to use references https://bugs.webkit.org/show_bug.cgi?id=125762 Reviewed by Darin Adler. * rendering/svg/RenderSVGImage.cpp: (WebCore::RenderSVGImage::imageChanged): * rendering/svg/RenderSVGResource.cpp: (WebCore::removeFromCacheAndInvalidateDependencies): (WebCore::RenderSVGResource::markForLayoutAndParentResourceInvalidation): * rendering/svg/RenderSVGResource.h: * rendering/svg/RenderSVGResourceClipper.cpp: (WebCore::RenderSVGResourceClipper::removeClientFromCache): * rendering/svg/RenderSVGResourceClipper.h: * rendering/svg/RenderSVGResourceContainer.cpp: (WebCore::RenderSVGResourceContainer::markAllClientsForInvalidation): (WebCore::RenderSVGResourceContainer::markAllClientLayersForInvalidation): (WebCore::RenderSVGResourceContainer::markClientForInvalidation): (WebCore::RenderSVGResourceContainer::removeClient): * rendering/svg/RenderSVGResourceContainer.h: * rendering/svg/RenderSVGResourceFilter.cpp: (WebCore::RenderSVGResourceFilter::removeClientFromCache): (WebCore::RenderSVGResourceFilter::postApplyResource): (WebCore::RenderSVGResourceFilter::primitiveAttributeChanged): * rendering/svg/RenderSVGResourceFilter.h: * rendering/svg/RenderSVGResourceGradient.cpp: (WebCore::RenderSVGResourceGradient::removeClientFromCache): * rendering/svg/RenderSVGResourceGradient.h: * rendering/svg/RenderSVGResourceMarker.cpp: (WebCore::RenderSVGResourceMarker::removeClientFromCache): * rendering/svg/RenderSVGResourceMarker.h: * rendering/svg/RenderSVGResourceMasker.cpp: (WebCore::RenderSVGResourceMasker::removeClientFromCache): * rendering/svg/RenderSVGResourceMasker.h: * rendering/svg/RenderSVGResourcePattern.cpp: (WebCore::RenderSVGResourcePattern::removeClientFromCache): * rendering/svg/RenderSVGResourcePattern.h: * rendering/svg/RenderSVGResourceSolidColor.h: (WebCore::RenderSVGResourceSolidColor::removeClientFromCache): * rendering/svg/SVGRenderSupport.cpp: (WebCore::invalidateResourcesOfChildren): * rendering/svg/SVGResources.cpp: (WebCore::SVGResources::removeClientFromCache): * rendering/svg/SVGResources.h: * rendering/svg/SVGResourcesCache.cpp: (WebCore::SVGResourcesCache::clientLayoutChanged): (WebCore::SVGResourcesCache::clientStyleChanged): (WebCore::SVGResourcesCache::clientWasAddedToTree): (WebCore::SVGResourcesCache::clientWillBeRemovedFromTree): (WebCore::SVGResourcesCache::clientDestroyed): * svg/SVGAnimateMotionElement.cpp: (WebCore::SVGAnimateMotionElement::applyResultsToTarget): * svg/SVGCircleElement.cpp: (WebCore::SVGCircleElement::svgAttributeChanged): * svg/SVGEllipseElement.cpp: (WebCore::SVGEllipseElement::svgAttributeChanged): * svg/SVGFEImageElement.cpp: (WebCore::SVGFEImageElement::notifyFinished): * svg/SVGFELightElement.cpp: (WebCore::SVGFELightElement::childrenChanged): * svg/SVGFilterPrimitiveStandardAttributes.cpp: (WebCore::invalidateFilterPrimitiveParent): * svg/SVGFilterPrimitiveStandardAttributes.h: (WebCore::SVGFilterPrimitiveStandardAttributes::invalidate): (WebCore::SVGFilterPrimitiveStandardAttributes::primitiveAttributeChanged): * svg/SVGForeignObjectElement.cpp: (WebCore::SVGForeignObjectElement::svgAttributeChanged): * svg/SVGGElement.cpp: (WebCore::SVGGElement::svgAttributeChanged): * svg/SVGGraphicsElement.cpp: (WebCore::SVGGraphicsElement::svgAttributeChanged): * svg/SVGImageElement.cpp: (WebCore::SVGImageElement::svgAttributeChanged): * svg/SVGLineElement.cpp: (WebCore::SVGLineElement::svgAttributeChanged): * svg/SVGPathElement.cpp: (WebCore::SVGPathElement::svgAttributeChanged): (WebCore::SVGPathElement::invalidateMPathDependencies): (WebCore::SVGPathElement::pathSegListChanged): * svg/SVGPolyElement.cpp: (WebCore::SVGPolyElement::svgAttributeChanged): * svg/SVGRectElement.cpp: (WebCore::SVGRectElement::svgAttributeChanged): * svg/SVGSVGElement.cpp: (WebCore::SVGSVGElement::svgAttributeChanged): (WebCore::SVGSVGElement::setupInitialView): * svg/SVGStopElement.cpp: (WebCore::SVGStopElement::svgAttributeChanged): * svg/SVGTRefElement.cpp: (WebCore::SVGTRefElement::svgAttributeChanged): * svg/SVGTextContentElement.cpp: (WebCore::SVGTextContentElement::svgAttributeChanged): * svg/SVGTextPathElement.cpp: (WebCore::SVGTextPathElement::svgAttributeChanged): * svg/SVGTextPositioningElement.cpp: (WebCore::SVGTextPositioningElement::svgAttributeChanged): * svg/SVGUseElement.cpp: (WebCore::SVGUseElement::svgAttributeChanged): 2013-12-16 Hans Muller [CSS Shapes] Add support for the computing the included intervals for a BoxShape https://bugs.webkit.org/show_bug.cgi?id=124605 Reviewed by Andreas Kling. Setting shape-inside to content-box now works. Changed FloatRoundedRect::xInterceptsAtY() to include the bottom edge of the rectangle and to check for the special cases where any or all of the corner radii are empty. Test: fast/shapes/shape-inside/shape-inside-content-box.html * platform/graphics/FloatRoundedRect.cpp: (WebCore::FloatRoundedRect::xInterceptsAtY): * rendering/shapes/BoxShape.cpp: (WebCore::BoxShape::getIncludedIntervals): Replaced the stub implementation with logic that's similar to getExcludedIntervals(). * rendering/shapes/ShapeInfo.cpp: (WebCore::::computedShape): Removed a meaningless assert. * rendering/shapes/ShapeInsideInfo.cpp: (WebCore::ShapeInsideInfo::isEnabledFor): 2013-12-16 Mario Sanchez Prada [ATK] Expose accessibility objects for more WAI-ARIA roles https://bugs.webkit.org/show_bug.cgi?id=125596 Reviewed by Chris Fleizach. Exposed accessibility objects with the proper AtkRoles, some of them to be provided by the next stable release of ATK. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): 2013-12-16 Eric Carlson Fix QuickTime plug-in replacement scripting bugs https://bugs.webkit.org/show_bug.cgi?id=125717 Reviewed by Sam Weinig. No new tests, existing test updated. * Modules/plugins/QuickTimePluginReplacement.js: (Replacement): Change '' to "" to avoid "Empty character constant" warning when creating Derived Sources. (Replacement.prototype.createVideoElement): Handle qtsrc attribute. Remember base url. (Replacement.prototype.setURL): Resolve urls relative to base. 2013-12-15 Darin Adler Catch callers who forget to use initializeStyle https://bugs.webkit.org/show_bug.cgi?id=125763 Reviewed by Andreas Kling. A recent fix was because a caller used setStyle first rather than using initializeStyle. This patch adds an assertion to catch cases where we do that so we see the mistake right away instead of indirectly later. * rendering/RenderElement.cpp: (WebCore::RenderElement::initializeStyle): Simplified an assertion. (WebCore::RenderElement::setStyle): Added an assertion that m_hasInitializedStyle is true, with an exception for RenderView, which needs to be created before we have the correct style computed for it (at least for now). Also broke out an assertion that was using &&, since we would prefer to know which clause failed, making separate assertions more useful than a combined assertion. 2013-12-16 Mario Sanchez Prada [ATK] Expose accessibility objects with ATK_ROLE_CHECK_MENU_ITEM https://bugs.webkit.org/show_bug.cgi?id=125594 Reviewed by Chris Fleizach. Exposed accessibility objects with checkmenuitem role with the proper AtkRole, to be provided by the next stable release of ATK. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): 2013-12-16 Mario Sanchez Prada [ATK] Expose accessibility objects with ATK_ROLE_ARTICLE https://bugs.webkit.org/show_bug.cgi?id=125587 Reviewed by Chris Fleizach. Exposed accessibility objects with article role with the proper AtkRole, to be provided by the next stable release of ATK. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): 2013-11-27 Sergio Villar Senin [CSS Grid Layout] Fix the preferred logical widths code to work with spanning grid items https://bugs.webkit.org/show_bug.cgi?id=123994 Reviewed by Andreas Kling. From Blink r159189 by There was no definition in the specs for the intrinsic / preferred logical widths on the grid element. The following was proposed to the WG and later accepted: - The sum of the grid tracks' UsedBreadth is the minimum logical width - The sum of the grid tracks' MaxBreadth is the maximum logical width http://lists.w3.org/Archives/Public/www-style/2013Oct/0054.html for more information. * rendering/RenderGrid.cpp: (WebCore::RenderGrid::computeIntrinsicLogicalWidths): (WebCore::RenderGrid::computedUsedBreadthOfGridTracks): (WebCore::RenderGrid::minContentForChild): (WebCore::RenderGrid::maxContentForChild): * rendering/RenderGrid.h: 2013-12-15 Frédéric Wang Add support for maction@toggle https://bugs.webkit.org/show_bug.cgi?id=120059 Reviewed by Chris Fleizach. Test: mathml/presentation/maction-toggle.html * mathml/MathMLSelectElement.cpp: (WebCore::MathMLSelectElement::getSelectedChildAndIndex): (WebCore::MathMLSelectElement::updateSelectedChild): (WebCore::MathMLSelectElement::defaultEventHandler): (WebCore::MathMLSelectElement::willRespondToMouseClickEvents): (WebCore::MathMLSelectElement::toggle): * mathml/MathMLSelectElement.h: 2013-12-15 Darin Adler More nullptr in RenderElement https://bugs.webkit.org/show_bug.cgi?id=125764 Reviewed by Andreas Kling. * rendering/RenderElement.cpp: (WebCore::RenderElement::uncachedFirstLineStyle): (WebCore::RenderElement::updateShapeImage): (WebCore::RenderElement::destroyLeftoverChildren): (WebCore::RenderElement::findNextLayer): Use nullptr in a few more places. 2013-12-15 Ryosuke Niwa REGRESSION: 2x regression on Dromaeo DOM query tests https://bugs.webkit.org/show_bug.cgi?id=125377 Reviewed by Filip Pizlo. The bug was caused by JSC not JIT'ing property accesses on document because of its having custom named getter (named properties). This resulted in resolution of methods on document such as getElementById to happen inside the interpreter. Fixed the bug by using the new JSC type info flag which tells JSC to JIT property access on document, and then notifying JSC whenever a new named property appeared on document. Tests: js/dom/dfg-prototype-chain-caching-with-impure-get-own-property-slot-traps-2.html js/dom/dfg-prototype-chain-caching-with-impure-get-own-property-slot-traps-3.html js/dom/dfg-prototype-chain-caching-with-impure-get-own-property-slot-traps-4.html js/dom/prototype-chain-caching-with-impure-get-own-property-slot-traps-2.html js/dom/prototype-chain-caching-with-impure-get-own-property-slot-traps-3.html js/dom/prototype-chain-caching-with-impure-get-own-property-slot-traps-4.html * bindings/js/JSDOMBinding.cpp: (WebCore::addImpureProperty): Wraps VM::addImpureProperty. * bindings/js/JSDOMBinding.h: * bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader): Added the support for NewImpurePropertyFiresWatchpoints. * bindings/scripts/IDLAttributes.txt: Ditto. * html/HTMLDocument.cpp: (WebCore::HTMLDocument::addDocumentNamedItem): Calls addImpureProperty. * html/HTMLDocument.idl: Added NewImpurePropertyFiresWatchpoints. 2013-12-15 Brent Fulgham [WIn] Unreviewed build fix after r160599 * rendering/RenderMediaControls.cpp: (WebCore::determineState): RenderObject::theme now returns a reference. 2013-12-15 Brent Fulgham [Win] Unreviewed build fix The build system continues to attempt to build QTMovieWin, even though it is excluded from the build solution. I'm actually removing the project files to prevent this. * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj: Removed. * WebCore.vcxproj/QTMovieWin/QTMovieWin.vcxproj.filters: Removed. 2013-12-15 Rob Buis [CSS Shapes] shape-outside animation does not handle 'auto' well https://bugs.webkit.org/show_bug.cgi?id=125700 Reviewed by Dirk Schulze. Handle the case where we are blending/animating with a null ShapeValue due to 'auto'. Adapted LayoutTests/fast/shapes/shape-outside-floats/shape-outside-animation.html for testing this. * page/animation/CSSPropertyAnimation.cpp: (WebCore::blendFunc): 2013-12-15 Andy Estes [iOS] Upstream changes to FeatureDefines.xcconfig https://bugs.webkit.org/show_bug.cgi?id=125742 Reviewed by Dan Bernstein. * Configurations/FeatureDefines.xcconfig: 2013-12-14 Darin Adler Crash in CSSImageGeneratorValue and RenderScrollbar https://bugs.webkit.org/show_bug.cgi?id=125702 Reviewed by Alexey Proskuryakov. This crash had two causes at two different levels. The crash fixes both. At the RenderScrollbar level, we were setting up a new renderer, a RenderScrollbarPart, and never calling initializeStyle. This meant that we did not do proper style setup, which meant we did not end up calling CSSImageGeneratorValue::addClient and so had a removeClient that was not properly balanced by an addClient. This is the primary bug. At the CSSImageGeneratorValue level, the addClient and removeClient functions were not properly handling possibly-mismatched calls. It was easy to fix the functions to work even if the calls are not perfectly matched up, which makes the consequences of a missed addClient call much less dire, no longer messing up reference counting. Fixing this mitigates the risk if we made this same mistake elsewhere, although I could not find any other places with some quick searches. Test: fast/css/scrollbar-image-crash.html * css/CSSImageGeneratorValue.cpp: (WebCore::CSSImageGeneratorValue::addClient): Only call ref if this will add the first client. (WebCore::CSSImageGeneratorValue::removeClient): Only call deref if this removes the last client. Also added an assertion that can fire if we call removeClient without first calling addClient, which is illegal. However, the function handles that case without over-deref'ing itself. * rendering/RenderScrollbar.cpp: (WebCore::RenderScrollbar::updateScrollbarPart): Simplify the logic for needRenderer a bit. Use initializeStyle rather than setStyle when first creating the RenderScrollbarPart. Also use add and take properly so we don't do extra hash lookups the old code did with get/set and get/remove. 2013-12-14 Sam Weinig CTTE: SVGResourcesCache::cachedResourcesForRenderObject() should take a reference https://bugs.webkit.org/show_bug.cgi?id=125743 Reviewed by Dan Bernstein. * rendering/svg/RenderSVGContainer.cpp: (WebCore::RenderSVGContainer::selfWillPaint): * rendering/svg/RenderSVGImage.cpp: (WebCore::RenderSVGImage::imageChanged): * rendering/svg/RenderSVGResource.cpp: (WebCore::requestPaintingResource): (WebCore::removeFromCacheAndInvalidateDependencies): (WebCore::RenderSVGResource::markForLayoutAndParentResourceInvalidation): * rendering/svg/RenderSVGResourceClipper.cpp: (WebCore::RenderSVGResourceClipper::applyClippingToContext): * rendering/svg/RenderSVGRoot.cpp: (WebCore::RenderSVGRoot::paintReplaced): * rendering/svg/RenderSVGShape.cpp: (WebCore::RenderSVGShape::shouldGenerateMarkerPositions): (WebCore::RenderSVGShape::markerRect): (WebCore::RenderSVGShape::drawMarkers): * rendering/svg/SVGRenderSupport.cpp: (WebCore::invalidateResourcesOfChildren): (WebCore::SVGRenderSupport::layoutChildren): (WebCore::SVGRenderSupport::intersectRepaintRectWithResources): (WebCore::SVGRenderSupport::filtersForceContainerLayout): (WebCore::SVGRenderSupport::pointInClippingArea): * rendering/svg/SVGRenderingContext.cpp: (WebCore::SVGRenderingContext::prepareToRenderSVGContent): * rendering/svg/SVGResourcesCache.cpp: (WebCore::SVGResourcesCache::cachedResourcesForRenderObject): (WebCore::SVGResourcesCache::clientLayoutChanged): (WebCore::SVGResourcesCache::clientDestroyed): * rendering/svg/SVGResourcesCache.h: * rendering/svg/SVGResourcesCycleSolver.cpp: (WebCore::SVGResourcesCycleSolver::resourceContainsCycles): 2013-12-14 Dan Bernstein Clean up the project after r160487 * WebCore.xcodeproj/project.pbxproj: Moved reference to Security.framework from the top level of the project to the Frameworks group, and made it SDK-relative. 2013-12-14 Andreas Kling Page::theme() should return a reference. There's always a RenderTheme, and not a single call site was checking for null pointers anyway. Updated RenderObject::theme() as well. Reviewed by Antti Koivisto. 2013-12-13 Sam Weinig CTTE: Convert Element and RenderObject iterator usage to use range-based for loops https://bugs.webkit.org/show_bug.cgi?id=125731 Reviewed by Andreas Kling. Perform straight forward conversions. A few stragglers that do odd things remain. 2013-12-14 Joseph Pecoraro Small string improvements to JSInjectedScriptHost::type and other bindings https://bugs.webkit.org/show_bug.cgi?id=125722 Reviewed by Timothy Hatcher. * bindings/js/JSInjectedScriptHostCustom.cpp: (WebCore::JSInjectedScriptHost::type): Use SmallStrings, jsNontrivialString and ASCIILiteral. * bindings/js/JSJavaScriptCallFrameCustom.cpp: (WebCore::JSJavaScriptCallFrame::type): Use jsNontrivialString. * bridge/c/c_instance.cpp: (JSC::Bindings::CInstance::stringValue): Use jsNontrivialString and ASCIILiteral. 2013-12-14 Andreas Kling Move a couple of inlines from RenderObject to RenderElement. Take most of the inline functions on RenderObject that call style() and move them over to RenderElement where style() is branchless. Reviewed by Antti Koivisto. 2013-12-14 Andreas Kling RenderElement::rendererForRootBackground() should return a reference. This function always finds a renderer to return. Reviewed by Antti Koivisto. 2013-12-14 Mark Rowe Build fix after r160557. * Configurations/WebCore.xcconfig: Find JavaScriptCore.framework below SDKROOT so that we'll pick up the built version in production builds rather than the system version. 2013-12-14 Brendan Long [GStreamer] Use GMutexLocker instead of g_mutex_lock https://bugs.webkit.org/show_bug.cgi?id=125588 Reviewed by Philippe Normand. No new tests because this is just code simplification. * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: (WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): (WebCore::MediaPlayerPrivateGStreamerBase::triggerRepaint): (WebCore::MediaPlayerPrivateGStreamerBase::paint): * platform/graphics/gstreamer/VideoSinkGStreamer.cpp: (webkitVideoSinkTimeoutCallback): (webkitVideoSinkRender): (unlockBufferMutex): (webkitVideoSinkUnlockStop): (webkitVideoSinkStart): 2013-12-13 Andreas Kling Move RenderObject::repaintAfterLayoutIfNeeded() to RenderElement. This function is only ever called on RenderElements, so move it there. Removes some RenderObject::style() branchiness. Reviewed by Darin Adler. 2013-12-13 Joseph Pecoraro Web Inspector: Move Inspector and Debugger protocol domains into JavaScriptCore https://bugs.webkit.org/show_bug.cgi?id=125707 Reviewed by Timothy Hatcher. - Switch TypeBuilder::Page::SearchMatch to TypeBuilder::GenericTypes::SearchMatch which comes from InspectorJSTypeBuilders. - Remove domains that moved to JavaScriptCore. No new tests, this only moves code around. There are no functional changes. * CMakeLists.txt: * DerivedSources.make: * GNUmakefile.am: Add new files. * inspector/ContentSearchUtils.cpp: (WebCore::ContentSearchUtils::buildObjectForSearchMatch): (WebCore::ContentSearchUtils::searchInTextByLines): * inspector/ContentSearchUtils.h: * inspector/InspectorAgent.cpp: * inspector/InspectorAgent.h: * inspector/InspectorDebuggerAgent.h: * inspector/InspectorPageAgent.cpp: (WebCore::InspectorPageAgent::searchInResource): * inspector/InspectorPageAgent.h: * inspector/protocol/Page.json: Update includes and type builder type names. * inspector/InspectorDebuggerAgent.cpp: (WebCore::breakpointActionTypeForString): (WebCore::InspectorDebuggerAgent::searchInContent): * inspector/InspectorTimelineAgent.cpp: (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline): Use the new getEnum function names. 2013-12-13 Brent Fulgham [Win] Remove pre-VS2013 support code. https://bugs.webkit.org/show_bug.cgi?id=125693 Reviewed by Darin Adler. * Modules/webdatabase/DatabaseTracker.cpp: (WebCore::DatabaseTracker::setQuota): Use C99 format arguments * loader/FTPDirectoryParser.cpp: (WebCore::parseOneFTPLine): Ditto * loader/icon/IconDatabase.cpp: (WebCore::IconDatabase::pruneUnretainedIcons): Ditto * platform/sql/SQLiteDatabase.cpp: (WebCore::SQLiteDatabase::setMaximumSize): Ditto 2013-12-13 Brent Fulgham SVG bindings are improperly being generated with "fastGetAttribute" https://bugs.webkit.org/show_bug.cgi?id=125670 Reviewed by Darin Adler. A bug was introduced in r152845 that improperly called the IsSVGAnimatedType using the $attribute hash, rather than the expected $attribute->signature->type. * bindings/scripts/CodeGenerator.pm: (GetterExpression): Clean up attribute type confusion. 2013-12-13 Brent Fulgham [Win] Unreviewed build fix after r160548 * WebCore.vcxproj/WebCore.vcxproj: Exclude MediaPlayerPrivateQuickTimeVisualContext from Windows build. * platform/graphics/MediaPlayer.cpp: Don't use QuickTime as the PlatformMediaEngine. 2013-12-13 Joseph Pecoraro [GTK] Remove Warnings in building about duplicate INSPECTOR variables https://bugs.webkit.org/show_bug.cgi?id=125710 Reviewed by Tim Horton. * GNUmakefile.am: 2013-12-13 Roger Fong [WebGL] Check for global variable precision mismatch between vertex and fragment shaders. https://bugs.webkit.org/show_bug.cgi?id=125546. Reviewed by Brent Fulgham. Covered Khronos conformances tests: webgl/1.0.2/glsl/misc/shader-with-global-variable-precision-mismatch.html * html/canvas/WebGLRenderingContext.cpp: (WebCore::WebGLRenderingContext::linkProgram): * platform/graphics/GraphicsContext3D.h: Rename areProgramSymbolsValid since it currently only serves one purpose. * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp: (WebCore::GraphicsContext3D::precisionsMatch): 2013-12-13 Brent Fulgham [Win] Unreviewed build fix after r160548 * WebCore.vcxproj/WebCoreGenerated.vcxproj: Specify that we are using the vs120_xp build target for Makefile-based projects. 2013-12-13 Joseph Pecoraro Web Inspector: Add Inspector Code Generation to JavaScriptCore for Runtime Domain https://bugs.webkit.org/show_bug.cgi?id=125595 Reviewed by Timothy Hatcher. - CodeGeneration changed to output Frontend and Backend dispatchers in namespace Inspector. So update all the agent's appropriately. - Update Derived Sources code generation to use the Scripts that had moved to JavaScriptCore. Some ports just use JSC/inspector/scripts directly, but others have to use the Scripts exported by JSC in JavaScriptCore's PrivateHeaders. - Add ForwardingHeaders for the files generated in JavaScriptCore. - Update the names of Inspector DerivedSources files, since they were renamed to InspectorWeb*. No new tests, this only moves code around. There are no functional changes. * CMakeLists.txt: * DerivedSources.make: * ForwardingHeaders/inspector/InspectorJSBackendDispatchers.h: Added. * ForwardingHeaders/inspector/InspectorJSFrontendDispatchers.h: Added. * ForwardingHeaders/inspector/InspectorJSTypeBuilders.h: Added. * GNUmakefile.am: * GNUmakefile.list.am: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.vcxproj/build-generated-files.sh: * WebCore.xcodeproj/project.pbxproj: Remove files, rename files, update code generation. * make-generated-sources.sh: Update this standalone developer script to fill in the new InspectorScripts variable. * inspector/ConsoleMessage.h: * inspector/InjectedScriptHost.cpp: * inspector/InspectorAgent.cpp: * inspector/InspectorAgent.h: * inspector/InspectorApplicationCacheAgent.cpp: * inspector/InspectorApplicationCacheAgent.h: * inspector/InspectorCSSAgent.h: * inspector/InspectorCanvasAgent.cpp: * inspector/InspectorCanvasAgent.h: * inspector/InspectorConsoleAgent.cpp: * inspector/InspectorConsoleAgent.h: * inspector/InspectorController.cpp: * inspector/InspectorDOMAgent.cpp: * inspector/InspectorDOMAgent.h: * inspector/InspectorDOMDebuggerAgent.cpp: * inspector/InspectorDOMDebuggerAgent.h: * inspector/InspectorDOMStorageAgent.cpp: * inspector/InspectorDOMStorageAgent.h: * inspector/InspectorDatabaseAgent.cpp: * inspector/InspectorDatabaseAgent.h: * inspector/InspectorDatabaseResource.cpp: * inspector/InspectorDatabaseResource.h: * inspector/InspectorDebuggerAgent.cpp: * inspector/InspectorDebuggerAgent.h: * inspector/InspectorFrontendClientLocal.cpp: * inspector/InspectorHeapProfilerAgent.h: * inspector/InspectorIndexedDBAgent.cpp: * inspector/InspectorIndexedDBAgent.h: * inspector/InspectorInputAgent.h: * inspector/InspectorLayerTreeAgent.cpp: * inspector/InspectorLayerTreeAgent.h: * inspector/InspectorMemoryAgent.cpp: * inspector/InspectorMemoryAgent.h: * inspector/InspectorPageAgent.cpp: * inspector/InspectorPageAgent.h: * inspector/InspectorProfilerAgent.cpp: * inspector/InspectorProfilerAgent.h: * inspector/InspectorResourceAgent.cpp: * inspector/InspectorResourceAgent.h: * inspector/InspectorRuntimeAgent.h: * inspector/InspectorTimelineAgent.cpp: * inspector/InspectorTimelineAgent.h: * inspector/InspectorWorkerAgent.cpp: * inspector/InspectorWorkerAgent.h: * inspector/PageRuntimeAgent.h: * inspector/ScriptCallFrame.cpp: * inspector/WorkerInspectorController.cpp: * inspector/WorkerRuntimeAgent.h: Updates header names and class namespace changes. 2013-12-13 Thiago de Barros Lacerda Adding RTCPeerConnectionErrorCallback https://bugs.webkit.org/show_bug.cgi?id=125574 Reviewed by Eric Carlson. According to the spec there should be a RTCPeerConnectionErrorCallback function type for createOffer/Answer, setLocal/RemoteDescription and updateIce function calls. This callback must handle a DOMError object. Existing tests were updated. * CMakeLists.txt: * GNUmakefile.list.am: * Modules/mediastream/RTCPeerConnection.cpp: (WebCore::RTCPeerConnection::createOffer): (WebCore::RTCPeerConnection::createAnswer): (WebCore::RTCPeerConnection::setLocalDescription): (WebCore::RTCPeerConnection::setRemoteDescription): (WebCore::RTCPeerConnection::addIceCandidate): * Modules/mediastream/RTCErrorCallback.h: Removed. * Modules/mediastream/RTCErrorCallback.idl: Removed. * Modules/mediastream/RTCPeerConnection.h: * Modules/mediastream/RTCPeerConnection.idl: * Modules/mediastream/RTCPeerConnectionErrorCallback.h: Added. * Modules/mediastream/RTCPeerConnectionErrorCallback.idl: Added. * Modules/mediastream/RTCSessionDescriptionRequestImpl.cpp: (WebCore::RTCSessionDescriptionRequestImpl::create): (WebCore::RTCSessionDescriptionRequestImpl::RTCSessionDescriptionRequestImpl): (WebCore::RTCSessionDescriptionRequestImpl::requestFailed): * Modules/mediastream/RTCSessionDescriptionRequestImpl.h: * Modules/mediastream/RTCVoidRequestImpl.cpp: (WebCore::RTCVoidRequestImpl::create): (WebCore::RTCVoidRequestImpl::RTCVoidRequestImpl): (WebCore::RTCVoidRequestImpl::requestFailed): * Modules/mediastream/RTCVoidRequestImpl.h: * WebCore.xcodeproj/project.pbxproj: * platform/mediastream/RTCPeerConnectionHandler.cpp: (WebCore::RTCPeerConnectionHandler::incompatibleConstraintsErrorName): (WebCore::RTCPeerConnectionHandler::invalidSessionDescriptionErrorName): (WebCore::RTCPeerConnectionHandler::incompatibleSessionDescriptionErrorName): (WebCore::RTCPeerConnectionHandler::internalErrorName): * platform/mediastream/RTCPeerConnectionHandler.h: * platform/mock/RTCNotifiersMock.cpp: (WebCore::SessionRequestNotifier::SessionRequestNotifier): (WebCore::SessionRequestNotifier::fire): (WebCore::VoidRequestNotifier::VoidRequestNotifier): (WebCore::VoidRequestNotifier::fire): * platform/mock/RTCNotifiersMock.h: * platform/mock/RTCPeerConnectionHandlerMock.cpp: (WebCore::RTCPeerConnectionHandlerMock::createOffer): (WebCore::RTCPeerConnectionHandlerMock::createAnswer): 2013-12-13 Brent Fulgham [Win] Switch WebKit solution to Visual Studio 2013 https://bugs.webkit.org/show_bug.cgi?id=125192 Reviewed by Anders Carlsson. * WebCore.vcxproj/WebCore.vcxproj: Update for VS2013 * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto * WebCore.vcxproj/WebCoreTestSupport.vcxproj: Ditto 2013-12-13 Alexey Proskuryakov WebCrypto Key.usages should be ordered alphabetically https://bugs.webkit.org/show_bug.cgi?id=125696 Reviewed by Darin Adler. * crypto/CryptoKey.cpp: (WebCore::CryptoKey::usages): Do it. 2013-12-13 Darin Adler Make some optimizations for DOM bindings involving vectors https://bugs.webkit.org/show_bug.cgi?id=125680 Reviewed by Andreas Kling. * bindings/js/JSDOMBinding.h: (WebCore::toJS): Removed unnecessary copying of vectors when converting them to JavaScript values. (WebCore::toRefPtrNativeArray): Use reserveInitialCapacity and uncheckedAppend. (WebCore::toNativeArray): Ditto. (WebCore::toNativeArguments): Ditto. 2013-12-13 Carlos Garcia Campos REGRESSION(r155784): [GTK] Some methods incorrectly removed in r155784 and deprecated in r158662 https://bugs.webkit.org/show_bug.cgi?id=125692 Reviewed by Martin Robinson. In r155784 the build was fixed by skipping Console::profile() and Console::profileEnd(), but the patch also skipped other methods containing the profile method name. Those were incorrectly deprecated in r158662 thinking that the property had been removed in the idl. * bindings/gobject/WebKitDOMDeprecated.cpp: Undeprecate webkit_dom_html_head_element_get_profile and webkit_dom_html_head_element_set_profile. * bindings/gobject/WebKitDOMDeprecated.h: Ditto. * bindings/gobject/WebKitDOMDeprecated.symbols: Ditto. * bindings/scripts/CodeGeneratorGObject.pm: (SkipFunction): Skip webkit_dom_console_profile and webkit_dom_console_profile_end. 2013-12-13 Rob Buis Clean up SVGScriptElement https://bugs.webkit.org/show_bug.cgi?id=125527 Reviewed by Darin Adler. From the Blink port of this bug it becomes clear that svg/dom/SVGScriptElement/script-set-href.svg and svg/dom/svg-element-attribute-js-null.xhtml still hit an assert in Debug because SVGNames::typeAttr can't be used with fastGetAttribute in all cases, because it can be animatable. However for SVGScriptElement it is not animatable, so make isAnimatableAttribute virtual (note Debug only method) and allow typeAttr in the SVGScriptElement case to be useable for fastGetAttribute. Test: svg/dom/SVGScriptElement/script-type-attribute.svg * svg/SVGElement.h: * svg/SVGScriptElement.cpp: (WebCore::SVGScriptElement::isAnimatableAttribute): * svg/SVGScriptElement.h: 2013-12-13 Carlos Garcia Campos [GTK] Expose also webkit_dom_document_get_url https://bugs.webkit.org/show_bug.cgi?id=125691 Reviewed by Martin Robinson. For some reason we expose the URL property, so it can be accessed with g_object_get(), but we have a special case to not provide a public getter. * bindings/gobject/webkitdom.symbols: Add new symbol. * bindings/scripts/CodeGeneratorGObject.pm: (GenerateFunctions): Remove the special case of URL property. 2013-12-13 Andreas Kling CSSFilterImageValue constructor should require both image and filter. Make the CSSFilterImageValue::create() helper take both the image and filter CSSValues by PassRef since they should never be null. Tweaked ComputedStyleExtractor::valueForFilter() to return a PassRef for this to work. Reviewed by Anders Carlsson. 2013-12-12 Andreas Kling StyleResolver::adjustRenderStyle() should take RenderStyle references. This function doesn't handle null styles being passed, so prevent it at compile time. Reviewed by Anders Carlsson. 2013-12-13 Darin Adler Eliminate awkward virtualComputedStyle construction https://bugs.webkit.org/show_bug.cgi?id=125681 Reviewed by Andreas Kling. * dom/Element.cpp: (WebCore::Element::computedStyle): Tweak coding style a bit. * dom/Element.h: Marked computedStyle virtual and got rid of virtualComputedStyle. This fixes a bug that we would not call SVGElement::computedStyle if we called it through an Element pointer or reference. Not sure how to get test coverage for this. * dom/Node.cpp: (WebCore::Node::computedStyle): Use a loop instead of recursive virtual calls. * dom/Node.h: Made computedStyle virtual and got rid of virtualComputedStyle. * svg/SVGElement.cpp: (WebCore::SVGElement::computedStyle): Tweak coding style a bit. * svg/SVGElement.h: Made computedStyle virtual (and FINAL) and got rid fo virtualComputedStyle. 2013-12-13 Darin Adler Fix a couple stray uses of RefPtr that should release https://bugs.webkit.org/show_bug.cgi?id=125679 Reviewed by Andreas Kling. * css/CSSParser.cpp: (WebCore::CSSParser::parseFilter): Add calls to release, in one case rearranging the order of operations slightly so we don't release the pointer before using it. 2013-12-12 Alexey Proskuryakov WebCrypto wrapKey operation doesn't check key usage https://bugs.webkit.org/show_bug.cgi?id=125675 Reviewed by Darin Adler. Tests: crypto/subtle/unwrapKey-check-usage.html crypto/subtle/wrapKey-check-usage.html * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::JSSubtleCrypto::wrapKey): Added accidentally omitted code. Other operations are fine. 2013-12-12 Darin Adler Make some improvements in CSSImageGeneratorValue code https://bugs.webkit.org/show_bug.cgi?id=125676 Reviewed by Simon Fraser. * css/CSSCrossfadeValue.cpp: (WebCore::subimageKnownToBeOpaque): Take a reference to the CSSValue, since it's known not to be null. Used checked cast. (WebCore::CSSCrossfadeValue::knownToBeOpaque): Updated to pass a reference. * css/CSSImageGeneratorValue.cpp: (WebCore::CSSImageGeneratorValue::saveCachedImageForSize): Use make_unique instead of adoptPtr. (WebCore::CSSImageGeneratorValue::subimageIsPending): Use checked cast. (WebCore::CSSImageGeneratorValue::cachedImageForCSSValue): Ditto, also use nullptr. * css/CSSImageGeneratorValue.h: Removed unneeded includes, added some forward declarations, used unique_ptr instead of OwnPtr, and used CSS_VALUE_TYPE_CASTS macro to create cast functions. * css/CSSValue.cpp: Removed unneeded include of CSSImageGeneratorValue.h. * css/StyleResolver.cpp: (WebCore::StyleResolver::State::clear): Use nullptr instead of 0. (WebCore::StyleResolver::applyProperty): Use checked cast and pass references instead of pointers to StyleGeneratedImage::create. (WebCore::StyleResolver::styleImage): Use checked cast and pass references instead of pointers to generatedOrPendingFromValue. (WebCore::StyleResolver::generatedOrPendingFromValue): Take the value as a reference instead of a pointer. (WebCore::StyleResolver::loadPendingImage): Pass a refernece instead of a pointer to StyleGeneratedImage::create. (WebCore::StyleResolver::loadPendingImages): Use auto for iteration instead of a lot type name. * css/StyleResolver.h: Changed generatedOrPendingFromValue to take the value as a reference instead of a pointer. * page/animation/CSSPropertyAnimation.cpp: (WebCore::blendFilter): Pass a reference insted of a pointer to StyleGeneratedImage::create. (WebCore::crossfadeBlend): Ditto. (WebCore::blendFunc): Ditto. Also use references for local variables. * rendering/style/StyleGeneratedImage.cpp: (WebCore::StyleGeneratedImage::StyleGeneratedImage): Use PassRef instead of PassRefPtr for the argument type. (WebCore::StyleGeneratedImage::cssValue): Updated since m_imageGeneratorValue is now a Ref instead of a RefPtr. Sadly this requires a const_cast that we can come back and get rid of later. (WebCore::StyleGeneratedImage::imageSize): Ditto. (WebCore::StyleGeneratedImage::image): Ditto. * rendering/style/StyleGeneratedImage.h: Changed create function and constructor to take a PassRef. Made imageValue non-const since it returns a non-const value, to be consistent with "conceptual const". Changed m_imageGeneratorValue to be a Ref instead of a RefPtr. * rendering/style/StyleImage.h: Made WrappedImagePtr be const void*, since it's a pointer used only for equality checks. Not a great idiom, but fine to use a const pointer instead of non-const, and avoids the const_cast we'd otherwise need in StyleGeneratedImage::data. 2013-12-12 KyungTae Kim Improve the find word boundary performance https://bugs.webkit.org/show_bug.cgi?id=125619 In endWordBoundary case, the textBreakPrevious call in findWordBoundary is unnecessary. So use separate function for endWordBoundary can improve the performance. Reviewed by Darin Adler. No tests because no operation changes. * editing/VisibleUnits.cpp: Use findEndWordBoundary in endWordBoundary (WebCore::endWordBoundary): * platform/text/TextBoundaries.cpp: Add findEndWordBoundary function (WebCore::findEndWordBoundary): * platform/text/TextBoundaries.h: * platform/text/mac/TextBoundaries.mm: Add findEndWordBoundary function (WebCore::findEndWordBoundary): 2013-12-12 Benjamin Poulain Fix a silly mistake of r160467 https://bugs.webkit.org/show_bug.cgi?id=125657 Reviewed by Alexey Proskuryakov. Fix a typo. The validity check was missing the logical not. * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp: (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willSendRequest): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveData): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFinishLoading): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFail): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willCacheResponse): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didSendBodyData): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::shouldUseCredentialStorage): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::canRespondToProtectionSpace): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveDataArray): 2013-12-12 Tim Horton [wk2] Handle pinch-to-zoom gesture https://bugs.webkit.org/show_bug.cgi?id=125604 Reviewed by Simon Fraser. * WebCore.exp.in: Export some TransformationMatrix functions. * WebCore.xcodeproj/project.pbxproj: Make some headers private so that RenderLayerCompositor/Backing can be used from WebKit2. * rendering/RenderLayerCompositor.h: (WebCore::RenderLayerCompositor::layerForContentShadow): Add a getter for the content shadow layer. 2013-12-12 Brady Eidson DatabaseProcess IndexedDB: Establish a metadata backing store on disk https://bugs.webkit.org/show_bug.cgi?id=125258 Reviewed by Alexey Proskuryakov, Anders Carlsson, and Tim Horton. Teach CrossThreadCopier how to handle IDBDatabaseMetadata. * CMakeLists.txt: * GNUmakefile.list.am: * WebCore.exp.in: * WebCore.xcodeproj/project.pbxproj: * Modules/indexeddb/IDBDatabaseMetadata.cpp: Added. (WebCore::IDBDatabaseMetadata::isolatedCopy): (WebCore::IDBObjectStoreMetadata::isolatedCopy): (WebCore::IDBIndexMetadata::isolatedCopy): * Modules/indexeddb/IDBDatabaseMetadata.h: * Modules/indexeddb/IDBKeyPath.cpp: (WebCore::IDBKeyPath::isolatedCopy): * Modules/indexeddb/IDBKeyPath.h: * platform/CrossThreadCopier.cpp: (WebCore::::copy): Add an IDBDatabaseMetadata specialization. * platform/CrossThreadCopier.h: 2013-12-12 Alexey Proskuryakov Add support for RSAES-PKCS1-v1_5 https://bugs.webkit.org/show_bug.cgi?id=125647 Build fix. * crypto/CommonCryptoUtilities.h: Declare a newly used private constant. 2013-12-12 Alexey Proskuryakov Add support for RSAES-PKCS1-v1_5 https://bugs.webkit.org/show_bug.cgi?id=125647 Reviewed by Anders Carlsson. Tests: crypto/subtle/rsaes-pkcs1-v1_5-decrypt.html crypto/subtle/rsaes-pkcs1-v1_5-wrap-unwrap-aes.html * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: * crypto/algorithms/CryptoAlgorithmAES_KW.h: Removed meaningless parameters arguments from private functions. The base arguments class is always empty. * WebCore.xcodeproj/project.pbxproj: * bindings/js/JSCryptoAlgorithmDictionary.cpp: (WebCore::JSCryptoAlgorithmDictionary::createParametersForEncrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDecrypt): * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm): (WebCore::JSCryptoKeySerializationJWK::keySizeIsValid): (WebCore::JSCryptoKeySerializationJWK::addJWKAlgorithmToJSON): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.cpp: Added. (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::CryptoAlgorithmRSAES_PKCS1_v1_5): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::~CryptoAlgorithmRSAES_PKCS1_v1_5): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::create): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::identifier): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::keyAlgorithmMatches): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::encrypt): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::decrypt): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::generateKey): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSAES_PKCS1_v1_5.h: Added. * crypto/mac/CryptoAlgorithmRSAES_PKCS1_v1_5Mac.cpp: Added. (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::platformEncrypt): (WebCore::CryptoAlgorithmRSAES_PKCS1_v1_5::platformDecrypt): * crypto/mac/CryptoAlgorithmRegistryMac.cpp: (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms): Added support for this algorithm. 2013-12-12 Andreas Kling [Mac] Stop not caching HTTP resources with "Vary" header in response. Remove the workaround preventing resources with the "Vary" header from going into cache, as the CFNetwork cache has supported this for quite a while now. 31.5 MB progression on Membuster3, because we can now mmap those resources from disk once they are in the cache. We keep the workaround on PLATFORM(WIN) for now. Reviewed by Antti Koivisto. 2013-12-12 Sam Weinig Replace uses of WTF::BitArray with std::bitset https://bugs.webkit.org/show_bug.cgi?id=125642 Reviewed by Anders Carlsson. * css/CSSParser.cpp: (WebCore::filterProperties): (WebCore::CSSParser::createStyleProperties): * css/StyleProperties.cpp: (WebCore::StyleProperties::asText): 2013-12-12 Alexey Proskuryakov Public key in a generated KeyPair should always be extractable https://bugs.webkit.org/show_bug.cgi?id=125643 Reviewed by Sam Weinig. The spec doesn't explain how generateKey works with key pairs (there are open bugs about that). Making public keys non-extractable makes no sense one way or another. Test: crypto/subtle/rsa-oaep-generate-non-extractable-key.html * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::CryptoKeyRSA::generatePair): 2013-12-12 Alexey Proskuryakov Make algorithm.name return registered name, not normalized one https://bugs.webkit.org/show_bug.cgi?id=125641 Reviewed by Anders Carlsson. Currently, WebCrypto editor's draft stipulates that algorithm name is lowercased as part of normalization. But it makes little sense to register algorithms as mixed (mostly upper) case, yet return the name lowercased. Other implementations don't bother respecting this, and signs are that the spec will change. I'd like to match other implementations here, because sticking to the spec only makes us fail 3rd party test suites for no good reason. Updated many existing tests. * crypto/CryptoAlgorithmRegistry.cpp: (WebCore::CryptoAlgorithmRegistry::getIdentifierForName): (WebCore::CryptoAlgorithmRegistry::registerAlgorithm): * crypto/CryptoAlgorithmRegistry.h: * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: * crypto/algorithms/CryptoAlgorithmSHA1.cpp: * crypto/algorithms/CryptoAlgorithmSHA224.cpp: * crypto/algorithms/CryptoAlgorithmSHA256.cpp: * crypto/algorithms/CryptoAlgorithmSHA384.cpp: * crypto/algorithms/CryptoAlgorithmSHA512.cpp: 2013-12-12 Csaba Osztrogonác Move CertificateInfo to WebCore https://bugs.webkit.org/show_bug.cgi?id=124720 Reviewed by Darin Adler. Based on the patch by Kwang Yul Seo * GNUmakefile.list.am: * PlatformEfl.cmake: * PlatformGTK.cmake: * WebCore.exp.in: * WebCore.xcodeproj/project.pbxproj: * platform/network/mac/CertificateInfo.h: Renamed from Source/WebKit2/Shared/mac/CertificateInfo.h. (WebCore::CertificateInfo::setCertificateChain): Added, because WebCoreArgumentCoders needs it. * platform/network/mac/CertificateInfoMac.mm: Renamed from Source/WebKit2/Shared/mac/CertificateInfo.mm. (WebCore::CertificateInfo::CertificateInfo): Moved encode() and decode() to WebCoreArgumentCodersMac.mm. * platform/network/soup/CertificateInfo.cpp: Copied from Source/WebKit2/Shared/WebCertificateInfo.h. (WebCore::CertificateInfo::CertificateInfo): Moved encode() and decode() to WebCoreArgumentCodersSoup.cpp. * platform/network/soup/CertificateInfo.h: Renamed from Source/WebKit2/Shared/soup/CertificateInfo.h. (WebCore::CertificateInfo::setCertificate): Added, because WebCoreArgumentCoders needs it. (WebCore::CertificateInfo::setTLSErrors): Added, because WebCoreArgumentCoders needs it. 2013-12-12 Commit Queue Unreviewed, rolling out r160417. http://trac.webkit.org/changeset/160417 https://bugs.webkit.org/show_bug.cgi?id=125629 The patch is causing crashes (Requested by zdobersek1 on #webkit). * accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::~AXObjectCache): (WebCore::AXObjectCache::remove): * accessibility/AXObjectCache.h: (WebCore::AXObjectCache::detachWrapper): * accessibility/atk/AXObjectCacheAtk.cpp: (WebCore::AXObjectCache::detachWrapper): (WebCore::AXObjectCache::attachWrapper): (WebCore::AXObjectCache::postPlatformNotification): * accessibility/ios/AXObjectCacheIOS.mm: (WebCore::AXObjectCache::detachWrapper): * accessibility/mac/AXObjectCacheMac.mm: (WebCore::AXObjectCache::detachWrapper): * accessibility/win/AXObjectCacheWin.cpp: (WebCore::AXObjectCache::detachWrapper): 2013-12-12 Martin Robinson Remove a few more guards mistakenly added in r160367 Reviewed by Carlos Garcia Campos r160367 was too liberal in hiding APIs from the GObject DOM bindings. We should expose the BatteryManager and the text and audio tracks. * Modules/battery/BatteryManager.idl: * html/HTMLMediaElement.idl: 2013-12-11 Darin Adler StylePendingImage needs to correctly manage the CSSValue pointer lifetime https://bugs.webkit.org/show_bug.cgi?id=125468 Reviewed by Andreas Kling. Test: fast/css/pending-image-crash.xhtml Disconnect the reference counted StylePendingImage from the CSSValue that owns it when it's not needed any more, otherwise we could end up using a pointer that might no longer be valid. * css/CSSCursorImageValue.cpp: (WebCore::CSSCursorImageValue::detachPendingImage): Added. Calls detachFromCSSValue on the current image if it is a StylePendingImage. (WebCore::CSSCursorImageValue::~CSSCursorImageValue): Call detachPendingImage. (WebCore::CSSCursorImageValue::cachedImage): Call detachPendingImage before changing m_image to a new value. (WebCore::CSSCursorImageValue::clearCachedImage): Ditto. * css/CSSCursorImageValue.h: Added detachPendingImage. * css/CSSImageSetValue.cpp: (WebCore::CSSImageSetValue::detachPendingImage): Added. Calls detachFromCSSValue on the current image set if it is a StylePendingImage. (WebCore::CSSImageSetValue::~CSSImageSetValue): Call detachPendingImage. (WebCore::CSSImageSetValue::cachedImageSet): Call detachPendingImage before changing m_imageSet to a new value. * css/CSSImageSetValue.h: Added detachPendingImage. * css/CSSImageValue.cpp: (WebCore::CSSImageValue::detachPendingImage): Added. Calls detachFromCSSValue on the current image if it is a StylePendingImage. (WebCore::CSSImageValue::~CSSImageValue): Call detachPendingImage. (WebCore::CSSImageValue::cachedImage): Call detachPendingImage before changing m_image to a new value. * css/CSSImageValue.h: Added detachPendingImage. * rendering/style/StylePendingImage.h: (WebCore::StylePendingImage::cssImageValue): Added a null check. (WebCore::StylePendingImage::cssImageGeneratorValue): Added a null check. (WebCore::StylePendingImage::cssCursorImageValue): Added a null check. (WebCore::StylePendingImage::cssImageSetValue): Added a null check. (WebCore::StylePendingImage::detachFromCSSValue): Added. Sets m_value to null since the style is no longer using this StylePendingImage. (WebCore::StylePendingImage::data): Changed to use the "this" pointer since all we need is some arbitrary pointer uniquely identifying the image. Before loading the image, we have no suitable weak identifier, so it suffices to use the unique pointer to each StylePendingImage object. This function is used only in a limited way; it would be nice to find a way to make the code less strange long term. 2013-12-11 Darin Adler Remove some unneeded code noticed while looking at StylePendingImage https://bugs.webkit.org/show_bug.cgi?id=125618 Reviewed by Andreas Kling. * css/StyleResolver.cpp: (WebCore::StyleResolver::loadPendingImage): Removed redundant function calls. * rendering/RenderImageResource.cpp: Removed unneeded nullImage and usesImageContainerSize member functions. (WebCore::RenderImageResource::image): Use Image::nullImage directly instead of through RenderImageResourceImage::nullImage. * rendering/RenderImageResource.h: Removed unneeded usesImageContainerSize and nullImage functions. Also removed unneeded includes. * rendering/RenderImageResourceStyleImage.h: Removed unneeded usesImageContainerSize override. Nobody was calling it. 2013-12-11 Benjamin Poulain Add the CFNetwork implementation of the asynchronous ResourceHandle https://bugs.webkit.org/show_bug.cgi?id=124440 Reviewed by Alexey Proskuryakov. Add a second subclass of ResourceHandleCFURLConnectionDelegate: ResourceHandleCFURLConnectionDelegateWithOperationQueue. The difference is those objects handle the network callback on a different queue. Some common code has been refactored in ResourceHandleCFURLConnectionDelegate to reduce duplicated code. The initialization of the request and connection is moved to the subclass to clean up initialization. * WebCore.xcodeproj/project.pbxproj: * platform/network/ResourceHandle.h: * platform/network/ResourceHandleClient.cpp: (WebCore::ResourceHandleClient::willCacheResponseAsync): * platform/network/ResourceHandleClient.h: * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.cpp: Added. (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::ResourceHandleCFURLConnectionDelegateWithOperationQueue): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::~ResourceHandleCFURLConnectionDelegateWithOperationQueue): (WebCore::connectionWasCancelled): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::setupRequest): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::setupConnectionScheduling): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willSendRequest): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveResponse): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveData): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFinishLoading): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didFail): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::willCacheResponse): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveChallenge): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didSendBodyData): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::shouldUseCredentialStorage): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::canRespondToProtectionSpace): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::didReceiveDataArray): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::continueWillSendRequest): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::continueDidReceiveResponse): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::continueShouldUseCredentialStorage): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::continueWillCacheResponse): (WebCore::ResourceHandleCFURLConnectionDelegateWithOperationQueue::continueCanAuthenticateAgainstProtectionSpace): * platform/network/cf/ResourceHandleCFURLConnectionDelegateWithOperationQueue.h: Copied from Source/WebCore/platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h. * platform/network/cf/ResourceHandleCFNet.cpp: (WebCore::ResourceHandleInternal::~ResourceHandleInternal): (WebCore::ResourceHandle::createCFURLConnection): (WebCore::ResourceHandle::start): (WebCore::ResourceHandle::shouldUseCredentialStorage): (WebCore::ResourceHandle::canAuthenticateAgainstProtectionSpace): (WebCore::ResourceHandle::continueWillSendRequest): (WebCore::ResourceHandle::continueDidReceiveResponse): (WebCore::ResourceHandle::continueShouldUseCredentialStorage): (WebCore::ResourceHandle::continueCanAuthenticateAgainstProtectionSpace): (WebCore::ResourceHandle::continueWillCacheResponse): * platform/network/cf/ResourceHandleCFURLConnectionDelegate.cpp: (WebCore::ResourceHandleCFURLConnectionDelegate::releaseHandle): (WebCore::ResourceHandleCFURLConnectionDelegate::synthesizeRedirectResponseIfNecessary): (WebCore::ResourceHandleCFURLConnectionDelegate::createResourceRequest): * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h: * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp: (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::setupRequest): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::setupConnectionScheduling): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::willSendRequest): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::continueWillSendRequest): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::continueDidReceiveResponse): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::continueShouldUseCredentialStorage): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::continueWillCacheResponse): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::continueCanAuthenticateAgainstProtectionSpace): * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h: 2013-12-11 David Kilzer Define m_hasBadParent in InlineBox if defined(ADDRESS_SANITIZER) Reviewed by Darin Adler. No tests since this is a build fix for: $ ./Tools/Scripts/build-webkit --release OTHER_CFLAGS="$inherited -DADDRESS_SANITIZER=1" * rendering/InlineBox.cpp: * rendering/InlineBox.h: - Replace ASSERT_DISABLED use with ASSERT_WITH_SECURITY_IMPLICATION_DISABLED for m_hasBadParent. * rendering/InlineFlowBox.cpp: (WebCore::InlineFlowBox::~InlineFlowBox): - Use !ASSERT_WITH_SECURITY_IMPLICATION_DISABLED instead of #ifndef NDEBUG since this calls setHasBadParent(). (WebCore::InlineFlowBox::checkConsistency): - Move ASSERT(!m_hasBadChildList) outside of #if CHECK_CONSISTENCY and change to ASSERT_WITH_SECURITY_IMPLICATION(!m_hasBadChildList). * rendering/InlineFlowBox.h: (WebCore::InlineFlowBox::InlineFlowBox): (WebCore::InlineFlowBox::setHasBadChildList): - Change #ifndef NDEBUG to #if !ASSERT_WITH_SECURITY_IMPLICATION_DISABLED for code using m_hasBadChildList. 2013-12-11 Ralph Thomas [WebGL] Fix build on GL ES 2.0 targets after r160119 https://bugs.webkit.org/show_bug.cgi?id=125541 Reviewed by Brent Fulgham. GL ES 2.0 doesn't define GL_HALF_FLOAT_ARB, so pass through HALF_FLOAT_OES (which is defined for GL ES 2.0). This change also reverts r160324 which incorrectly defined GL_HALF_FLOAT_ARB for the Windows ANGLE target. No new tests, no change in functionality. * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp: (WebCore::GraphicsContext3D::texSubImage2D): 2013-12-11 Joseph Pecoraro Web Inspector: Push More Inspector Required Classes Down into JavaScriptCore https://bugs.webkit.org/show_bug.cgi?id=125324 Reviewed by Timothy Hatcher. Part 1: Push down core inspector classes. - Move InspectAgentBase, InspectorAgentRegistry, InspectorBackendDispatcher, InspectorValues down to JavaScriptCore and into the Inspector namespace. - Add forwarding headers for JavaScriptCore/inspector files. - Use the Inspector namespace where appropriate. - Rename InspectorBaseAgent to InspectorAgentBase for clarity. Part 2: Push Script wrapper classes down into JavaScriptCore/bindings. - Move ScriptObject and ScriptValue into JavaScriptCore but namespace Deprecated - Add forwarding headers - Use Deprecated::ScriptObject and Deprecated::ScriptValue everywhere. Part 3: Push Down ScriptFunctionCall - Move ScriptFunctionCall to JavaScriptCore/bindings into namespace Deprecated. - Give constructor a function to all for a different JSC::call, because WebCore ScriptFunctionCall's use JSMainThreadExecState when isMainThread. - Prefer Deprecated::ScriptFunctionCall everywhere it is used in WebCore. Part 4: Extract InspectorTypeBuilder helper functions - There is a chunk of InspectorTypeBuilder that never changes. Extract it into its own file, InspectorTypeBuilder.h in JSC/inspector, Inspector namespace. - This moves TypeBuilder from namespace WebCore to namespace Inspector - Rename the WebCore generated InspectorTypeBuilder to InspectorWebTypeBuilders, eventually the CodeGenerator script will do this for more then TypeBuilders and there will be "JS" TypeBuilders and "Web" TypeBuilders files. No new tests. No change in functionality, just moving things around. * CMakeLists.txt: * ForwardingHeaders/bindings/ScriptFunctionCall.h: Added. * ForwardingHeaders/bindings/ScriptObject.h: Added. * ForwardingHeaders/bindings/ScriptValue.h: Added. * ForwardingHeaders/inspector/InspectorAgentBase.h: Added. * ForwardingHeaders/inspector/InspectorAgentRegistry.h: Added. * ForwardingHeaders/inspector/InspectorBackendDispatcher.h: Added. * ForwardingHeaders/inspector/InspectorTypeBuilder.h: Added. * ForwardingHeaders/inspector/InspectorValues.h: Added. * GNUmakefile.am: * GNUmakefile.list.am: * Modules/indexeddb/IDBAny.cpp: (WebCore::IDBAny::scriptValue): (WebCore::IDBAny::IDBAny): * Modules/indexeddb/IDBAny.h: * Modules/indexeddb/IDBCursor.cpp: (WebCore::IDBCursor::key): (WebCore::IDBCursor::primaryKey): (WebCore::IDBCursor::value): (WebCore::IDBCursor::update): (WebCore::IDBCursor::continueFunction): (WebCore::IDBCursor::setValueReady): * Modules/indexeddb/IDBCursor.h: * Modules/indexeddb/IDBFactory.cpp: (WebCore::IDBFactory::cmp): * Modules/indexeddb/IDBFactory.h: * Modules/indexeddb/IDBIndex.cpp: (WebCore::IDBIndex::openCursor): (WebCore::IDBIndex::count): (WebCore::IDBIndex::openKeyCursor): (WebCore::IDBIndex::get): (WebCore::IDBIndex::getKey): * Modules/indexeddb/IDBIndex.h: (WebCore::IDBIndex::openCursor): (WebCore::IDBIndex::openKeyCursor): * Modules/indexeddb/IDBKeyRange.cpp: (WebCore::IDBKeyRange::lowerValue): (WebCore::IDBKeyRange::upperValue): (WebCore::IDBKeyRange::only): (WebCore::IDBKeyRange::lowerBound): (WebCore::IDBKeyRange::upperBound): (WebCore::IDBKeyRange::bound): * Modules/indexeddb/IDBKeyRange.h: (WebCore::IDBKeyRange::lowerBound): (WebCore::IDBKeyRange::upperBound): (WebCore::IDBKeyRange::bound): * Modules/indexeddb/IDBObjectStore.cpp: (WebCore::IDBObjectStore::get): (WebCore::generateIndexKeysForValue): (WebCore::IDBObjectStore::add): (WebCore::IDBObjectStore::put): (WebCore::IDBObjectStore::deleteFunction): (WebCore::IDBObjectStore::openCursor): (WebCore::IDBObjectStore::count): * Modules/indexeddb/IDBObjectStore.h: * Modules/indexeddb/IDBRequest.cpp: (WebCore::IDBRequest::setResultCursor): (WebCore::IDBRequest::onSuccess): (WebCore::IDBRequest::onSuccessInternal): * Modules/indexeddb/IDBRequest.h: * Modules/mediastream/CapabilityRange.cpp: (WebCore::scriptValue): (WebCore::CapabilityRange::min): (WebCore::CapabilityRange::max): * Modules/mediastream/CapabilityRange.h: * Modules/mediastream/MediaTrackConstraint.h: * Modules/mediastream/RTCIceCandidate.cpp: * Modules/plugins/QuickTimePluginReplacement.cpp: * Modules/plugins/QuickTimePluginReplacement.h: * UseJSC.cmake: * WebCore.exp.in: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.xcodeproj/project.pbxproj: * bindings/js/Dictionary.h: (WebCore::Dictionary::getEventListener): * bindings/js/IDBBindingUtilities.cpp: (WebCore::createIDBKeyFromScriptValueAndKeyPath): (WebCore::injectIDBKeyIntoScriptValue): (WebCore::canInjectIDBKeyIntoScriptValue): (WebCore::deserializeIDBValue): (WebCore::deserializeIDBValueBuffer): (WebCore::idbKeyToScriptValue): (WebCore::scriptValueToIDBKey): * bindings/js/IDBBindingUtilities.h: * bindings/js/JSBindingsAllInOne.cpp: * bindings/js/JSDictionary.cpp: (WebCore::JSDictionary::convertValue): * bindings/js/JSDictionary.h: * bindings/js/JSHTMLCanvasElementCustom.cpp: (WebCore::JSHTMLCanvasElement::getContext): * bindings/js/JSInjectedScriptHostCustom.cpp: (WebCore::InjectedScriptHost::scriptValueAsNode): (WebCore::InjectedScriptHost::nodeAsScriptValue): (WebCore::JSInjectedScriptHost::inspectedObject): (WebCore::JSInjectedScriptHost::inspect): * bindings/js/JSInjectedScriptManager.cpp: (WebCore::InjectedScriptManager::createInjectedScript): * bindings/js/JSMainThreadExecState.cpp: (WebCore::functionCallHandlerFromAnyThread): * bindings/js/JSMainThreadExecState.h: (WebCore::JSMainThreadExecState::currentState): * bindings/js/JSMessageEventCustom.cpp: (WebCore::JSMessageEvent::data): (WebCore::handleInitMessageEvent): * bindings/js/ScheduledAction.cpp: * bindings/js/ScriptCallStackFactory.cpp: (WebCore::createScriptArguments): * bindings/js/ScriptController.cpp: (WebCore::ScriptController::evaluateInWorld): (WebCore::ScriptController::evaluate): (WebCore::ScriptController::executeScriptInWorld): (WebCore::ScriptController::executeScript): (WebCore::ScriptController::executeIfJavaScriptURL): * bindings/js/ScriptController.h: * bindings/js/ScriptDebugServer.cpp: (WebCore::ScriptDebugServer::setScriptSource): (WebCore::ScriptDebugServer::updateCallStack): (WebCore::ScriptDebugServer::dispatchDidPause): (WebCore::ScriptDebugServer::runScript): * bindings/js/ScriptDebugServer.h: * bindings/js/ScriptGlobalObject.cpp: Renamed from Source/WebCore/bindings/js/ScriptObject.cpp. (WebCore::handleException): (WebCore::ScriptGlobalObject::set): (WebCore::ScriptGlobalObject::get): (WebCore::ScriptGlobalObject::remove): * bindings/js/ScriptGlobalObject.h: Copied from Source/WebCore/inspector/ScriptCallStack.h. (WebCore::ScriptGlobalObject::ScriptGlobalObject): * bindings/js/ScriptObject.h: Removed. * bindings/js/ScriptProfile.cpp: (WebCore::buildInspectorObjectFor): (WebCore::ScriptProfile::buildInspectorObjectForHead): (WebCore::ScriptProfile::buildInspectorObjectForBottomUpHead): * bindings/js/ScriptProfile.h: * bindings/js/ScriptProfiler.cpp: (WebCore::ScriptProfiler::objectByHeapObjectId): (WebCore::ScriptProfiler::getHeapObjectId): * bindings/js/ScriptProfiler.h: * bindings/js/ScriptState.h: * bindings/js/SerializedScriptValue.cpp: (WebCore::SerializedScriptValue::deserializeForInspector): (WebCore::SerializedScriptValue::serialize): (WebCore::SerializedScriptValue::deserialize): * bindings/js/SerializedScriptValue.h: * bindings/js/WorkerScriptController.cpp: (WebCore::WorkerScriptController::evaluate): (WebCore::WorkerScriptController::setException): * bindings/js/WorkerScriptController.h: * bindings/scripts/CodeGeneratorJS.pm: * bindings/scripts/test/JS/JSTestObj.cpp: (WebCore::setJSTestObjAnyAttribute): * dom/CustomEvent.cpp: (WebCore::CustomEvent::initCustomEvent): * dom/CustomEvent.h: (WebCore::CustomEvent::detail): * dom/MessageEvent.cpp: (WebCore::MessageEvent::MessageEvent): (WebCore::MessageEvent::initMessageEvent): * dom/MessageEvent.h: (WebCore::MessageEvent::create): (WebCore::MessageEvent::dataAsScriptValue): * dom/PopStateEvent.h: (WebCore::PopStateEvent::state): * dom/ScriptElement.cpp: * html/HTMLMediaElement.cpp: * html/parser/XSSAuditor.cpp: * html/parser/XSSAuditorDelegate.cpp: * inspector/CodeGeneratorInspector.py: (RawTypes.BaseType.get_raw_validator_call_text): (RawTypes.Object.get_array_item_raw_c_type_text): (RawTypes.Any.get_array_item_raw_c_type_text): (RawTypes.Array.get_array_item_raw_c_type_text): (CommandReturnPassModel.OptOutput.get_return_var_type): (CommandReturnPassModel.OptOutput.get_output_parameter_type): (TypeModel.ExactlyInt.get_input_param_type_text): (TypeModel.ExactlyInt.get_opt_output_type_): (TypeModel.init_class): (TypeBindings.create_named_type_declaration.Helper): (TypeBindings.create_type_declaration_.EnumBinding.get_code_generator.CodeGenerator.generate_type_builder): (TypeBindings.create_type_declaration_.EnumBinding.get_setter_value_expression_pattern): (TypeBindings.create_type_declaration_.ClassBinding.get_code_generator.CodeGenerator.generate_type_builder): (Inspector): (ArrayBinding.get_array_item_c_type_text): (Generator.go): (Generator.process_command): * inspector/CodeGeneratorInspectorStrings.py: (void): (InspectorFrontend_h): (InspectorBackendDispatchers_h): * inspector/ConsoleMessage.cpp: (WebCore::messageSourceValue): (WebCore::messageTypeValue): (WebCore::messageLevelValue): (WebCore::ConsoleMessage::addToFrontend): * inspector/ConsoleMessage.h: * inspector/ContentSearchUtils.cpp: (WebCore::ContentSearchUtils::buildObjectForSearchMatch): (WebCore::ContentSearchUtils::searchInTextByLines): * inspector/ContentSearchUtils.h: * inspector/InjectedScript.cpp: (WebCore::InjectedScript::InjectedScript): (WebCore::InjectedScript::evaluate): (WebCore::InjectedScript::callFunctionOn): (WebCore::InjectedScript::evaluateOnCallFrame): (WebCore::InjectedScript::getFunctionDetails): (WebCore::InjectedScript::getProperties): (WebCore::InjectedScript::getInternalProperties): (WebCore::InjectedScript::nodeForObjectId): (WebCore::InjectedScript::releaseObject): (WebCore::InjectedScript::wrapCallFrames): (WebCore::InjectedScript::wrapObject): (WebCore::InjectedScript::wrapTable): (WebCore::InjectedScript::wrapNode): (WebCore::InjectedScript::findObjectById): (WebCore::InjectedScript::inspectNode): (WebCore::InjectedScript::releaseObjectGroup): (WebCore::InjectedScript::nodeAsScriptValue): * inspector/InjectedScript.h: * inspector/InjectedScriptBase.cpp: (WebCore::InjectedScriptBase::InjectedScriptBase): (WebCore::InjectedScriptBase::initialize): (WebCore::InjectedScriptBase::injectedScriptObject): (WebCore::InjectedScriptBase::callFunctionWithEvalEnabled): (WebCore::InjectedScriptBase::makeCall): (WebCore::InjectedScriptBase::makeEvalCall): * inspector/InjectedScriptBase.h: * inspector/InjectedScriptCanvasModule.cpp: (WebCore::InjectedScriptCanvasModule::wrapCanvas2DContext): (WebCore::InjectedScriptCanvasModule::wrapWebGLContext): (WebCore::InjectedScriptCanvasModule::callWrapContextFunction): (WebCore::InjectedScriptCanvasModule::markFrameEnd): (WebCore::InjectedScriptCanvasModule::callStartCapturingFunction): (WebCore::InjectedScriptCanvasModule::callVoidFunctionWithTraceLogIdArgument): (WebCore::InjectedScriptCanvasModule::traceLog): (WebCore::InjectedScriptCanvasModule::replayTraceLog): (WebCore::InjectedScriptCanvasModule::resourceInfo): (WebCore::InjectedScriptCanvasModule::resourceState): * inspector/InjectedScriptCanvasModule.h: * inspector/InjectedScriptHost.cpp: (WebCore::InjectedScriptHost::inspectImpl): (WebCore::InjectedScriptHost::InspectableObject::get): * inspector/InjectedScriptHost.h: * inspector/InjectedScriptManager.cpp: (WebCore::InjectedScriptManager::injectedScriptFor): * inspector/InjectedScriptManager.h: * inspector/InjectedScriptModule.cpp: (WebCore::InjectedScriptModule::ensureInjected): * inspector/InspectorAgent.cpp: (WebCore::InspectorAgent::InspectorAgent): (WebCore::InspectorAgent::didCreateFrontendAndBackend): (WebCore::InspectorAgent::inspect): * inspector/InspectorAgent.h: * inspector/InspectorAllInOne.cpp: * inspector/InspectorApplicationCacheAgent.cpp: (WebCore::InspectorApplicationCacheAgent::InspectorApplicationCacheAgent): (WebCore::InspectorApplicationCacheAgent::didCreateFrontendAndBackend): (WebCore::InspectorApplicationCacheAgent::getFramesWithManifests): (WebCore::InspectorApplicationCacheAgent::getApplicationCacheForFrame): (WebCore::InspectorApplicationCacheAgent::buildObjectForApplicationCache): (WebCore::InspectorApplicationCacheAgent::buildArrayForApplicationCacheResources): (WebCore::InspectorApplicationCacheAgent::buildObjectForApplicationCacheResource): * inspector/InspectorApplicationCacheAgent.h: * inspector/InspectorCSSAgent.cpp: (WebCore::SelectorProfile::toInspectorObject): (WebCore::InspectorCSSAgent::InspectorCSSAgent): (WebCore::InspectorCSSAgent::didCreateFrontendAndBackend): (WebCore::InspectorCSSAgent::getMatchedStylesForNode): (WebCore::InspectorCSSAgent::getInlineStylesForNode): (WebCore::InspectorCSSAgent::getComputedStyleForNode): (WebCore::InspectorCSSAgent::getAllStyleSheets): (WebCore::InspectorCSSAgent::getStyleSheet): (WebCore::InspectorCSSAgent::setStyleText): (WebCore::InspectorCSSAgent::setPropertyText): (WebCore::InspectorCSSAgent::toggleProperty): (WebCore::InspectorCSSAgent::setRuleSelector): (WebCore::InspectorCSSAgent::addRule): (WebCore::InspectorCSSAgent::getSupportedCSSProperties): (WebCore::InspectorCSSAgent::getNamedFlowCollection): (WebCore::InspectorCSSAgent::stopSelectorProfiler): (WebCore::InspectorCSSAgent::stopSelectorProfilerImpl): (WebCore::InspectorCSSAgent::asInspectorStyleSheet): (WebCore::InspectorCSSAgent::collectStyleSheets): (WebCore::InspectorCSSAgent::viaInspectorStyleSheet): (WebCore::InspectorCSSAgent::detectOrigin): (WebCore::InspectorCSSAgent::buildObjectForRule): (WebCore::InspectorCSSAgent::buildArrayForRuleList): (WebCore::InspectorCSSAgent::buildArrayForMatchedRuleList): (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle): (WebCore::InspectorCSSAgent::buildArrayForRegions): (WebCore::InspectorCSSAgent::buildObjectForNamedFlow): * inspector/InspectorCSSAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::InspectorCanvasAgent): (WebCore::InspectorCanvasAgent::didCreateFrontendAndBackend): (WebCore::InspectorCanvasAgent::wrapCanvas2DRenderingContextForInstrumentation): (WebCore::InspectorCanvasAgent::wrapWebGLRenderingContextForInstrumentation): (WebCore::InspectorCanvasAgent::notifyRenderingContextWasWrapped): (WebCore::InspectorCanvasAgent::injectedScriptCanvasModule): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasInstrumentation.h: (WebCore::InspectorInstrumentation::wrapCanvas2DRenderingContextForInstrumentation): (WebCore::InspectorInstrumentation::wrapWebGLRenderingContextForInstrumentation): * inspector/InspectorClient.cpp: * inspector/InspectorClient.h: * inspector/InspectorConsoleAgent.cpp: (WebCore::InspectorConsoleAgent::InspectorConsoleAgent): (WebCore::InspectorConsoleAgent::didCreateFrontendAndBackend): (WebCore::InspectableHeapObject::get): * inspector/InspectorConsoleAgent.h: * inspector/InspectorController.cpp: * inspector/InspectorController.h: * inspector/InspectorDOMAgent.cpp: (WebCore::InspectorDOMAgent::InspectorDOMAgent): (WebCore::InspectorDOMAgent::didCreateFrontendAndBackend): (WebCore::InspectorDOMAgent::getDocument): (WebCore::InspectorDOMAgent::pushChildNodesToFrontend): (WebCore::InspectorDOMAgent::querySelectorAll): (WebCore::InspectorDOMAgent::pushNodePathToFrontend): (WebCore::InspectorDOMAgent::getEventListenersForNode): (WebCore::InspectorDOMAgent::getSearchResults): (WebCore::InspectorDOMAgent::resolveNode): (WebCore::InspectorDOMAgent::getAttributes): (WebCore::InspectorDOMAgent::buildObjectForNode): (WebCore::InspectorDOMAgent::buildArrayForElementAttributes): (WebCore::InspectorDOMAgent::buildArrayForContainerChildren): (WebCore::InspectorDOMAgent::buildObjectForEventListener): (WebCore::InspectorDOMAgent::didCommitLoad): (WebCore::InspectorDOMAgent::didInsertDOMNode): (WebCore::InspectorDOMAgent::styleAttributeInvalidated): * inspector/InspectorDOMAgent.h: * inspector/InspectorDOMDebuggerAgent.cpp: (WebCore::InspectorDOMDebuggerAgent::InspectorDOMDebuggerAgent): (WebCore::InspectorDOMDebuggerAgent::didCreateFrontendAndBackend): (WebCore::InspectorDOMDebuggerAgent::descriptionForDOMEvent): * inspector/InspectorDOMDebuggerAgent.h: * inspector/InspectorDOMStorageAgent.cpp: (WebCore::InspectorDOMStorageAgent::InspectorDOMStorageAgent): (WebCore::InspectorDOMStorageAgent::didCreateFrontendAndBackend): (WebCore::InspectorDOMStorageAgent::getDOMStorageItems): (WebCore::InspectorDOMStorageAgent::storageId): (WebCore::InspectorDOMStorageAgent::didDispatchDOMStorageEvent): * inspector/InspectorDOMStorageAgent.h: * inspector/InspectorDatabaseAgent.cpp: (WebCore::InspectorDatabaseAgent::InspectorDatabaseAgent): (WebCore::InspectorDatabaseAgent::didCreateFrontendAndBackend): (WebCore::InspectorDatabaseAgent::getDatabaseTableNames): * inspector/InspectorDatabaseAgent.h: * inspector/InspectorDatabaseResource.cpp: (WebCore::InspectorDatabaseResource::bind): * inspector/InspectorDebuggerAgent.cpp: (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent): (WebCore::InspectorDebuggerAgent::didCreateFrontendAndBackend): (WebCore::breakpointActionTypeForString): (WebCore::InspectorDebuggerAgent::setBreakpointByUrl): (WebCore::InspectorDebuggerAgent::setBreakpoint): (WebCore::InspectorDebuggerAgent::resolveBreakpoint): (WebCore::scriptToInspectorObject): (WebCore::InspectorDebuggerAgent::searchInContent): (WebCore::InspectorDebuggerAgent::setScriptSource): (WebCore::InspectorDebuggerAgent::getFunctionDetails): (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame): (WebCore::InspectorDebuggerAgent::compileScript): (WebCore::InspectorDebuggerAgent::runScript): (WebCore::InspectorDebuggerAgent::currentCallFrames): (WebCore::InspectorDebuggerAgent::didParseSource): (WebCore::InspectorDebuggerAgent::didPause): (WebCore::InspectorDebuggerAgent::didContinue): (WebCore::InspectorDebuggerAgent::clear): * inspector/InspectorDebuggerAgent.h: * inspector/InspectorForwarding.h: * inspector/InspectorFrontendClientLocal.cpp: (WebCore::InspectorFrontendClientLocal::evaluateAsBoolean): * inspector/InspectorFrontendHost.cpp: (WebCore::FrontendMenuProvider::create): (WebCore::FrontendMenuProvider::disconnect): (WebCore::FrontendMenuProvider::FrontendMenuProvider): (WebCore::FrontendMenuProvider::contextMenuItemSelected): (WebCore::FrontendMenuProvider::contextMenuCleared): (WebCore::InspectorFrontendHost::showContextMenu): * inspector/InspectorHeapProfilerAgent.cpp: (WebCore::InspectorHeapProfilerAgent::InspectorHeapProfilerAgent): (WebCore::InspectorHeapProfilerAgent::didCreateFrontendAndBackend): (WebCore::InspectorHeapProfilerAgent::createSnapshotHeader): (WebCore::InspectorHeapProfilerAgent::getProfileHeaders): (WebCore::InspectorHeapProfilerAgent::getObjectByHeapObjectId): (WebCore::InspectorHeapProfilerAgent::getHeapObjectId): * inspector/InspectorHeapProfilerAgent.h: * inspector/InspectorIndexedDBAgent.cpp: (WebCore::InspectorIndexedDBAgent::InspectorIndexedDBAgent): (WebCore::InspectorIndexedDBAgent::didCreateFrontendAndBackend): * inspector/InspectorIndexedDBAgent.h: * inspector/InspectorInputAgent.cpp: (WebCore::InspectorInputAgent::InspectorInputAgent): (WebCore::InspectorInputAgent::didCreateFrontendAndBackend): * inspector/InspectorInputAgent.h: * inspector/InspectorInstrumentation.cpp: * inspector/InspectorInstrumentation.h: * inspector/InspectorLayerTreeAgent.cpp: (WebCore::InspectorLayerTreeAgent::InspectorLayerTreeAgent): (WebCore::InspectorLayerTreeAgent::didCreateFrontendAndBackend): (WebCore::InspectorLayerTreeAgent::layersForNode): (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderObjectHierarchy): (WebCore::InspectorLayerTreeAgent::gatherLayersUsingRenderLayerHierarchy): (WebCore::InspectorLayerTreeAgent::buildObjectForLayer): (WebCore::InspectorLayerTreeAgent::buildObjectForIntRect): (WebCore::InspectorLayerTreeAgent::reasonsForCompositingLayer): * inspector/InspectorLayerTreeAgent.h: * inspector/InspectorMemoryAgent.cpp: (WebCore::InspectorMemoryAgent::didCreateFrontendAndBackend): (WebCore::InspectorMemoryAgent::InspectorMemoryAgent): * inspector/InspectorMemoryAgent.h: * inspector/InspectorOverlay.cpp: * inspector/InspectorOverlay.h: * inspector/InspectorPageAgent.cpp: (WebCore::InspectorPageAgent::resourceTypeJson): (WebCore::InspectorPageAgent::cachedResourceTypeJson): (WebCore::InspectorPageAgent::InspectorPageAgent): (WebCore::InspectorPageAgent::didCreateFrontendAndBackend): (WebCore::buildObjectForCookie): (WebCore::buildArrayForCookies): (WebCore::InspectorPageAgent::getCookies): (WebCore::InspectorPageAgent::getResourceTree): (WebCore::InspectorPageAgent::searchInResource): (WebCore::buildObjectForSearchResult): (WebCore::InspectorPageAgent::searchInResources): (WebCore::InspectorPageAgent::buildObjectForFrame): (WebCore::InspectorPageAgent::buildObjectForFrameTree): * inspector/InspectorPageAgent.h: * inspector/InspectorProfilerAgent.cpp: (WebCore::InspectorProfilerAgent::InspectorProfilerAgent): (WebCore::InspectorProfilerAgent::createProfileHeader): (WebCore::InspectorProfilerAgent::createSnapshotHeader): (WebCore::InspectorProfilerAgent::getProfileHeaders): (WebCore::InspectorProfilerAgent::getCPUProfile): (WebCore::InspectorProfilerAgent::didCreateFrontendAndBackend): (WebCore::InspectorProfilerAgent::getObjectByHeapObjectId): (WebCore::InspectorProfilerAgent::getHeapObjectId): * inspector/InspectorProfilerAgent.h: * inspector/InspectorResourceAgent.cpp: (WebCore::InspectorResourceAgent::didCreateFrontendAndBackend): (WebCore::buildObjectForTiming): (WebCore::buildObjectForResourceRequest): (WebCore::buildObjectForResourceResponse): (WebCore::buildObjectForCachedResource): (WebCore::InspectorResourceAgent::willSendRequest): (WebCore::InspectorResourceAgent::didReceiveResponse): (WebCore::InspectorResourceAgent::didLoadResourceFromMemoryCache): (WebCore::InspectorResourceAgent::buildInitiatorObject): (WebCore::InspectorResourceAgent::willSendWebSocketHandshakeRequest): (WebCore::InspectorResourceAgent::didReceiveWebSocketHandshakeResponse): (WebCore::InspectorResourceAgent::didReceiveWebSocketFrame): (WebCore::InspectorResourceAgent::didSendWebSocketFrame): (WebCore::InspectorResourceAgent::InspectorResourceAgent): * inspector/InspectorResourceAgent.h: * inspector/InspectorRuntimeAgent.cpp: (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent): (WebCore::buildErrorRangeObject): (WebCore::InspectorRuntimeAgent::parse): (WebCore::InspectorRuntimeAgent::evaluate): (WebCore::InspectorRuntimeAgent::callFunctionOn): (WebCore::InspectorRuntimeAgent::getProperties): * inspector/InspectorRuntimeAgent.h: * inspector/InspectorStyleSheet.cpp: (WebCore::buildSourceRangeObject): (WebCore::buildMediaObject): (WebCore::fillMediaListChain): (WebCore::InspectorStyle::buildObjectForStyle): (WebCore::InspectorStyle::buildArrayForComputedStyle): (WebCore::InspectorStyle::styleWithProperties): (WebCore::InspectorStyleSheet::create): (WebCore::InspectorStyleSheet::InspectorStyleSheet): (WebCore::InspectorStyleSheet::buildObjectForStyleSheet): (WebCore::InspectorStyleSheet::buildObjectForStyleSheetInfo): (WebCore::selectorsFromSource): (WebCore::InspectorStyleSheet::buildObjectForSelectorList): (WebCore::InspectorStyleSheet::buildObjectForRule): (WebCore::InspectorStyleSheet::buildObjectForStyle): (WebCore::InspectorStyleSheet::resourceStyleSheetText): (WebCore::InspectorStyleSheet::buildArrayForRuleList): (WebCore::InspectorStyleSheetForInlineStyle::create): (WebCore::InspectorStyleSheetForInlineStyle::InspectorStyleSheetForInlineStyle): * inspector/InspectorStyleSheet.h: (WebCore::InspectorCSSId::InspectorCSSId): (WebCore::InspectorStyleSheet::canBind): * inspector/InspectorStyleTextEditor.cpp: * inspector/InspectorTimelineAgent.cpp: (WebCore::InspectorTimelineAgent::didCreateFrontendAndBackend): (WebCore::toProtocol): (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline): (WebCore::InspectorTimelineAgent::setDOMCounters): (WebCore::InspectorTimelineAgent::InspectorTimelineAgent): (WebCore::InspectorTimelineAgent::sendEvent): * inspector/InspectorTimelineAgent.h: (WebCore::InspectorTimelineAgent::TimelineRecordEntry::TimelineRecordEntry): * inspector/InspectorWebAgentBase.h: Renamed from Source/WebCore/inspector/InspectorAgentRegistry.h. (WebCore::InspectorAgentBase::InspectorAgentBase): * inspector/InspectorWorkerAgent.cpp: (WebCore::InspectorWorkerAgent::InspectorWorkerAgent): (WebCore::InspectorWorkerAgent::didCreateFrontendAndBackend): * inspector/InspectorWorkerAgent.h: * inspector/InstrumentingAgents.cpp: * inspector/NetworkResourcesData.cpp: * inspector/PageConsoleAgent.cpp: (WebCore::InspectableNode::get): * inspector/PageDebuggerAgent.cpp: * inspector/PageDebuggerAgent.h: * inspector/PageRuntimeAgent.cpp: (WebCore::PageRuntimeAgent::didCreateFrontendAndBackend): * inspector/PageRuntimeAgent.h: * inspector/ScriptArguments.cpp: (WebCore::ScriptArguments::create): (WebCore::ScriptArguments::ScriptArguments): (WebCore::ScriptArguments::argumentAt): (WebCore::ScriptArguments::getFirstArgumentAsString): * inspector/ScriptArguments.h: * inspector/ScriptCallFrame.cpp: (WebCore::ScriptCallFrame::buildInspectorObject): * inspector/ScriptCallFrame.h: * inspector/ScriptCallStack.cpp: (WebCore::ScriptCallStack::buildInspectorArray): * inspector/ScriptCallStack.h: * inspector/ScriptDebugListener.h: * inspector/TimelineRecordFactory.cpp: * inspector/TimelineRecordFactory.h: (WebCore::TimelineRecordFactory::createWebSocketCreateData): (WebCore::TimelineRecordFactory::createGenericWebSocketData): * inspector/WorkerConsoleAgent.cpp: * inspector/WorkerDebuggerAgent.cpp: * inspector/WorkerInspectorController.cpp: * inspector/WorkerInspectorController.h: * inspector/WorkerRuntimeAgent.cpp: (WebCore::WorkerRuntimeAgent::didCreateFrontendAndBackend): * inspector/WorkerRuntimeAgent.h: * page/Console.cpp: * page/ContentSecurityPolicy.cpp: * page/Frame.cpp: * page/PageConsole.cpp: * plugins/PluginView.cpp: (WebCore::PluginView::performRequest): * testing/Internals.cpp: (WebCore::Internals::parserMetaData): * testing/Internals.h: * workers/SharedWorkerGlobalScope.cpp: (WebCore::createConnectEvent): * workers/WorkerGlobalScope.cpp: (WebCore::WorkerGlobalScope::importScripts): * workers/WorkerThread.cpp: * xml/XMLTreeViewer.cpp: * xml/parser/XMLDocumentParser.cpp: * xml/parser/XMLDocumentParserLibxml2.cpp: 2013-12-11 Laszlo Vidacs Store SHA1 hash in std::array https://bugs.webkit.org/show_bug.cgi?id=125446 Reviewed by Darin Adler. Change Vector to std::array and use typedef. * Modules/websockets/WebSocketHandshake.cpp: (WebCore::WebSocketHandshake::getExpectedWebSocketAccept): * inspector/DOMPatchSupport.cpp: (WebCore::DOMPatchSupport::createDigest): * platform/network/soup/ResourceHandleSoup.cpp: (WebCore::HostTLSCertificateSet::computeCertificateHash): 2013-12-11 Alexey Proskuryakov WebCrypto keys should support structured clone https://bugs.webkit.org/show_bug.cgi?id=125590 Reviewed by Oliver Hunt. Tests: crypto/subtle/aes-postMessage.html crypto/subtle/hmac-postMessage.html crypto/subtle/postMessage-worker.html crypto/subtle/rsa-postMessage.html * crypto/CryptoAlgorithmIdentifier.h: (WebCore::CryptoAlgorithmIdentifier): * bindings/js/JSCryptoAlgorithmDictionary.cpp: (WebCore::JSCryptoAlgorithmDictionary::createParametersForEncrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDecrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForSign): (WebCore::JSCryptoAlgorithmDictionary::createParametersForVerify): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDigest): (WebCore::JSCryptoAlgorithmDictionary::createParametersForGenerateKey): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDeriveKey): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDeriveBits): (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey): (WebCore::JSCryptoAlgorithmDictionary::createParametersForExportKey): AES_KW was added to WebCrypto spec editor's draft yesterday night. Now that we're adding a matching enum for structired clone serialization, it's as good a time as any to update the order of values to match. * bindings/js/SerializedScriptValue.cpp: (WebCore::countUsages): (WebCore::CloneSerializer::dumpIfTerminal): (WebCore::CloneSerializer::write): (WebCore::CloneDeserializer::read): (WebCore::CloneDeserializer::readHMACKey): (WebCore::CloneDeserializer::readAESKey): (WebCore::CloneDeserializer::readRSAKey): (WebCore::CloneDeserializer::readCryptoKey): (WebCore::CloneDeserializer::readTerminal): Added serialization/deserialization for CryptoKey. This doesn't update version number, because we don't currently store structured clones in persistent storage - and even if we did, we wouldn't want to invalidate everything users already stored. * crypto/CryptoAlgorithmRegistry.cpp: (WebCore::CryptoAlgorithmRegistry::shared): (WebCore::registryMutex): (WebCore::CryptoAlgorithmRegistry::getIdentifierForName): (WebCore::CryptoAlgorithmRegistry::nameForIdentifier): (WebCore::CryptoAlgorithmRegistry::create): (WebCore::CryptoAlgorithmRegistry::registerAlgorithm): * crypto/CryptoKey.idl: With structured clone, it is now possible to send a Key to a web worker. That's of no practical use because the crypto API is not exposed in workers, but we shouldn't crash anyway. * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::CryptoKeyAES): (WebCore::CryptoKeyAES::isValidAESAlgorithm): * crypto/keys/CryptoKeyAES.h: Exposed isValidAESAlgorithm, so that a caller could know whether the constructor will assert. * CMakeLists.txt: * GNUmakefile.am: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.vcxproj/WebCoreCommon.props: Added crypto/keys to search paths to avoid build breakage. 2013-12-11 Bear Travis Web Inspector: [CSS Shapes] Highlight margin-shape for shape-outside https://bugs.webkit.org/show_bug.cgi?id=125175 Reviewed by Darin Adler. In addition to highlighting the shape, also highlight the shape created by shape-margin with a slightly more transparent color. This patch modifies the shape info passed to the Inspector Overlay to include a path for both the raw shape and the shape with margin. Test: inspector-protocol/model/highlight-shape-outside-margin.html * inspector/InspectorOverlay.cpp: (WebCore::buildObjectForShapeOutside): Call Shape::buildDisplayPaths rather than Shape::buildPath, and pass along any relevant paths to the Inspector overlay. * inspector/InspectorOverlayPage.js: (_drawShapeHighlight): Draw the margin shape in addition to the raw shape. * rendering/shapes/BoxShape.cpp: (WebCore::addRoundedRect): Add a rounded rect to the path. (WebCore::BoxShape::buildDisplayPaths): Create the applicable [margin/padding/raw] shapes. * rendering/shapes/BoxShape.h: * rendering/shapes/PolygonShape.cpp: (WebCore::addPolygon): Add a set of vertices as a polygon to the path. (WebCore::PolygonShape::buildDisplayPaths): Create the applicable [margin/padding/raw] shapes. * rendering/shapes/PolygonShape.h: * rendering/shapes/RasterShape.h: (WebCore::RasterShape::buildDisplayPaths): Ditto. * rendering/shapes/RectangleShape.cpp: (WebCore::RectangleShape::buildDisplayPaths): Ditto. * rendering/shapes/RectangleShape.h: * rendering/shapes/Shape.h: 2013-12-11 Mario Sanchez Prada [ATK] Expose accessibility objects WAI-ARIA landmark roles https://bugs.webkit.org/show_bug.cgi?id=125584 Reviewed by Chris Fleizach. Exposed accessibility objects with landmark roles with the proper AtkRole, to be provided by the next stable release of ATK. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (webkitAccessibleGetAttributes): (atkRole): 2013-12-11 José Dapena Paz and Zan Dobersek [GTK] Add a UPower-based BatteryProvider https://bugs.webkit.org/show_bug.cgi?id=115719 Reviewed by Martin Robinson. Introduce the BatteryProviderUPower, a provider of the system's battery status that produces the information using the upower-glib library. The BatteryProviderUPower creates a new UPower client when the provider should start emitting updates and hooks up to device alteration signals. These only fire recalculation of the battery status when a battery device is altered. When recalculating, every battery device is taken into account, accumulating the energy capacities when both empty and full, the current rate of energy charging/discharging, and the battery status (whether the device is charging or discharging). This gives a set of data that covers the overall battery status of the system. This data is then used to calculate the battery status as perceived by the WebCore implementation. Charging is determined by examining the integral sign of the current combined energy rate. Charging and discharging times are calculated, when appropriate, by dividing the chargable/dischargable capacity with the current combined energy rate. The battery level is calculated by dividing the current energy capacity with the full energy capacity (i.e. the combined capacity of all the batteries that the system possesses). The status is (indirectly) passed onto BatteryManager by invoking the updateBatteryStatus method on the client, with the first parameter representing the battery charging/discharging state, the second parameter representing the time left until the battery is fully charged (when charging) or fully depleted (when discharging), and the third parameter representing the current battery level. Whenever the implementation cannot provide any information about the battery status of the system, the client's updateBatteryStatus method is invoked with the first parameter reporting the unavailability of any information about the battery status. The other two parameters can be omitted as they default to 0 when not given and are neither available nor useful in such circumstances. The client should handle such an update by reporting the 'default' battery status - charging, the battery level being at 1.0 and both the charging and discharging time having the value of the positive infinity (as per the Battery Status API specification). The implementation is heavily inspired by a similar approach to calculating battery status in GNOME Settings Daemon. No new tests - no new functionality. The feature is not yet enabled. When enabled, the relevant tests pass. * GNUmakefile.list.am: Add the BatteryProviderUPower(Client) build targets. * platform/glib/BatteryProviderUPower.cpp: Added. (powerDeviceAlterationCallback): (BatteryProviderUPower::BatteryProviderUPower): (BatteryProviderUPower::startUpdating): (BatteryProviderUPower::stopUpdating): (BatteryProviderUPower::updateBatteryStatus): * platform/glib/BatteryProviderUPower.h: Added. (WebCore): (BatteryProviderUPower): * platform/glib/BatteryProviderUPowerClient.h: Added. (WebCore): (BatteryProviderUPowerClient): 2013-12-11 Thiago de Barros Lacerda Improving createOffer and createAnswer LayoutTests https://bugs.webkit.org/show_bug.cgi?id=125568 Reviewed by Philippe Normand. The constraints parameter should be optional in both. Also adding tests to check if we already have a local SDP when creating an answer. Existing tests were updated. * platform/mock/RTCPeerConnectionHandlerMock.cpp: (WebCore::RTCPeerConnectionHandlerMock::createOffer): 2013-12-11 Michał Pakuła vel Rutka [EFL] Fix build with CONTEXT_MENUS flag set OFF https://bugs.webkit.org/show_bug.cgi?id=125572 Reviewed by Gyuyoung Kim. dispatchEventAsContextMenuEvent is called regardless of CONTEXT_MENUS flag setting, thus its definition in InspectorFrontendHost should not be guarded by this flag. No new tests, no behaviour change. * inspector/InspectorFrontendHost.cpp: (WebCore::InspectorFrontendHost::dispatchEventAsContextMenuEvent): 2013-12-11 Tamas Gergely [CURL] Build fails after r160386. https://bugs.webkit.org/show_bug.cgi?id=125571 Reviewed by Zoltan Herczeg. Need no new tests. Fix a typo in commit r160386 that prevents building with curl. * platform/network/curl/CurlCacheEntry.cpp: (WebCore::CurlCacheEntry::generateBaseFilename): 2013-12-11 Rob Buis [CSS Shapes] Take into account fill-rule for polygon interpolation https://bugs.webkit.org/show_bug.cgi?id=125508 Reviewed by Dirk Schulze. Implement the polygon fill-rule part of http://dev.w3.org/csswg/css-shapes/#basic-shape-interpolation. Adapt fast/shapes/shape-outside-floats/shape-outside-animation.html. * rendering/style/BasicShapes.cpp: (WebCore::BasicShape::canBlend): 2013-12-11 Mario Sanchez Prada Programmatically-inserted children lack accessibility events https://bugs.webkit.org/show_bug.cgi?id=100275 Reviewed by Chris Fleizach. Test: accessibility/children-changed-sends-notification.html Emit children-changed::add and children-changed::remove whenever an object has been added/removed to the accessibility hierarchy, that is, when a new AtkObject is being attached/detached. * accessibility/AXObjectCache.h: Added new enumeration to know when we are detaching a wrapper because of the cache or the element is being destroyed, so we can use that information. (WebCore::AXObjectCache::detachWrapper): Added a new parameter and updated all the prototypes in different ports. * accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::~AXObjectCache): Call detachWrapper() specifying that we do it because the cache is being destroyed. (WebCore::AXObjectCache::remove): Call detachWrapper() specifying that we do it because an accessible element is being destroyed. * accessibility/atk/AXObjectCacheAtk.cpp: (WebCore::AXObjectCache::detachWrapper): Emit the children-changed signal when needed. We rely on the cached reference to the parent AtkObject (using the implementation of atk_object_get_parent from the AtkObject class) to find the right object to emit the signal from here, since the accessibility hierarchy from WebCore will no longer be accessible at this point. (WebCore::AXObjectCache::attachWrapper): Emit the children-change signal from here unless we are in the middle of a layout update, trying to provide as much information (e.g. the offset) as possible. (WebCore::AXObjectCache::postPlatformNotification): Make sure we update (touch) the subtree under an accessibility object whenever we receive AXChildrenChanded from WebCore, to ensure that those objects will also be visible rightaway to ATs, and that those get properly notified of the event at that very same moment. * accessibility/ios/AXObjectCacheIOS.mm: (WebCore::AXObjectCache::detachWrapper): Updated function signature. * accessibility/mac/AXObjectCacheMac.mm: (WebCore::AXObjectCache::detachWrapper): Ditto. * accessibility/win/AXObjectCacheWin.cpp: (WebCore::AXObjectCache::detachWrapper): Ditto. 2013-12-11 Andreas Kling REGRESSION(r160389): SVG test assertion extravaganza. Unreviewed. Use getAttribute() instead of fastGetAttribute() for the "type" attribute since it's animatable on SVG elements. 2013-12-11 Gyuyoung Kim Set m_nextBreakablePosition as private in InlineIterator, and use it. https://bugs.webkit.org/show_bug.cgi?id=125482 Reviewed by Andreas Kling. InlineIterator has been exported m_nextBreakablePosition as public though it is member variable. This patch set it as private, and add getter/setter functions for it. No new tests, no behavior changes. * rendering/InlineIterator.h: (WebCore::InlineIterator::InlineIterator): (WebCore::InlineIterator::nextBreakablePosition): (WebCore::InlineIterator::setNextBreakablePosition): * rendering/line/BreakingContextInlineHeaders.h: (WebCore::BreakingContext::handleText): 2013-12-10 Gurpreet Kaur top and bottom black background line not getting displayed https://bugs.webkit.org/show_bug.cgi?id=21664 Reviewed by Simon Fraser. The table cell's background was not being displayed. Since the table cell had no child correct offsetWidth was not being set even if table width is being defined. Test: fast/dom/HTMLTableElement/empy-table-cell-with-background-color.html * rendering/AutoTableLayout.cpp: (WebCore::AutoTableLayout::recalcColumn): cellHasContent should also be set to true incase background color is present. 2013-12-10 Beth Dakin Horizontal rubber-banding without a horizontal scrollbar is distracting https://bugs.webkit.org/show_bug.cgi?id=125550 Reviewed by Simon Fraser. Setting the ScrollElasticity to ScrollElasticityAutomatic will make sure we only rubber-band horizontally when there is a horizontal scrollbar. * page/FrameView.cpp: (WebCore::FrameView::FrameView): 2013-12-10 Martin Robinson Correct a preprocessor guard from a mis-merged patch In r160367, I mismerged a patch from Gustavo Noronha. This commit fixes the merge and thus fixes the CMake build. * html/HTMLMediaElement.idl: Move the preprocessor guard to the correct property. 2013-12-10 Rob Buis Clean up SVGScriptElement https://bugs.webkit.org/show_bug.cgi?id=125527 Reviewed by Sam Weinig. Rewrite to not store type in m_type and also remove type getter/setter. * svg/SVGScriptElement.cpp: (WebCore::SVGScriptElement::parseAttribute): (WebCore::SVGScriptElement::typeAttributeValue): * svg/SVGScriptElement.h: * svg/SVGScriptElement.idl: 2013-12-10 Laszlo Vidacs Use std::array when computing MD5 checksum https://bugs.webkit.org/show_bug.cgi?id=125509 Reviewed by Anders Carlsson. Use MD5::Digest type and MD5::hashSize when computing MD5 checksum. * platform/network/curl/CurlCacheEntry.cpp: (WebCore::CurlCacheEntry::generateBaseFilename): 2013-12-10 Mario Sanchez Prada [ATK] Expose splitter elements with ATK_ROLE_SEPARATOR https://bugs.webkit.org/show_bug.cgi?id=125522 Reviewed by Chris Fleizach. Expose objects with SplitterRole role as ATK_ROLE_SEPARATOR. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): 2013-12-10 Mario Sanchez Prada [ATK] Elements with role 'alertdialog' should be ATK_ROLE_ALERT https://bugs.webkit.org/show_bug.cgi?id=125521 Reviewed by Chris Fleizach. Stop exposing alert dialogs as ATK_ROLE_DIALOG and do it as ATK_ROLE_ALERT instead. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): 2013-12-10 Brendan Long [GTK][GStreamer] media/video-preload.html is flakily crashing on WK2 https://bugs.webkit.org/show_bug.cgi?id=125411 Reviewed by Philippe Normand. No new tests because this fixes flakeyness in existing tests (media/video-preload.html, and various tests in media/track/{audio,in-band,video}). * platform/graphics/gstreamer/TextCombinerGStreamer.cpp: (webkitTextCombinerPadGetProperty): Copy tag list to prevent concurrent modification problems. (webkitTextCombinerPadEvent): Add locking. * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp: (WebCore::TrackPrivateBaseGStreamer::TrackPrivateBaseGStreamer): Call tagsChanged() because we need it to setup m_tags. (WebCore::TrackPrivateBaseGStreamer::disconnect): Clear m_tags. (WebCore::TrackPrivateBaseGStreamer::tagsChanged): Lookup the tags while we're in this callback, because it's the only time we can guarantee that the input-selector won't unref them. (WebCore::TrackPrivateBaseGStreamer::notifyTrackOfTagsChanged): Use m_tags. * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h: Add m_tags and a mutex. 2013-12-10 László Langó PageConsole::addMessage should automatically determine column number alongside line number https://bugs.webkit.org/show_bug.cgi?id=114319 Reviewed by Joseph Pecoraro. * dom/InlineStyleSheetOwner.cpp: (WebCore::InlineStyleSheetOwner::InlineStyleSheetOwner): * dom/ScriptElement.cpp: (WebCore::ScriptElement::ScriptElement): * dom/ScriptableDocumentParser.h: * dom/StyledElement.cpp: (WebCore::StyledElement::styleAttributeChanged): * html/parser/HTMLDocumentParser.cpp: (WebCore::HTMLDocumentParser::didReceiveParsedChunkFromBackgroundParser): (WebCore::HTMLDocumentParser::pumpPendingSpeculations): * html/parser/HTMLDocumentParser.h: * inspector/InspectorResourceAgent.cpp: (WebCore::InspectorResourceAgent::buildInitiatorObject): * page/Console.cpp: (WebCore::internalAddMessage): * page/PageConsole.cpp: (WebCore::PageConsole::printSourceURLAndPosition): (WebCore::PageConsole::addMessage): * page/PageConsole.h: * xml/parser/XMLDocumentParser.h: * xml/parser/XMLDocumentParserLibxml2.cpp: (WebCore::XMLDocumentParser::error): 2013-12-10 Andreas Kling Jettison all StyleResolver data on memory pressure. The StyleResolver can be rebuilt relatively quickly; we already have an optimization that discards it some time after last use. If we find ourseles under serious memory pressure, don't wait for the timer to kick in, throw everything overboard right away. ~5MB progression post-pressure on Membuster3. Reviewed by Anders Carlsson. 2013-12-10 Martin Robinson [GTK] [CMake] Add support for building the DOM bindings https://bugs.webkit.org/show_bug.cgi?id=116375 Reviewed by Gustavo Noronha Silva. The CMake build is more complete than the autotools counterpart, so autotools doesn't consider some supplemental IDL attributes when building the DOM bindings. To prevent API breaks we should protect these attributes from DOM binding generation. * Modules/battery/BatteryManager.idl: Protect non-GObject DOM bound methods by C preprocessor checks. * Modules/battery/NavigatorBattery.idl: Ditto. * Modules/mediastream/HTMLMediaElementMediaStream.idl: Ditto. * Modules/networkinfo/NavigatorNetworkInfoConnection.idl: Ditto. * Modules/networkinfo/NetworkInfoConnection.idl: Ditto. * PlatformGTK.cmake: Add build steps for building the bindings. * dom/Document.idl: Protect non-GObject DOM bound methods by C preprocessor checks. * html/HTMLMediaElement.idl: Ditto. 2013-12-10 Martin Robinson Various fixes for the CMake GTK+ build Reviewed by Gustavo Noronha. * PlatformGTK.cmake: Update source list. 2013-12-10 Robert Sipka [nix][curl] Buildfix after r160310 https://bugs.webkit.org/show_bug.cgi?id=125489 Reviewed by Gustavo Noronha Silva. Curl doesn't include soup files. * PlatformNix.cmake: 2013-12-10 Gustavo Noronha Silva [GTK] REGRESSION: www.yahoo.com redirects to the mobile version after UA change https://bugs.webkit.org/show_bug.cgi?id=125444 Reviewed by Martin Robinson. * platform/gtk/UserAgentGtk.cpp: (WebCore::platformVersionForUAString): more correctly pretend we're Mac OS X. (WebCore::standardUserAgent): ditto. 2013-12-09 Gustavo Noronha Silva [Soup] Send original encoded data size to didReceiveBuffer https://bugs.webkit.org/show_bug.cgi?id=125410 Reviewed by Martin Robinson. No tests, the only way to test this seems to be through the inspector UI. * platform/network/ResourceHandle.h: * platform/network/ResourceHandleInternal.h: (WebCore::ResourceHandleInternal::ResourceHandleInternal): data member to track stream position. * platform/network/soup/ResourceHandleSoup.cpp: (WebCore::ResourceHandle::currentStreamPosition): obtains the current stream position by querying the first seekable input stream we find. (WebCore::nextMultipartResponsePartCallback): store the position before we start reading a new part. (WebCore::sendRequestCallback): store the position before we start reading the response body. (WebCore::readCallback): pass the position delta to didReceiveData. 2013-12-09 Andreas Kling Clear out font width measurement caches on memory pressure. The data kept in WidthCaches can be regenerated on demand. Throwing it away when we're under memory pressure buys us ~4MB on Membuster3. Reviewed by Antti Koivisto. 2013-12-09 Seokju Kwon Web Inspector: Remove enabled() in InspectorRuntimeAgent. https://bugs.webkit.org/show_bug.cgi?id=125476 Reviewed by Joseph Pecoraro. Dead code. It's never called anywhere. No new tests, no behavior change. * inspector/InspectorRuntimeAgent.h: 2013-12-09 Sam Weinig Replace use of WTF::FixedArray with std::array https://bugs.webkit.org/show_bug.cgi?id=125475 Reviewed by Anders Carlsson. * crypto/parameters/CryptoAlgorithmAesCbcParams.h: * platform/graphics/GlyphMetricsMap.h: 2013-12-09 Benjamin Poulain Refactor the CFURLConnectionClient to be the synchronous implementation of an abstract network delegate https://bugs.webkit.org/show_bug.cgi?id=125379 Reviewed by Alexey Proskuryakov. * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.xcodeproj/project.pbxproj: * platform/network/ResourceHandle.h: * platform/network/ResourceHandleInternal.h: * platform/network/cf/ResourceHandleCFNet.cpp: (WebCore::ResourceHandle::createCFURLConnection): * platform/network/cf/ResourceHandleCFURLConnectionDelegate.cpp: Added. (WebCore::ResourceHandleCFURLConnectionDelegate::ResourceHandleCFURLConnectionDelegate): (WebCore::ResourceHandleCFURLConnectionDelegate::~ResourceHandleCFURLConnectionDelegate): (WebCore::ResourceHandleCFURLConnectionDelegate::willSendRequestCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didReceiveResponseCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didReceiveDataCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didFinishLoadingCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didFailCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::willCacheResponseCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didReceiveChallengeCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didSendBodyDataCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::shouldUseCredentialStorageCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::canRespondToProtectionSpaceCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::didReceiveDataArrayCallback): (WebCore::ResourceHandleCFURLConnectionDelegate::makeConnectionClient): * platform/network/cf/ResourceHandleCFURLConnectionDelegate.h: Added. * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.cpp: Added. (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::SynchronousResourceHandleCFURLConnectionDelegate): (WebCore::synthesizeRedirectResponseIfNecessary): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::willSendRequest): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveResponse): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveData): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didFinishLoading): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didFail): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::willCacheResponse): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveChallenge): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didSendBodyData): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::shouldUseCredentialStorageCallback): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::canRespondToProtectionSpace): (WebCore::SynchronousResourceHandleCFURLConnectionDelegate::didReceiveDataArray): * platform/network/cf/SynchronousResourceHandleCFURLConnectionDelegate.h: Added. 2013-12-09 Ryosuke Niwa REGRESSION(r136280): input[type=image] should assume coords of 0,0 when activated without physically clicking https://bugs.webkit.org/show_bug.cgi?id=125392 Reviewed by Darin Adler. Merge https://chromium.googlesource.com/chromium/blink/+/3c33d42207cd209bb171083ba66c225f694f2101 Activating an image button with the keyboard or element.click() should result in selected coords of (0,0) per http://www.w3.org/TR/2013/CR-html5-20130806/forms.html#image-button-state-(type=image) "If the user activates the control without explicitly selecting a coordinate, then the coordinate (0,0) must be assumed." New behavior also matches that of Internet Explorer and Firefox. Tests: fast/forms/input-image-submit.html * html/ImageInputType.cpp: (WebCore::ImageInputType::handleDOMActivateEvent): Set m_clickLocation to (0, 0) for simulated events. 2013-12-09 Jer Noble [MSE] Add support for VideoPlaybackMetrics. https://bugs.webkit.org/show_bug.cgi?id=125380 Reviewed by Eric Carlson. Test: media/media-source/media-source-video-playback-quality.html Add a new object type VideoPlaybackQuality to be returned by HTMLMediaElement.getVideoPlaybackQuality(). HTMLMediaElements must separately track a droppedVideoFrame count, as certain operations on SourceBuffer will drop incoming frames, which must be accounted for. Reset this count when the media engine changes, which is indicitive of a new media load requset starting. Add the new VideoPlaybackQuality class: * Modules/mediasource/VideoPlaybackQuality.cpp: Added. (WebCore::VideoPlaybackQuality::create): (WebCore::VideoPlaybackQuality::VideoPlaybackQuality): * Modules/mediasource/VideoPlaybackQuality.h: Added. (WebCore::VideoPlaybackQuality::creationTime): (WebCore::VideoPlaybackQuality::totalVideoFrames): (WebCore::VideoPlaybackQuality::droppedVideoFrames): (WebCore::VideoPlaybackQuality::corruptedVideoFrames): (WebCore::VideoPlaybackQuality::totalFrameDelay): * Modules/mediasource/VideoPlaybackQuality.idl: Added. Add support for the new class to HTMLMediaElement: * html/HTMLMediaElement.cpp: (HTMLMediaElement::shouldUseVideoPluginProxy): (HTMLMediaElement::getVideoPlaybackQuality): * html/HTMLMediaElement.h: * html/HTMLMediaElement.idl: Report the video quality metrics from the MediaPlayer: * platform/graphics/MediaPlayer.cpp: (WebCore::MediaPlayer::totalVideoFrames): (WebCore::MediaPlayer::droppedVideoFrames): (WebCore::MediaPlayer::corruptedVideoFrames): (WebCore::MediaPlayer::totalFrameDelay): * platform/graphics/MediaPlayer.h: * platform/graphics/MediaPlayerPrivate.h: (WebCore::MediaPlayerPrivateInterface::totalVideoFrames): (WebCore::MediaPlayerPrivateInterface::droppedVideoFrames): (WebCore::MediaPlayerPrivateInterface::corruptedVideoFrames): (WebCore::MediaPlayerPrivateInterface::totalFrameDelay): Correctly report the dropped frame count: * Modules/mediasource/SourceBuffer.cpp: (WebCore::SourceBuffer::TrackBuffer::TrackBuffer): needsRandomAccessFlag defaults to true. (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Check the sync status of the incoming sample. (WebCore::SourceBuffer::didDropSample): Notify the media element of a dropped frame. * Modules/mediasource/SourceBuffer.h: * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::HTMLMediaElement): (HTMLMediaElement::mediaPlayerEngineUpdated): Reset m_droppedFrameCount. (HTMLMediaElement::getVideoPlaybackQuality): Return a new VideoPlaybackQuality object. * html/HTMLMediaElement.h: (WebCore::HTMLMediaElement::incrementDroppedFrameCount): Simple incrementer. * platform/MediaSample.h: (WebCore::MediaSample::isSync): Convenience function. (WebCore::MediaSample::isNonDisplaying): Ditto. Add support in the AVFoundation MediaSource Engine: * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm: (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::totalVideoFrames): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::droppedVideoFrames): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::corruptedVideoFrames): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::totalFrameDelay): Add support in the Mock MediaSource Engine: * platform/mock/mediasource/MockBox.h: * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp: (WebCore::MockMediaPlayerMediaSource::totalVideoFrames): Simple accessor. (WebCore::MockMediaPlayerMediaSource::droppedVideoFrames): Ditto. (WebCore::MockMediaPlayerMediaSource::corruptedVideoFrames): Ditto. (WebCore::MockMediaPlayerMediaSource::totalFrameDelay): Ditto. * platform/mock/mediasource/MockMediaPlayerMediaSource.h: * platform/mock/mediasource/MockMediaSourcePrivate.cpp: (WebCore::MockMediaSourcePrivate::MockMediaSourcePrivate): * platform/mock/mediasource/MockMediaSourcePrivate.h: * platform/mock/mediasource/MockSourceBufferPrivate.cpp: (WebCore::MockSourceBufferPrivate::enqueueSample): Increment the frame counts based on the incoming sample. * platform/mock/mediasource/MockSourceBufferPrivate.h: Add the new files to the project: * bindings/gobject/GNUmakefile.am: * DerivedSources.make: * WebCore.xcodeproj/project.pbxproj: * GNUMakefile.list.am: * CMakeLists.txt: 2013-12-09 Simon Fraser Avoid divide by zero in scrollbar code, and protect against Obj-C exceptions https://bugs.webkit.org/show_bug.cgi?id=125469 Reviewed by Beth Dakin. In ScrollbarThemeMac::setPaintCharacteristicsForScrollbar(), proportion could end up as NaN if scrollbar->totalSize() were zero. Protect against that. Also wrap functions that call into Objective-C with BEGIN_BLOCK_OBJC_EXCEPTIONS/ END_BLOCK_OBJC_EXCEPTIONS. * platform/mac/ScrollbarThemeMac.mm: (WebCore::ScrollbarThemeMac::scrollbarThickness): (WebCore::ScrollbarThemeMac::updateScrollbarOverlayStyle): (WebCore::ScrollbarThemeMac::minimumThumbLength): (WebCore::ScrollbarThemeMac::updateEnabledState): (WebCore::ScrollbarThemeMac::setPaintCharacteristicsForScrollbar): (WebCore::scrollbarPainterPaint): 2013-12-09 Ryosuke Niwa Implement Document.cloneNode() https://bugs.webkit.org/show_bug.cgi?id=11646 Reviewed by Darin Adler. Merge https://chromium.googlesource.com/chromium/blink/+/dc7879025e01d63be9fcf6a84ca6c9b8b5768a80 Implement the behavior specified in the current DOM4 working draft: http://www.w3.org/TR/2013/WD-dom-20131107/#dom-node-clonenode Tests: fast/dom/Document/clone-node.html fast/dom/HTMLDocument/clone-node-quirks-mode.html svg/custom/clone-node.html * dom/Document.cpp: (WebCore::Document::cloneNode): (WebCore::Document::cloneDocumentWithoutChildren): (WebCore::Document::cloneDataFromDocument): * dom/Document.h: * html/HTMLDocument.cpp: (WebCore::HTMLDocument::cloneDocumentWithoutChildren): * html/HTMLDocument.h: * svg/SVGDocument.cpp: (WebCore::SVGDocument::cloneDocumentWithoutChildren): * svg/SVGDocument.h: 2013-12-09 Andreas Kling REGRESSION(r160260): Memory pressure signal causes web process to hang. Reviewed by Tim Horton. This command caused all of my web processes to hang: notifyutil -p org.WebKit.lowMemory This only happens when the cache pruning code encounters a resource using purgeable memory. * loader/cache/MemoryCache.cpp: (WebCore::MemoryCache::pruneLiveResourcesToSize): Grab the next CachedResource pointer before continuing the loop. 2013-12-09 peavo@outlook.com [WinCairo] OpenGL compile error. https://bugs.webkit.org/show_bug.cgi?id=125383 Reviewed by Darin Adler. * platform/graphics/opengl/Extensions3DOpenGLES.h: Define GL_HALF_FLOAT_ARB on Windows when OPENGL_ES_2 is used. 2013-12-09 Peter Molnar Fix handling of 'inherit' and 'initial' for grid lines. https://bugs.webkit.org/show_bug.cgi?id=125223 Reviewed by Darin Adler. 'initial' and 'inherit' are always allowed values for CSS properties. As the CSSParser handles them automatically, those 2 values were never taken care of in StyleResolver, leading to crashes. Added tests cases for 'inherit' and 'initial' to the following tests: fast/css-grid-layout/grid-item-column-row-get-set.html fast/css-grid-layout/grid-item-end-after-get-set.html fast/css-grid-layout/grid-item-start-before-get-set.html Patch backported from Blink: https://src.chromium.org/viewvc/blink?revision=149257&view=revision * css/StyleResolver.cpp: (WebCore::StyleResolver::applyProperty): * rendering/style/RenderStyle.h: * rendering/style/StyleGridItemData.cpp: (WebCore::StyleGridItemData::StyleGridItemData): 2013-12-09 Joseph Pecoraro Web Inspector: Inspector.json and CodeGenerator tweaks https://bugs.webkit.org/show_bug.cgi?id=125321 Reviewed by Timothy Hatcher. * inspector/protocol/Runtime.json: Runtime.js was depending on Network.FrameId. This is a layering violation, so ideally we can fix this later. For now, just copy the FrameId type into Runtime. They are strings so all is good. * inspector/CodeGeneratorInspector.py: (Generator.EventMethodStructTemplate.append_epilog): * inspector/CodeGeneratorInspectorStrings.py: Improve --help usage information. Make the script work with a single domain json file. Add ASCIILiteral's where appropriate. 2013-12-09 Nick Diego Yamane [Nix] Fix file name typo in PlatformNix.cmake https://bugs.webkit.org/show_bug.cgi?id=125457 Reviewed by Gustavo Noronha Silva. Wrong file name introduced in http://trac.webkit.org/changeset/160310. * PlatformNix.cmake: 2013-12-09 Brendan Long [GStreamer] Memory leak due to incorrect use of gst_tag_list_merge in TextCombinerGStreamer https://bugs.webkit.org/show_bug.cgi?id=125452 Reviewed by Philippe Normand. No new tests because this fixes a memory leak. * platform/graphics/gstreamer/TextCombinerGStreamer.cpp: (webkitTextCombinerPadEvent): Use gst_tag_list_insert instead of gst_tag_list_merge, since we don't want to create a new list. 2013-12-09 Chris Fleizach AX: WebKit ignores @alt on IMG elements with role="text" https://bugs.webkit.org/show_bug.cgi?id=125363 Reviewed by Mario Sanchez Prada. If an element has a different role, the alt attribute should still be used in the name calculation if present. Test: accessibility/alt-tag-on-image-with-nonimage-role.html * accessibility/AccessibilityNodeObject.cpp: (WebCore::AccessibilityNodeObject::usesAltTagForTextComputation): (WebCore::AccessibilityNodeObject::alternativeText): (WebCore::AccessibilityNodeObject::accessibilityDescription): (WebCore::AccessibilityNodeObject::text): * accessibility/AccessibilityNodeObject.h: 2013-12-08 Martin Robinson [WK2][Soup] Use didReceiveBuffer instead of didReceiveData https://bugs.webkit.org/show_bug.cgi?id=118598 Reviewed by Gustavo Noronha Silva. Original patch by Kwang Yul Seo and Csaba Osztrogonác . Switch from using didReceiveData to didReceiveBuffer for the Soup backend and let SharedBuffer wrap a SoupBuffer. This is necessary because the NetworkProcess only supports getting data via SharedBuffer. * GNUmakefile.list.am: Add the new SharedBufferSoup.cpp file to the list. * PlatformEfl.cmake: * PlatformGTK.cmake: * PlatformNix.cmake: * platform/SharedBuffer.cpp: We no longer used the no-op version of the platformFoo methods. * platform/SharedBuffer.h: Ditto. * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp: Use didReceiveBuffer instead of didReceiveData. * platform/network/ResourceHandleInternal.h: Have only a m_soupBuffer member instead of three to manage the buffer. * platform/network/soup/GOwnPtrSoup.cpp: Add support for SoupBuffer. * platform/network/soup/GOwnPtrSoup.h: Ditto. * platform/network/soup/ResourceHandleSoup.cpp: (WebCore::WebCoreSynchronousLoader::didReceiveData): ASSERT_NOT_REACHED here, since it should never be called now. (WebCore::WebCoreSynchronousLoader::didReceiveBuffer): Handle this call properly. (WebCore::ResourceHandle::ensureReadBuffer): Now we package up our buffer into a SoupBuffer. (WebCore::redirectSkipCallback): Use the new m_soupBuffer member. (WebCore::cleanupSoupRequestOperation): Ditto. (WebCore::nextMultipartResponsePartCallback): Ditto. (WebCore::sendRequestCallback): Ditto. (WebCore::readCallback): * platform/soup/SharedBufferSoup.cpp: Added. 2013-12-09 Michal Poteralski DataCloneError exception is not thrown when postMessage's second parameter is the source port or the target port. https://bugs.webkit.org/show_bug.cgi?id=124708 Reviewed by Alexey Proskuryakov. According to specification: http://www.whatwg.org/specs/web-apps/current-work/multipage/web-messaging.html#dom-window-postmessage If the method was invoked with a second argument transfer then if any of the objects in the transfer are either the source port or the target port (if any), then a DataCloneError exception should be thrown. Currently an InvalidStateError exception is thrown what is an incorrect behaviour. The proposed solution is change to the correct the exception value. Tests: fast/dom/Window/postMessage-clone-port-error.html * dom/MessagePort.cpp: (WebCore::MessagePort::postMessage): Improve exception value 2013-12-09 Carlos Garcia Campos Unreviewed. Fix the GTK+ build with NetworkProcess enabled. * GNUmakefile.list.am: Add missing file to compilation. 2013-12-08 Ryosuke Niwa getComputedStyle border-radius shorthand omits vertical radius information https://bugs.webkit.org/show_bug.cgi?id=125394 Reviewed by Andreas Kling. Merge https://chromium.googlesource.com/chromium/blink/+/4c2866855dddbb28bb7d978ad627acc368af23d0 getComputedStyle of border-radius shows the vertical radius components if they differ from their horizontal counterpants. We were incorrectly detecting this case and over simplifying the results of getComputedStyle. This patch ensures we only hide the vertical values if they are identical to the horizontal values. * css/CSSComputedStyleDeclaration.cpp: (WebCore::getBorderRadiusShorthandValue): 2013-12-08 Carlos Garcia Campos [GTK] Do not skip attributes with only custom setter https://bugs.webkit.org/show_bug.cgi?id=125417 Reviewed by Gustavo Noronha Silva. For attributes with a custom setter, we now generate the code as a read-only attribute with a getter method, unless it also has a custom getter in which case the attribute is skipped. * bindings/gobject/GNUmakefile.am: Generate WebKitDOMMediaController that is now required by an attribute having a custom setter. * bindings/gobject/WebKitDOMCustom.cpp: Remove methods that are now generated. * bindings/gobject/WebKitDOMCustom.h: Ditto. * bindings/gobject/WebKitDOMCustom.symbols: Ditto. * bindings/gobject/webkitdom.symbols: Add new symbols. * bindings/scripts/CodeGeneratorGObject.pm: (SkipAttribute): Do not skip attributes having a custom setter. (GetWriteableProperties): Do not include attributes having a custom setter. (GenerateProperty): Do not return early for attributes having custom setter. (GenerateFunctions): Do not generate setter for attributes having a custom setter. 2013-12-08 Carlos Garcia Campos [GTK] Do not generate new dispatch_event methods marked as deprecated https://bugs.webkit.org/show_bug.cgi?id=125416 Reviewed by Gustavo Noronha Silva. * bindings/scripts/CodeGeneratorGObject.pm: (SkipFunction): Skip dispatch_event methods for objects implementing EventTarget interface unless they are already deprecated. (GenerateFunction): Pass also the parentNode to SkipFunction(). 2013-12-05 Jer Noble [MSE] Bring end-of-stream algorithm section up to current spec. https://bugs.webkit.org/show_bug.cgi?id=125270 Reviewed by Darin Adler. Test: media/media-source/media-source-end-of-stream.html Separate the "endOfStream()" method from the "end of stream algorithm". * Modules/mediasource/MediaSource.cpp: (WebCore::SourceBufferIsUpdating): Added predicate function. (WebCore::MediaSource::endOfStream): Call streamEndedWithError(). (WebCore::MediaSource::streamEndedWithError): Added. * Modules/mediasource/MediaSource.h: * Modules/mediasource/SourceBuffer.cpp: (WebCore::SourceBuffer::appendBufferTimerFired): Call streamEndedWithError(). (WebCore::SourceBuffer::sourceBufferPrivateDidReceiveSample): Ditto. * Modules/mediasource/SourceBuffer.h: * html/HTMLMediaElement.cpp: (HTMLMediaElement::mediaLoadingFailedFatally): Renamed from mediaEngineError. (HTMLMediaElement::mediaLoadingFailed): Call renamed method. * html/HTMLMediaElement.h: * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm: (WebCore::MediaSourcePrivateAVFObjC::markEndOfStream): Set load state to Loaded. * platform/mock/mediasource/MockMediaPlayerMediaSource.cpp: (WebCore::MockMediaPlayerMediaSource::setNetworkState): Simple setter. * platform/mock/mediasource/MockMediaPlayerMediaSource.h: * platform/mock/mediasource/MockMediaSourcePrivate.cpp: (WebCore::MockMediaSourcePrivate::MockMediaSourcePrivate): Set the intitial duration to NaN. (WebCore::MockMediaSourcePrivate::markEndOfStream): Set load state to Loaded. 2013-12-04 Jer Noble [MSE][Mac] Crash when removing MediaSource from HTMLMediaElement. https://bugs.webkit.org/show_bug.cgi?id=125269 Reviewed by Sam Weinig. Fixes the media/media-source/media-source-fastseek.html test when run with MallocScribble enabled. It's possible for a SourceBufferPrivateAVFObjC to outlive its MediaSourcePrivateAVFObjC, so make sure to clear the pointer from the former to the latter when the latter is destroyed. That means we now have to check to see if the pointer to the latter is still valid at every call site. As a drive-by fix, rename m_parent to m_mediaSource to more accurately reflect what the pointer points to. * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm: (WebCore::MediaSourcePrivateAVFObjC::~MediaSourcePrivateAVFObjC): Clear the SourceBuffer's backpointer. * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h: (WebCore::SourceBufferPrivateAVFObjC::clearMediaSource): * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::SourceBufferPrivateAVFObjC): Rename m_parent -> m_mediaSource. (WebCore::SourceBufferPrivateAVFObjC::append): Check m_mediaSource before calling. (WebCore::SourceBufferPrivateAVFObjC::removedFromMediaSource): Ditto. (WebCore::SourceBufferPrivateAVFObjC::readyState): Ditto. (WebCore::SourceBufferPrivateAVFObjC::setReadyState): Ditto. (WebCore::SourceBufferPrivateAVFObjC::trackDidChangeEnabled): Ditto. (WebCore::SourceBufferPrivateAVFObjC::flushAndEnqueueNonDisplayingSamples): Ditto. (WebCore::SourceBufferPrivateAVFObjC::enqueueSample): Ditto. (WebCore::SourceBufferPrivateAVFObjC::setActive): Ditto. * platform/mock/mediasource/MockMediaSourcePrivate.cpp: (WebCore::MockMediaSourcePrivate::~MockMediaSourcePrivate): Clear the SourceBuffer's backpointer. * platform/mock/mediasource/MockSourceBufferPrivate.cpp: (WebCore::MockSourceBufferPrivate::MockSourceBufferPrivate): Rename m_parent -> m_mediaSource. (WebCore::MockSourceBufferPrivate::removedFromMediaSource): Check m_mediaSource before calling. (WebCore::MockSourceBufferPrivate::readyState): Ditto. (WebCore::MockSourceBufferPrivate::setReadyState): Ditto. (WebCore::MockSourceBufferPrivate::setActive): Ditto. * platform/mock/mediasource/MockSourceBufferPrivate.h: (WebCore::MockSourceBufferPrivate::clearMediaSource): 2013-12-07 Zoltan Horvath Remove statusWithDirection static function from RenderBlockLineLayout https://bugs.webkit.org/show_bug.cgi?id=125372 Reviewed by Andreas Kling. I run into a FIXME about using BidiStatus constructor rather than statusWithDirection, once it's implemented. BidiStatus has got the appropriate constructor now, so I removed statusWithDirection and updated the code to use the constructor of BidiStatus. No new tests, no behavior change. * rendering/RenderBlockLineLayout.cpp: (WebCore::constructBidiRunsForSegment): 2013-12-07 ChangSeok Oh Unreviewed. Build fix for gtk port after r160260. * loader/cache/CachedImage.h: Add missing a header. 2013-12-07 Gustavo Noronha Silva ubuntu software center hits _XReadEvents() error https://bugs.webkit.org/show_bug.cgi?id=123480 Reviewed by Martin Robinson. * platform/gtk/WidgetBackingStoreGtkX11.cpp: (WebCore::WidgetBackingStoreGtkX11::~WidgetBackingStoreGtkX11): clear the surface before freeing the associated pixmap. 2013-12-06 Tim Horton [mac] Keep around more decoded image data, since it's purgeable https://bugs.webkit.org/show_bug.cgi?id=125273 Unreviewed patch to fix review comments... * platform/graphics/BitmapImage.h: Dan noticed that these return statements were improperly indented. 2013-12-05 Jer Noble [MSE][Mac] Disable AVFoundation when enabling the MockMediaPlayerMediaSource. https://bugs.webkit.org/show_bug.cgi?id=125338 Reviewed by Darin Adler. The MediaSource API has some assumptions which break if more than one installed media engine supports MediaSources at the same time. So when enabling the mock media source engine in DRT or WKTR, disable AVFoundation so that only the mock engine will support media source loading. * testing/Internals.cpp: (WebCore::Internals::initializeMockMediaSource): 2013-12-06 Antti Koivisto Use NeverDestroyed instead of DEFINE_STATIC_LOCAL Reviewed by Anders Carlsson. * rendering/RenderText.cpp: (WebCore::originalTextMap): 2013-12-05 Jer Noble [MSE] Add a runtime-setting for the MediaSource constructor. https://bugs.webkit.org/show_bug.cgi?id=125336 Reviewed by Eric Carlson. Add a Setting to enable the MediaSource constructor. * Modules/mediasource/MediaSource.idl: * page/Settings.in: 2013-12-06 Tim Horton [mac] Keep around more decoded image data, since it's purgeable https://bugs.webkit.org/show_bug.cgi?id=125273 Reviewed by Simon Fraser. No new tests, just an optimization. Instead of throwing away decoded image data eagerly, allow the operating system to manage the memory via the standard purgeability mechanism, where it can. This improves the performance on some pathological cases (extremely large animated GIFs) by up to 8x. * loader/cache/MemoryCache.cpp: (WebCore::MemoryCache::pruneLiveResourcesToSize): Don't prune live resources' decoded data if it is purgeable. * platform/graphics/BitmapImage.cpp: (WebCore::BitmapImage::destroyDecodedDataIfNecessary): Don't eagerly throw away decoded image data if it's purgeable. * loader/cache/CachedImage.h: * loader/cache/CachedResource.h: (WebCore::CachedResource::decodedDataIsPurgeable): * platform/graphics/BitmapImage.h: * platform/graphics/Image.h: (WebCore::Image::decodedDataIsPurgeable): 2013-12-06 Antti Koivisto Save original text for RenderText to a map https://bugs.webkit.org/show_bug.cgi?id=125278 Reviewed by Darin Adler. Currently the original text is fetched from the Text node. This is one of the few things where we use the RenderText node pointer and is stopping Text nodes from being anonymous. It is very rare of original text to differ from the actual text so we can just squirrel the original to a map when it differs. This is also simplifies the code. * rendering/RenderQuote.cpp: (WebCore::RenderQuote::styleDidChange): (WebCore::RenderQuote::updateDepth): * rendering/RenderText.cpp: (WebCore::originalTextMap): (WebCore::RenderText::RenderText): (WebCore::RenderText::~RenderText): (WebCore::RenderText::styleDidChange): (WebCore::RenderText::originalText): (WebCore::RenderText::setTextInternal): (WebCore::RenderText::setText): * rendering/RenderText.h: * rendering/RenderTextFragment.cpp: * rendering/RenderTextFragment.h: 2013-12-04 Jer Noble [MSE] Refactor MediaSourceBase back into MediaSource https://bugs.webkit.org/show_bug.cgi?id=125245 Reviewed by Eric Carlson. Now that the legacy WebKitMediaSource has been removed, there is no reason to have a separate MediaSource and MediaSourceBase. Re-integrate the two. Copy all the methods from MediaSource into MediaSourceBase, and rename the class MediaSource: * Modules/mediasource/MediaSource.cpp: Copied from MediaSourceBase.cpp. (WebCore::MediaSource::create): Copied from MediaSource.cpp. (WebCore::MediaSource::addSourceBuffer): Ditto. (WebCore::MediaSource::removeSourceBuffer): Ditto. (WebCore::MediaSource::isTypeSupported): Ditto. (WebCore::MediaSource::eventTargetInterface): Ditto. (WebCore::MediaSource::sourceBufferDidChangeAcitveState): Ditto. * Modules/mediasource/MediaSource.h: Copied from MediaSourceBase.h. (WebCore::MediaSource::sourceBuffers): Copied from MediaSource.h. (WebCore::MediaSource::activeSourceBuffers): Copied from MediaSource.h. * Modules/mediasource/MediaSourceBase.cpp: Removed. * Modules/mediasource/MediaSourceBase.h: Removed. Change all references to MediaSourceBase into MediaSource: * Modules/mediasource/DOMURLMediaSource.cpp: (WebCore::DOMURLMediaSource::createObjectURL): * Modules/mediasource/DOMURLMediaSource.h: * Modules/mediasource/MediaSourceRegistry.cpp: (WebCore::MediaSourceRegistry::registerURL): (WebCore::MediaSourceRegistry::unregisterURL): * Modules/mediasource/MediaSourceRegistry.h: Remove MediaSourceBase.cpp/h from the project file: * WebCore.xcodeproj/project.pbxproj: * GNUmakefile.list.am: 2013-12-06 Eric Carlson r159827 broke plug-in snapshotting https://bugs.webkit.org/show_bug.cgi?id=125365 Reviewed by Dean Jackson. No new tests, covered by existing tests. * html/HTMLPlugInImageElement.cpp: (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot): Return early if there is NOT a page, not if there IS a page. 2013-12-06 Roger Fong and Brent Fulgham [Win] Support compiling with VS2013 https://bugs.webkit.org/show_bug.cgi?id=125353 Reviewed by Anders Carlsson. * loader/archive/cf/LegacyWebArchive.cpp: (WebCore::LegacyWebArchive::create): Use nullptr (WebCore::LegacyWebArchive::createFromSelection): Ditto 2013-11-15 Jer Noble [MSE][Mac] Add a new MSE-compatible MediaPlayerPrivate implementation, MediaPlayerPrivateMediaSourceAVFObjC https://bugs.webkit.org/show_bug.cgi?id=123378 Reviewed by Eric Carlson. Add an AVFoundation implementation of MediaPlayerPrivate which creates and uses MediaSourcePrivate and SourceBufferPrivate subclasses. Add the new media engine to the list of installed engines: * platform/MediaSample.h: * platform/graphics/MediaPlayer.cpp: (WebCore::installedMediaEngines): * platform/graphics/MediaPlayer.h: Add the new files to the project: * WebCore.xcodeproj/project.pbxproj: Drive by fix for ports who implement seekDouble(): * platform/graphics/MediaPlayerPrivate.h: (WebCore::MediaPlayerPrivateInterface::seekWithTolerance): Add new Video and AudioTrackPrivate types which handle their own enable state: * platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.cpp: Added (WebCore::AudioTrackPrivateMediaSourceAVFObjC::AudioTrackPrivateMediaSourceAVFObjC): (WebCore::AudioTrackPrivateMediaSourceAVFObjC::resetPropertiesFromTrack): (WebCore::AudioTrackPrivateMediaSourceAVFObjC::setAssetTrack): (WebCore::AudioTrackPrivateMediaSourceAVFObjC::assetTrack): (WebCore::AudioTrackPrivateMediaSourceAVFObjC::setEnabled): * platform/graphics/avfoundation/objc/AudioTrackPrivateMediaSourceAVFObjC.h: Added * platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.cpp: Added. (WebCore::VideoTrackPrivateMediaSourceAVFObjC::VideoTrackPrivateMediaSourceAVFObjC): (WebCore::VideoTrackPrivateMediaSourceAVFObjC::resetPropertiesFromTrack): (WebCore::VideoTrackPrivateMediaSourceAVFObjC::setAssetTrack): (WebCore::VideoTrackPrivateMediaSourceAVFObjC::assetTrack): (WebCore::VideoTrackPrivateMediaSourceAVFObjC::setSelected): * platform/graphics/avfoundation/objc/VideoTrackPrivateMediaSourceAVFObjC.h: Added. Add a new MediaPlayerPrivate which can handle MediaSource objects: * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.h: Added. * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm: Added. (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::~MediaPlayerPrivateMediaSourceAVFObjC): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::registerMediaEngine): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::create): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isAvailable): (WebCore::mimeTypeCache): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::getSupportedTypes): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsType): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::load): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::cancelLoad): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::prepareToPlay): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::platformMedia): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::platformLayer): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::play): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::playInternal): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::pause): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::pauseInternal): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::paused): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsScanning): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::naturalSize): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::hasVideo): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::hasAudio): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setVisible): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::durationDouble): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::currentTimeDouble): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::startTimeDouble): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::initialTime): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekWithTolerance): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekInternal): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seeking): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setRateDouble): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::networkState): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::readyState): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::seekable): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::maxTimeSeekableDouble): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::minTimeSeekable): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::buffered): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::didLoadingProgress): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setSize): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::paint): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::paintCurrentFrameInContext): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::hasAvailableVideoFrame): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsAcceleratedRendering): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::acceleratedRenderingStateChanged): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::movieLoadType): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::prepareForRendering): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::engineDescription): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::languageOfPrimaryAudioTrack): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::extraMemoryCost): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureLayer): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::destroyLayer): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::updateDuration): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::updateStates): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setReadyState): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::setNetworkState): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::addDisplayLayer): (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::removeDisplayLayer): Add a new MediaSourcePrivate implementation: * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.h: Added. (WebCore::MediaSourcePrivateAVFObjC::player): (WebCore::MediaSourcePrivateAVFObjC::activeSourceBuffers): * platform/graphics/avfoundation/objc/MediaSourcePrivateAVFObjC.mm: Added. (WebCore::MediaSourcePrivateAVFObjC::create): (WebCore::MediaSourcePrivateAVFObjC::MediaSourcePrivateAVFObjC): (WebCore::MediaSourcePrivateAVFObjC::~MediaSourcePrivateAVFObjC): (WebCore::MediaSourcePrivateAVFObjC::addSourceBuffer): (WebCore::MediaSourcePrivateAVFObjC::removeSourceBuffer): (WebCore::MediaSourcePrivateAVFObjC::duration): (WebCore::MediaSourcePrivateAVFObjC::setDuration): (WebCore::MediaSourcePrivateAVFObjC::markEndOfStream): (WebCore::MediaSourcePrivateAVFObjC::unmarkEndOfStream): (WebCore::MediaSourcePrivateAVFObjC::readyState): (WebCore::MediaSourcePrivateAVFObjC::setReadyState): (WebCore::MediaSourcePrivateAVFObjC::sourceBufferPrivateDidChangeActiveState): (WebCore::MediaSourcePrivateAVFObjCHasAudio): (WebCore::MediaSourcePrivateAVFObjC::hasAudio): (WebCore::MediaSourcePrivateAVFObjCHasVideo): (WebCore::MediaSourcePrivateAVFObjC::hasVideo): (WebCore::MediaSourcePrivateAVFObjC::seekToTime): Add a new SourceBufferPrivate implementation: * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.h: Added. * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: Added. (-[WebAVStreamDataParserListener initWithParser:parent:WebCore::]): (-[WebAVStreamDataParserListener dealloc]): (-[WebAVStreamDataParserListener streamDataParser:didParseStreamDataAsAsset:]): (-[WebAVStreamDataParserListener streamDataParser:didFailToParseStreamDataWithError:]): (-[WebAVStreamDataParserListener streamDataParser:didProvideMediaData:forTrackID:mediaType:flags:]): (-[WebAVStreamDataParserListener streamDataParser:didReachEndOfTrackWithTrackID:mediaType:]): (WebCore::MediaSampleAVFObjC::create): (WebCore::MediaSampleAVFObjC::~MediaSampleAVFObjC): (WebCore::MediaSampleAVFObjC::MediaSampleAVFObjC): (WebCore::MediaSampleAVFObjC::platformSample): (WebCore::CMSampleBufferIsRandomAccess): (WebCore::MediaSampleAVFObjC::flags): (WebCore::MediaDescriptionAVFObjC::create): (WebCore::MediaDescriptionAVFObjC::~MediaDescriptionAVFObjC): (WebCore::MediaDescriptionAVFObjC::MediaDescriptionAVFObjC): (WebCore::SourceBufferPrivateAVFObjC::create): (WebCore::SourceBufferPrivateAVFObjC::SourceBufferPrivateAVFObjC): (WebCore::SourceBufferPrivateAVFObjC::~SourceBufferPrivateAVFObjC): (WebCore::SourceBufferPrivateAVFObjC::didParseStreamDataAsAsset): (WebCore::SourceBufferPrivateAVFObjC::didFailToParseStreamDataWithError): (WebCore::callProcessCodedFrameForEachSample): (WebCore::SourceBufferPrivateAVFObjC::didProvideMediaDataForTrackID): (WebCore::SourceBufferPrivateAVFObjC::processCodedFrame): (WebCore::SourceBufferPrivateAVFObjC::didReachEndOfTrackWithTrackID): (WebCore::SourceBufferPrivateAVFObjC::setClient): (WebCore::SourceBufferPrivateAVFObjC::append): (WebCore::SourceBufferPrivateAVFObjC::abort): (WebCore::SourceBufferPrivateAVFObjC::removedFromMediaSource): (WebCore::SourceBufferPrivateAVFObjC::readyState): (WebCore::SourceBufferPrivateAVFObjC::setReadyState): (WebCore::SourceBufferPrivateAVFObjC::evictCodedFrames): (WebCore::SourceBufferPrivateAVFObjC::isFull): (WebCore::SourceBufferPrivateAVFObjC::hasVideo): (WebCore::SourceBufferPrivateAVFObjC::hasAudio): (WebCore::SourceBufferPrivateAVFObjC::trackDidChangeEnabled): (WebCore::createNonDisplayingCopy): (WebCore::SourceBufferPrivateAVFObjC::flushAndEnqueueNonDisplayingSamples): (WebCore::SourceBufferPrivateAVFObjC::enqueueSample): (WebCore::SourceBufferPrivateAVFObjC::isReadyForMoreSamples): (WebCore::SourceBufferPrivateAVFObjC::setActive): (WebCore::SourceBufferPrivateAVFObjC::fastSeekTimeForMediaTime): (WebCore::SourceBufferPrivateAVFObjC::seekToTime): * platform/mac/PlatformClockCM.h: Add a SOFT_LINK_CLASS_OPTIONAL macro: * platform/mac/SoftLinking.h: 2013-12-06 Alexey Proskuryakov Remove some duplicate checks from SerializedScriptValue https://bugs.webkit.org/show_bug.cgi?id=125358 Reviewed by Geoffrey Garen. There is no need to call inherits() before WebCore's toXXX(JSValue) functions. Also, the result of toArrayBuffer() is a raw pointer, not a RefPtr (it's confusing because toArrayBufferView returns a RefPtr). * bindings/js/SerializedScriptValue.cpp: (WebCore::CloneSerializer::dumpIfTerminal): 2013-12-06 Tim Horton Remove Image::decodedSize() https://bugs.webkit.org/show_bug.cgi?id=125327 Reviewed by Simon Fraser. Missed a comment when removing this code. * svg/graphics/SVGImage.h: 2013-12-06 Rob Buis [CSS Shapes] ShapeOutsideInfo needs to use the parent's writing mode when calculating offsets https://bugs.webkit.org/show_bug.cgi?id=124680 Reviewed by Dirk Schulze. Do not take the writing-mode property on the float into account for shape-outside. Add a virtual method writingMode() in order to do this for shape-outside but keep old behavior (element writingMode) for shape-inside. Change existing test floats/shape-outside-floats-different-writing-modes.html to test the new behavior. * rendering/shapes/ShapeInfo.cpp: (WebCore::::computedShape): * rendering/shapes/ShapeInfo.h: (WebCore::ShapeInfo::writingMode): * rendering/shapes/ShapeOutsideInfo.cpp: (WebCore::ShapeOutsideInfo::writingMode): * rendering/shapes/ShapeOutsideInfo.h: 2013-12-06 Joseph Pecoraro Web Inspector: Remove Staging Workaround https://bugs.webkit.org/show_bug.cgi?id=125354 Reviewed by Timothy Hatcher. * inspector/CodeGeneratorInspector.py: 2013-12-06 Joseph Pecoraro Simplify ScriptFunctionCall by removing dead code. https://bugs.webkit.org/show_bug.cgi?id=125274 Reviewed by Timothy Hatcher. * bindings/js/ScriptFunctionCall.cpp: (WebCore::ScriptFunctionCall::call): * bindings/js/ScriptFunctionCall.h: 2013-12-06 Daniel Bates [iOS] Upstream WebCore/rendering changes https://bugs.webkit.org/show_bug.cgi?id=125239 Reviewed by Simon Fraser. * WebCore.xcodeproj/project.pbxproj: * rendering/InlineBox.cpp: (WebCore::InlineBox::previousOnLineExists): Added. * rendering/InlineBox.h: * rendering/InlineTextBox.cpp: (WebCore::InlineTextBox::paintCompositionBackground): Modified to query RenderStyle on iOS for the composition fill color. Added FIXME to make this platform-independent. (WebCore::InlineTextBox::paintDecoration): Added iOS-specific decoration code. (WebCore::lineStyleForMarkerType): (WebCore::InlineTextBox::paintDocumentMarkers): Added iOS-specific code. Also, added FIXME to make this code platform-independent. * rendering/RenderBlock.cpp: (WebCore::RenderBlock::paint): Ditto. (WebCore::positionForPointRespectingEditingBoundaries): Added iOS-specific code. * rendering/RenderBlock.h: Changed access control of logical{Left, Right}SelectionOffset() from private to protected so that these methods can be used from RenderImage::collectSelectionRects(). * rendering/RenderBox.cpp: (WebCore::RenderBox::borderRadii): Added. (WebCore::RenderBox::paintBoxDecorations): Added iOS-specific workaround. See for more details. (WebCore::RenderBox::computeRectForRepaint): Added iOS-specific code. (WebCore::customContainingBlockWidth): Added; guarded by PLATFORM(IOS). (WebCore::customContainingBlockHeight): Added; guarded by PLATFORM(IOS). (WebCore::customContainingBlockLogicalWidth): Added; guarded by PLATFORM(IOS). (WebCore::customContainingBlockLogicalHeight): Added; guarded by PLATFORM(IOS). (WebCore::customContainingBlockAvailableLogicalHeight): Added; guarded by PLATFORM(IOS). (WebCore::RenderBox::availableLogicalHeightUsing): Added iOS-specific code; calls customContainingBlockAvailableLogicalHeight(). (WebCore::RenderBox::containingBlockLogicalWidthForPositioned): Added iOS-specific code; calls customContainingBlockLogicalWidth(). (WebCore::RenderBox::containingBlockLogicalHeightForPositioned): Added iOS-specific code; calls customContainingBlockLogicalHeight(). (WebCore::RenderBox::layoutOverflowRectForPropagation): Added iOS-specific code. * rendering/RenderBox.h: * rendering/RenderBoxModelObject.cpp: (WebCore::RenderBoxModelObject::stickyPositionOffset): Use FrameView::customFixedPositionLayoutRect() instead of FrameView::viewportConstrainedVisibleContentRect(). * rendering/RenderButton.cpp: (WebCore::RenderButton::layout): Added; iOS-specific. Includes FIXME comment. See for more details. * rendering/RenderElement.cpp: (WebCore::RenderElement::styleWillChange): Added iOS-specific code. (WebCore::RenderElement::styleDidChange): Modified to only call areCursorsEqual() and EventHandler::scheduleCursorUpdate() on a non-iOS port. * rendering/RenderEmbeddedObject.cpp: (WebCore::RenderEmbeddedObject::allowsAcceleratedCompositing): Added iOS-specific code. (WebCore::RenderEmbeddedObject::setPluginUnavailabilityReason): This method has an empty implementation for iOS. (WebCore::RenderEmbeddedObject::setPluginUnavailabilityReasonWithDescription): Ditto. * rendering/RenderFileUploadControl.cpp: (WebCore::nodeHeight): (WebCore::RenderFileUploadControl::maxFilenameWidth): Added iOS-specific code. (WebCore::RenderFileUploadControl::paintObject): Ditto. (WebCore::RenderFileUploadControl::fileTextValue): Ditto. * rendering/RenderFrameSet.cpp: (WebCore::RenderFrameSet::positionFrames): Ditto; Also added FIXME comment as this code may not be specific to iOS. * rendering/RenderIFrame.h: Added iOS-specific workaround to RenderObject::renderName(). Added FIXME comment to determine whether this workaround is still applicable. * rendering/RenderImage.cpp: (WebCore::RenderImage::collectSelectionRects): Added; guarded by PLATFORM(IOS). (WebCore::RenderImage::paintAreaElementFocusRing): This method has an empty implementation for iOS. * rendering/RenderImage.h: * rendering/RenderInline.cpp: (WebCore::RenderInline::absoluteQuadsForSelection): Added; guarded by PLATFORM(IOS). * rendering/RenderInline.h: * rendering/RenderLayer.cpp: (WebCore::RenderLayer::RenderLayer): Added iOS-specific member initialization. (WebCore::RenderLayer::~RenderLayer): Added iOS-specific code. (WebCore::RenderLayer::willBeDestroyed): Added; iOS-specific. (WebCore::RenderLayer::hasAcceleratedTouchScrolling): Ditto. (WebCore::RenderLayer::handleTouchEvent): Ditto. (WebCore::RenderLayer::registerAsTouchEventListenerForScrolling): Ditto. (WebCore::RenderLayer::unregisterAsTouchEventListenerForScrolling): Ditto. (WebCore::RenderLayer::updateNeedsCompositedScrolling): Added iOS-specific code as we use UIKit to composite our scroll bars. (WebCore::RenderLayer::scrollTo): Added iOS-specific code. (WebCore::RenderLayer::scrollRectToVisible): Ditto. (WebCore::RenderLayer::styleChanged): Modified to make use of the passed StyleDifference on iOS. (WebCore::RenderLayer::visibleContentRect): Added; iOS-specific. (WebCore::RenderLayer::didStartScroll): Ditto. (WebCore::RenderLayer::didEndScroll): Ditto. (WebCore::RenderLayer::didUpdateScroll): Ditto. (WebCore::RenderLayer::invalidateScrollbarRect): Added iOS-specific code. (WebCore::RenderLayer::invalidateScrollCornerRect): Ditto. (WebCore::RenderLayer::verticalScrollbarWidth): Ditto. (WebCore::RenderLayer::horizontalScrollbarHeight): Ditto. (WebCore::RenderLayer::updateScrollableAreaSet): Ditto. (WebCore::RenderLayer::updateScrollInfoAfterLayout): Add iOS-specific workaround with FIXME. See for more details. (WebCore::RenderLayer::paintOverflowControls): Added iOS-specific code. (WebCore::RenderLayer::calculateClipRects): Ditto. * rendering/RenderLayer.h: * rendering/RenderLayerBacking.cpp: (WebCore::RenderLayerBacking::createPrimaryGraphicsLayer): Modified to not apply page scale on iOS as we apply a page scale at a different time in the code. (WebCore::RenderLayerBacking::layerWillBeDestroyed): Added; guarded by PLATFORM(IOS). (WebCore::layerOrAncestorIsTransformedOrScrolling): Added iOS-specific variant with FIXME comment. (WebCore::RenderLayerBacking::shouldClipCompositedBounds): Added iOS-specific code. (WebCore::RenderLayerBacking::updateGraphicsLayerConfiguration): Ditto. (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry): Ditto. (WebCore::RenderLayerBacking::registerScrollingLayers): Ditto. (WebCore::RenderLayerBacking::updateScrollingLayers): Ditto. (WebCore::RenderLayerBacking::containsPaintedContent): Call RenderLayer::hasBoxDecorationsOrBackground() when building on iOS Simulator. (WebCore::RenderLayerBacking::parentForSublayers): Added iOS-specific code and FIXME comment. (WebCore::RenderLayerBacking::paintsIntoWindow): Opt-into coordinated graphics code path. (WebCore::RenderLayerBacking::setContentsNeedDisplayInRect): Added iOS-specific code. (WebCore::RenderLayerBacking::paintIntoLayer): Compile-out ASSERT_NOT_REACHED for iOS and added FIXME comment. * rendering/RenderLayerBacking.h: * rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::scheduleLayerFlush): Added iOS-specific code. (WebCore::RenderLayerCompositor::chromeClient): Added; guarded by PLATFORM(IOS). (WebCore::RenderLayerCompositor::flushPendingLayerChanges): Added iOS-specific code. (WebCore::scrollbarHasDisplayNone): Added; iOS-specific. (WebCore::updateScrollingLayerWithClient): Ditto. (WebCore::RenderLayerCompositor::updateCustomLayersAfterFlush): Ditto. (WebCore::RenderLayerCompositor::didFlushChangesForLayer): Added iOS-specific code. (WebCore::RenderLayerCompositor::didChangeVisibleRect): Ditto. (WebCore::RenderLayerCompositor::addToOverlapMap): Don't apply page scale factor on iOS. We apply the page scale factor at a different time in the code. Also, added FIXME comment. (WebCore::RenderLayerCompositor::computeCompositingRequirements): Added iOS-specific workaround. See for more details. (WebCore::RenderLayerCompositor::setIsInWindow): Use non-Mac code path for iOS. (WebCore::RenderLayerCompositor::allowsIndependentlyCompositedFrames): Added iOS-specific code. (WebCore::RenderLayerCompositor::requiresCompositingLayer): Ditto. (WebCore::RenderLayerCompositor::requiresOwnBackingStore): Ditto. (WebCore::RenderLayerCompositor::reasonsForCompositing): Ditto. (WebCore::RenderLayerCompositor::requiresCompositingForAnimation): Opt-into calling AnimationController::isRunningAnimationOnRenderer() on iOS. (WebCore::RenderLayerCompositor::requiresCompositingForScrolling): Added; guarded by PLATFORM(IOS). (WebCore::isStickyInAcceleratedScrollingLayerOrViewport): Added iOS-specific code. (WebCore::isViewportConstrainedFixedOrStickyLayer): Ditto. (WebCore::RenderLayerCompositor::requiresCompositingForPosition): Use FrameView::customFixedPositionLayoutRect() instead of FrameView::viewportConstrainedVisibleContentRect(). (WebCore::RenderLayerCompositor::contentsScaleMultiplierForNewTiles): Ditto. (WebCore::RenderLayerCompositor::ensureRootLayer): Ditto. (WebCore::RenderLayerCompositor::computeFixedViewportConstraints): Use FrameView::customFixedPositionLayoutRect() instead of FrameView::viewportConstrainedVisibleContentRect(). (WebCore::RenderLayerCompositor::computeStickyViewportConstraints): Ditto. (WebCore::RenderLayerCompositor::registerOrUpdateViewportConstrainedLayer): This method has an empty implementation for iOS as we batch update viewport-constrained layers in the iOS-specific method, RenderLayerCompositor::updateCustomLayersAfterFlush(). (WebCore::RenderLayerCompositor::unregisterViewportConstrainedLayer): Ditto. (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers): Added; guarded by PLATFORM(IOS). (WebCore::RenderLayerCompositor::unregisterAllViewportConstrainedLayers): Ditto. (WebCore::RenderLayerCompositor::registerAllScrollingLayers): Ditto. (WebCore::RenderLayerCompositor::unregisterAllScrollingLayers): Ditto. (WebCore::RenderLayerCompositor::scrollingLayerAddedOrUpdated): Ditto. (WebCore::RenderLayerCompositor::scrollingLayerRemoved): Ditto. (WebCore::RenderLayerCompositor::startInitialLayerFlushTimerIfNeeded): Ditto. * rendering/RenderLayerCompositor.h: * rendering/RenderLayerFilterInfo.h: Added iOS-specific Clang workaround to ignore an unused private field. * rendering/RenderMenuList.cpp: (WebCore::selectedOptionCount): Added; guarded by PLATFORM(IOS). (WebCore::RenderMenuList::RenderMenuList): On iOS we don't make use of RenderMenuList::m_popupIsVisible. (WebCore::RenderMenuList::~RenderMenuList): On iOS we don't make use of RenderMenuList::m_popup. (WebCore::RenderMenuList::adjustInnerStyle): Add iOS-specific code. (RenderMenuList::updateFromElement): On iOS we don't make use of RenderMenuList::m_popup. (RenderMenuList::setTextFromOption): Add iOS-specific code. (RenderMenuList::showPopup): Define RenderMenuList::showPopup() to ASSERT_NOT_REACHED() on iOS as we don't make use of RenderMenuList::m_popup. (RenderMenuList::hidePopup): This method has an empty implementation for iOS as we don't make use of RenderMenuList::m_popup. (RenderMenuList::popupDidHide): This method has an empty implementation for iOS as we don't make use of RenderMenuList::m_popupIsVisible. * rendering/RenderMenuList.h: * rendering/RenderObject.cpp: (WebCore::RenderObject::columnNumberForOffset): Added; guarded by PLATFORM(IOS). Also, added a FIXME comment to make this function return an unsigned integer instead of a signed integer. (WebCore::RenderObject::collectSelectionRects): Added; guarded by PLATFORM(IOS). (WebCore::RenderObject::destroy): Added iOS-specific code. (WebCore::RenderObject::innerLineHeight): Added. (WebCore::RenderObject::willRenderImage): Added iOS-specific code. * rendering/RenderObject.h: Change the access control of RenderObject::drawLineForBoxSide() from protected to public so that it can be used from RenderThemeIOS::adjustMenuListButtonStyle(). (WebCore::RenderObject::absoluteQuadsForSelection): * rendering/RenderScrollbar.h: Change the access control of RenderScrollbar::getScrollbarPseudoStyle() from private to public so that it can be used from the iOS-specific static function, scrollbarHasDisplayNone, defined in RenderLayerCompositor.cpp. * rendering/RenderSearchField.cpp: (WebCore::RenderSearchField::itemText): Added iOS-specific code. * rendering/RenderText.cpp: (WebCore::RenderText::collectSelectionRects): Added; guarded by PLATFORM(IOS). (WebCore::RenderText::setTextInternal): Added iOS-specific code. * rendering/RenderText.h: * rendering/RenderTextControl.cpp: (WebCore::RenderTextControl::adjustInnerTextStyle): Ditto. (WebCore::RenderTextControl::canScroll): Added; guarded by PLATFORM(IOS). (WebCore::RenderTextControl::innerLineHeight): Ditto. * rendering/RenderTextControl.h: * rendering/RenderTextControlMultiLine.cpp: (WebCore::RenderTextControlMultiLine::getAvgCharWidth): Compile-out code when building for iOS. (WebCore::RenderTextControlMultiLine::createInnerTextStyle): Added iOS-specific code. * rendering/RenderTextControlSingleLine.cpp: (WebCore::RenderTextControlSingleLine::layout): Ditto. (WebCore::RenderTextControlSingleLine::getAvgCharWidth): Compile-out code when building for iOS. (WebCore::RenderTextControlSingleLine::preferredContentLogicalWidth): Ditto. * rendering/RenderTextLineBoxes.cpp: (WebCore::lineDirectionPointFitsInBox): Ditto. (WebCore::RenderTextLineBoxes::positionForPoint): Added iOS-specific code. * rendering/RenderTheme.cpp: (WebCore::RenderTheme::paintBorderOnly): Ditto. (WebCore::RenderTheme::paintDecorations): Modified to call the control-specific paint*Decorations(). * rendering/RenderTheme.h: (WebCore::RenderTheme::paintCheckboxDecorations): Added. (WebCore::RenderTheme::paintRadioDecorations): Added. (WebCore::RenderTheme::paintButtonDecorations): Added. (WebCore::RenderTheme::paintTextFieldDecorations): Added. (WebCore::RenderTheme::paintTextAreaDecorations): Added. (WebCore::RenderTheme::paintMenuListDecorations): Added. (WebCore::RenderTheme::paintPushButtonDecorations): Added. (WebCore::RenderTheme::paintSquareButtonDecorations): Added. (WebCore::RenderTheme::paintFileUploadIconDecorations): Added. (WebCore::RenderTheme::paintSliderThumbDecorations): Added. (WebCore::RenderTheme::paintSearchFieldDecorations): Added. * rendering/RenderThemeIOS.h: Added. * rendering/RenderThemeIOS.mm: Added. * rendering/RenderThemeMac.h: Don't compile the contents of this file when building for iOS. * rendering/RenderThemeMac.mm: Ditto. * rendering/RenderVideo.cpp: (WebCore::RenderVideo::calculateIntrinsicSize): Compile-out code when building for iOS. * rendering/RenderView.cpp: (WebCore::RenderView::availableLogicalHeight): Add iOS-specific workaround. See . (WebCore::fixedPositionOffset): Added; used in iOS-specific code (e.g. RenderView::mapLocalToContainer()). (WebCore::RenderView::mapLocalToContainer): Use WebCore::fixedPositionOffset() instead of FrameView::scrollOffsetForFixedPosition(). (WebCore::RenderView::pushMappingToContainer): Ditto. (WebCore::RenderView::mapAbsoluteToLocalPoint): Ditto. (WebCore::RenderView::repaintViewRectangle): Ditto. (WebCore::RenderView::computeRectForRepaint): Ditto. (WebCore::isFixedPositionInViewport): Added; used in RenderView::hasCustomFixedPosition(). (WebCore::RenderView::hasCustomFixedPosition): Added; guarded by PLATFORM(IOS). * rendering/RenderView.h: * rendering/RenderWidget.cpp: (WebCore::RenderWidget::willBeDestroyed): Added iOS-specific code. * rendering/RootInlineBox.cpp: (WebCore::RootInlineBox::ascentAndDescentForBox): Ditto. * rendering/break_lines.cpp: Only include header when building for Mac. 2013-12-06 Zoltan Horvath Clean up the includes of RenderBlock.h https://bugs.webkit.org/show_bug.cgi?id=125351 Reviewed by Darin Adler. I turned some header includes into forward declarations. I also removed / moved out some includes, which don't belong to RenderBlock.h anymore. No new tests, no behavior change. * editing/VisibleUnits.cpp: * html/HTMLInputElement.cpp: * html/HTMLTextAreaElement.cpp: * html/TextFieldInputType.cpp: * html/TextInputType.cpp: * rendering/InlineElementBox.cpp: * rendering/RenderBlock.h: * rendering/RenderBlockFlow.cpp: * rendering/line/LineBreaker.h: * rendering/line/LineWidth.cpp: 2013-12-06 Laszlo Vidacs Define SHA1 hash size in SHA1.h and use it at various places. https://bugs.webkit.org/show_bug.cgi?id=125345 Reviewed by Darin Adler. Use SHA1::hashSize instead of local variables. * Modules/websockets/WebSocketHandshake.cpp: (WebCore::WebSocketHandshake::getExpectedWebSocketAccept): * platform/network/soup/ResourceHandleSoup.cpp: (WebCore::HostTLSCertificateSet::computeCertificateHash): 2013-12-06 Dan Bernstein [Cocoa] Add load delegate methods for responding to authentication challenges https://bugs.webkit.org/show_bug.cgi?id=125333 Reviewed by Darin Adler. * WebCore.exp.in: Exported core(NSURLCredential *). 2013-12-06 Daniel Bates Rename {adjust, paint}SearchFieldDecoration, {adjust, paint}SearchFieldResultsDecoration https://bugs.webkit.org/show_bug.cgi?id=125191 Reviewed by Joseph Pecoraro. Towards upstreaming the iOS concept of render theme decorations, we should rename RenderTheme::{adjust, paint}SearchFieldDecorationStyle and RenderTheme::{adjust, paint}SearchFieldResultsDecoration to avoid ambiguity with the iOS concept. * platform/efl/RenderThemeEfl.cpp: * platform/efl/RenderThemeEfl.h: * platform/gtk/RenderThemeGtk.cpp: * platform/gtk/RenderThemeGtk.h: * rendering/RenderTheme.cpp: * rendering/RenderTheme.h: * rendering/RenderThemeMac.h: * rendering/RenderThemeMac.mm: * rendering/RenderThemeSafari.cpp: * rendering/RenderThemeSafari.h: * rendering/RenderThemeWin.cpp: * rendering/RenderThemeWin.h: * rendering/RenderThemeWinCE.cpp: * rendering/RenderThemeWinCE.h: 2013-12-06 Andreas Kling Make remaining CSSValue constructors return PassRef. Tweak the remaining CSSValue create() helpers to return PassRef instead of PassRefPtr in the cases where nullptr is never returned. Reviewed by Anders Carlsson. 2013-12-06 Roger Fong Hook into some shader symbol logic following the ANGLE update in r159533. https://bugs.webkit.org/show_bug.cgi?id=125332. Reviewed by Brent Fulgham. No new functionality added. * html/canvas/WebGLRenderingContext.cpp: Add some error checking for errors related to shader symbols that exist across both vertex and fragment shaders. (WebCore::WebGLRenderingContext::linkProgram): * platform/graphics/ANGLEWebKitBridge.cpp: Add logic for handling varyings and add new fields to the ANGLEShaderSymbol struct. (WebCore::getSymbolInfo): * platform/graphics/ANGLEWebKitBridge.h: * platform/graphics/GraphicsContext3D.h: Add those same fields to the SymbolInfo struct as well so that we can access them from our shader source map. Also add a map of varyings along side the uniforms and attributes. (WebCore::GraphicsContext3D::SymbolInfo::SymbolInfo): (WebCore::GraphicsContext3D::ShaderSourceEntry::symbolMap): * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp: (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE): * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp: (WebCore::GraphicsContext3D::areProgramSymbolsValid): Will be filled in later, this method will use the shader source map to check for issues with unused varyings and precisions mismatches of shader symbols that exist across both the vertex and fragment shaders. 2013-12-06 Lukasz Gajowy [ATK] Missing aria roles mappings https://bugs.webkit.org/show_bug.cgi?id=117729 Reviewed by Mario Sanchez Prada. Added a few mappings from ARIA roles to ATK roles. Test: accessibility/aria-mappings.html * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (atkRole): 2013-11-11 Philippe Normand [GStreamer] webkitwebaudiosrc element needs to emit stream-start, caps and segment events https://bugs.webkit.org/show_bug.cgi?id=123015 Reviewed by Martin Robinson. When the source element starts emitting buffers send along various events to notify downstream elements. No new tests, change covered by existing webaudio tests. * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp: (webkit_web_audio_src_init): Initialize segment. (webKitWebAudioSrcConstructed): Give an explicit name to each queue added in front of the interleave element. (webKitWebAudioSrcLoop): Before sending the first buffers push stream-start, caps and segment events on each queue's sinkpad. 2013-12-05 Philippe Normand [GStreamer] Audio/Video sink management is incoherent https://bugs.webkit.org/show_bug.cgi?id=125304 Reviewed by Gustavo Noronha Silva. Allow subclasses of MediaPlayerPrivateGStreamerBase to create custom audio/video sinks in a coherent manner using create{Audio,Video}Sink methods. Convenience getters are also available. Also removed some un-needed member variables in the playbin-based player. No new tests, existing media tests cover this change. * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp: (WebCore::MediaPlayerPrivateGStreamer::MediaPlayerPrivateGStreamer): (WebCore::MediaPlayerPrivateGStreamer::updateStates): (WebCore::MediaPlayerPrivateGStreamer::createAudioSink): (WebCore::MediaPlayerPrivateGStreamer::audioSink): (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin): * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h: * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h: (WebCore::MediaPlayerPrivateGStreamerBase::createAudioSink): 2013-12-05 Gyuyoung Kim Introduce IMAGE_TYPE_CASTS, and use it https://bugs.webkit.org/show_bug.cgi?id=125330 Reviewed by Ryosuke Niwa. As a step to use TYPE_CASTS_BASE, this cl introduce IMAGE_TYPE_CASTS. BitmapImage and SVGImage can use it to generate toFoo() type case helper functions. No new tests, no behavior changes. * loader/cache/CachedImage.cpp: (WebCore::CachedImage::imageSizeForRenderer): (WebCore::CachedImage::resumeAnimatingImagesForLoader): * platform/graphics/BitmapImage.h: * platform/graphics/Image.h: * platform/mac/DragImageMac.mm: (WebCore::createDragImageFromImage): * svg/graphics/SVGImage.h: 2013-12-05 Zoltan Horvath Clean up the forwarding headers of RenderBlock.h https://bugs.webkit.org/show_bug.cgi?id=125323 Reviewed by Ryosuke Niwa. In this patch, I removed the unnecessary forwarding headers from RenderBlock.h, and moved some to RenderBlockFlow.h. No new tests, no behavior change. * rendering/RenderBlock.h: Remove unnecessary forwarding headers. * rendering/RenderBlockFlow.h: Moved some forwarding headers from RenderBlock.h 2013-12-04 Oliver Hunt Refactor static getter function prototype to include thisValue in addition to the base object https://bugs.webkit.org/show_bug.cgi?id=124461 Reviewed by Geoffrey Garen. Change bindings codegen to produce static getter functions with the correct types. Also update the many custom implementations to the new type. No change in behaviour. * bindings/js/JSCSSStyleDeclarationCustom.cpp: (WebCore::cssPropertyGetterPixelOrPosPrefixCallback): (WebCore::cssPropertyGetterCallback): * bindings/js/JSDOMBinding.cpp: (WebCore::objectToStringFunctionGetter): * bindings/js/JSDOMBinding.h: * bindings/js/JSDOMMimeTypeArrayCustom.cpp: (WebCore::JSDOMMimeTypeArray::nameGetter): * bindings/js/JSDOMPluginArrayCustom.cpp: (WebCore::JSDOMPluginArray::nameGetter): * bindings/js/JSDOMPluginCustom.cpp: (WebCore::JSDOMPlugin::nameGetter): * bindings/js/JSDOMStringMapCustom.cpp: (WebCore::JSDOMStringMap::nameGetter): * bindings/js/JSDOMWindowCustom.cpp: (WebCore::nonCachingStaticFunctionGetter): (WebCore::childFrameGetter): (WebCore::indexGetter): (WebCore::namedItemGetter): * bindings/js/JSHTMLAllCollectionCustom.cpp: (WebCore::JSHTMLAllCollection::nameGetter): * bindings/js/JSHTMLCollectionCustom.cpp: (WebCore::JSHTMLCollection::nameGetter): * bindings/js/JSHTMLDocumentCustom.cpp: (WebCore::JSHTMLDocument::nameGetter): * bindings/js/JSHTMLFormControlsCollectionCustom.cpp: (WebCore::JSHTMLFormControlsCollection::nameGetter): * bindings/js/JSHTMLFormElementCustom.cpp: (WebCore::JSHTMLFormElement::nameGetter): * bindings/js/JSHTMLFrameSetElementCustom.cpp: (WebCore::JSHTMLFrameSetElement::nameGetter): * bindings/js/JSHistoryCustom.cpp: (WebCore::nonCachingStaticBackFunctionGetter): (WebCore::nonCachingStaticForwardFunctionGetter): (WebCore::nonCachingStaticGoFunctionGetter): * bindings/js/JSJavaScriptCallFrameCustom.cpp: (WebCore::JSJavaScriptCallFrame::scopeType): * bindings/js/JSLocationCustom.cpp: (WebCore::nonCachingStaticReplaceFunctionGetter): (WebCore::nonCachingStaticReloadFunctionGetter): (WebCore::nonCachingStaticAssignFunctionGetter): * bindings/js/JSNamedNodeMapCustom.cpp: (WebCore::JSNamedNodeMap::nameGetter): * bindings/js/JSNodeListCustom.cpp: (WebCore::JSNodeList::nameGetter): * bindings/js/JSPluginElementFunctions.cpp: (WebCore::pluginElementPropertyGetter): * bindings/js/JSPluginElementFunctions.h: * bindings/js/JSRTCStatsResponseCustom.cpp: (WebCore::JSRTCStatsResponse::nameGetter): * bindings/js/JSStorageCustom.cpp: (WebCore::JSStorage::nameGetter): * bindings/js/JSStyleSheetListCustom.cpp: (WebCore::JSStyleSheetList::nameGetter): * bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader): (GenerateImplementation): (GenerateParametersCheck): * bridge/runtime_array.cpp: (JSC::RuntimeArray::lengthGetter): (JSC::RuntimeArray::indexGetter): * bridge/runtime_array.h: * bridge/runtime_method.cpp: (JSC::RuntimeMethod::lengthGetter): * bridge/runtime_method.h: * bridge/runtime_object.cpp: (JSC::Bindings::RuntimeObject::fallbackObjectGetter): (JSC::Bindings::RuntimeObject::fieldGetter): (JSC::Bindings::RuntimeObject::methodGetter): * bridge/runtime_object.h: 2013-12-05 Tim Horton Remove Image::decodedSize() https://bugs.webkit.org/show_bug.cgi?id=125327 Reviewed by Sam Weinig. No new tests, just removing dead code. * platform/graphics/BitmapImage.cpp: (WebCore::BitmapImage::resetAnimation): * platform/graphics/BitmapImage.h: * platform/graphics/GeneratedImage.h: * platform/graphics/Image.h: * platform/graphics/cg/PDFDocumentImage.cpp: * platform/graphics/cg/PDFDocumentImage.h: * svg/graphics/SVGImage.h: * svg/graphics/SVGImageForContainer.h: 2013-12-05 Commit Queue Unreviewed, rolling out r160133. http://trac.webkit.org/changeset/160133 https://bugs.webkit.org/show_bug.cgi?id=125325 broke bindings tests on all the bots (Requested by thorton on #webkit). * bindings/js/JSCSSStyleDeclarationCustom.cpp: (WebCore::cssPropertyGetterPixelOrPosPrefixCallback): (WebCore::cssPropertyGetterCallback): * bindings/js/JSDOMBinding.cpp: (WebCore::objectToStringFunctionGetter): * bindings/js/JSDOMBinding.h: * bindings/js/JSDOMMimeTypeArrayCustom.cpp: (WebCore::JSDOMMimeTypeArray::nameGetter): * bindings/js/JSDOMPluginArrayCustom.cpp: (WebCore::JSDOMPluginArray::nameGetter): * bindings/js/JSDOMPluginCustom.cpp: (WebCore::JSDOMPlugin::nameGetter): * bindings/js/JSDOMStringMapCustom.cpp: (WebCore::JSDOMStringMap::nameGetter): * bindings/js/JSDOMWindowCustom.cpp: (WebCore::nonCachingStaticFunctionGetter): (WebCore::childFrameGetter): (WebCore::indexGetter): (WebCore::namedItemGetter): * bindings/js/JSHTMLAllCollectionCustom.cpp: (WebCore::JSHTMLAllCollection::nameGetter): * bindings/js/JSHTMLCollectionCustom.cpp: (WebCore::JSHTMLCollection::nameGetter): * bindings/js/JSHTMLDocumentCustom.cpp: (WebCore::JSHTMLDocument::nameGetter): * bindings/js/JSHTMLFormControlsCollectionCustom.cpp: (WebCore::JSHTMLFormControlsCollection::nameGetter): * bindings/js/JSHTMLFormElementCustom.cpp: (WebCore::JSHTMLFormElement::nameGetter): * bindings/js/JSHTMLFrameSetElementCustom.cpp: (WebCore::JSHTMLFrameSetElement::nameGetter): * bindings/js/JSHistoryCustom.cpp: (WebCore::nonCachingStaticBackFunctionGetter): (WebCore::nonCachingStaticForwardFunctionGetter): (WebCore::nonCachingStaticGoFunctionGetter): * bindings/js/JSJavaScriptCallFrameCustom.cpp: (WebCore::JSJavaScriptCallFrame::scopeType): * bindings/js/JSLocationCustom.cpp: (WebCore::nonCachingStaticReplaceFunctionGetter): (WebCore::nonCachingStaticReloadFunctionGetter): (WebCore::nonCachingStaticAssignFunctionGetter): * bindings/js/JSNamedNodeMapCustom.cpp: (WebCore::JSNamedNodeMap::nameGetter): * bindings/js/JSNodeListCustom.cpp: (WebCore::JSNodeList::nameGetter): * bindings/js/JSPluginElementFunctions.cpp: (WebCore::pluginElementPropertyGetter): * bindings/js/JSPluginElementFunctions.h: * bindings/js/JSRTCStatsResponseCustom.cpp: (WebCore::JSRTCStatsResponse::nameGetter): * bindings/js/JSStorageCustom.cpp: (WebCore::JSStorage::nameGetter): * bindings/js/JSStyleSheetListCustom.cpp: (WebCore::JSStyleSheetList::nameGetter): * bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader): (GenerateImplementation): (GenerateParametersCheck): * bridge/runtime_array.cpp: (JSC::RuntimeArray::lengthGetter): (JSC::RuntimeArray::indexGetter): * bridge/runtime_array.h: * bridge/runtime_method.cpp: (JSC::RuntimeMethod::lengthGetter): * bridge/runtime_method.h: * bridge/runtime_object.cpp: (JSC::Bindings::RuntimeObject::fallbackObjectGetter): (JSC::Bindings::RuntimeObject::fieldGetter): (JSC::Bindings::RuntimeObject::methodGetter): * bridge/runtime_object.h: 2013-12-05 Seokju Kwon Web Inspector: Remove 'cookiesString' output from Page.getCookies https://bugs.webkit.org/show_bug.cgi?id=125268 Reviewed by Timothy Hatcher. Remove 'cookiesString' output from Page.getCookies protocol. It is no longer meaningful because it is an unused parameter. No new tests, no behavior change. * inspector/InspectorPageAgent.cpp: (WebCore::InspectorPageAgent::getCookies): * inspector/InspectorPageAgent.h: * inspector/protocol/Page.json: 2013-12-05 Brian J. Burg Web Inspector: expose node and frame snapshot capabilities. https://bugs.webkit.org/show_bug.cgi?id=124326 Reviewed by Joseph Pecoraro. This adds snapshotRect() and snapshotNode() to the Page domain. Both methods create snapshots using FrameSnapshotting APIs and send images to the inspector frontend as a data URL. Remove the unimplemented Page.captureScreenshot API. * inspector/InspectorPageAgent.cpp: (WebCore::InspectorPageAgent::snapshotNode): Added. (WebCore::InspectorPageAgent::snapshotRect): Added. * inspector/InspectorPageAgent.h: * inspector/protocol/Page.json: Added new protocol APIs. 2013-12-04 Bear Travis [CSS Shapes] Enable CSS Shapes on Windows https://bugs.webkit.org/show_bug.cgi?id=89957 Reviewed by Brent Fulgham. * css/CSSPropertyNames.in: Tweak to ensure shapes properties are regenerated. 2013-12-05 Roger Fong [WebGL] Make sure we satisfy uniform and varying packing restrictions. https://bugs.webkit.org/show_bug.cgi?id=125124. Reviewed by Brent Fulgham. Tests covered by WebGL Khronos conformance tests: webgl/1.0.2/conformance/glsl/misc/shader-uniform-packing-restrictions.html webgl/1.0.2/conformance/glsl/misc/shader-varying-packing-restrictions.html * platform/graphics/opengl/Extensions3DOpenGLCommon.cpp: (WebCore::Extensions3DOpenGLCommon::getTranslatedShaderSourceANGLE): 2013-12-05 Laszlo Vidacs 32bit buildfix after r160151 https://bugs.webkit.org/show_bug.cgi?id=125298 Reviewed by Csaba Osztrogonác. * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp: (StreamingClient::handleDataReceived): 2013-12-05 Myles C. Maxfield Cropping and drawing ImageBuffers results in uninitialized data being shown https://bugs.webkit.org/show_bug.cgi?id=125271 Reviewed by Simon Fraser. createCroppedImageIfNecessary() crops to the bottom left of the ImageBuffer backing store instead of the top left. In addition, ImageBuffer::draw() draws the entire ImageBuffer's backing store instead of just the relevant portion of it. No new tests are necessary because the existing tests already test this functionality * platform/graphics/cg/ImageBufferCG.cpp: (WebCore::createCroppedImageIfNecessary): Crop to the top left of the backing store (WebCore::ImageBuffer::draw): Draw only the logical portion of the backing store 2013-12-05 Joseph Pecoraro Remove stale ScriptGlobalObject methods https://bugs.webkit.org/show_bug.cgi?id=125276 Reviewed by Sam Weinig. * bindings/js/ScriptObject.cpp: (WebCore::ScriptGlobalObject::set): * bindings/js/ScriptObject.h: 2013-12-04 Ryosuke Niwa Change how the form element pointer affects parsing template elements, to reduce weirdness in templates https://bugs.webkit.org/show_bug.cgi?id=125279 Reviewed by Antti Koivisto. Faithfully update the HTML5 parser after http://html5.org/tools/web-apps-tracker?from=8330&to=8331. Test: fast/dom/HTMLTemplateElement/no-form-association-2.html * html/parser/HTMLConstructionSite.cpp: (WebCore::HTMLConstructionSite::insertHTMLFormElement): Don't the form element pointer if the context element or its ancestor is a template element. (WebCore::HTMLConstructionSite::insideTemplateElement): Added. (WebCore::HTMLConstructionSite::createHTMLElement): Renamed openElementsContainTemplateElement to insideTemplateElement to reflect the true semantics of the boolean. * html/parser/HTMLConstructionSite.h: * html/parser/HTMLTreeBuilder.cpp: (WebCore::HTMLTreeBuilder::processIsindexStartTagForInBody): Ignore the form element pointer if there is a template element on the stack of open elements. This faithfully reflects what's being said in the specification. We should probably make isParsingTemplateContents more efficient by storing a boolean and then wrap from() in some helper function but that should probbaly happen in a separate patch. (WebCore::HTMLTreeBuilder::processStartTagForInBody): Ditto. (WebCore::HTMLTreeBuilder::processStartTagForInTable): Ditto. (WebCore::HTMLTreeBuilder::processEndTagForInBody): Don't unset or rely on the form element pointer when there is a template element on the stack of open elements. * html/parser/HTMLTreeBuilder.h: (WebCore::HTMLTreeBuilder::isParsingTemplateContents): Added a trivial implementation for when TEMPLATE_ELEMENT is disabled. (WebCore::HTMLTreeBuilder::isParsingFragmentOrTemplateContents): Merged two implementations. 2013-12-05 Thiago de Barros Lacerda [MediaStream] Firing negotiationneeded event upon track add/remove on MediaStream https://bugs.webkit.org/show_bug.cgi?id=125243 Reviewed by Eric Carlson. Spec states that: In particular, if an RTCPeerConnection object is consuming a MediaStream on which a track is added, by, e.g., the addTrack() method being invoked, the RTCPeerConnection object must fire the "negotiationneeded" event. Removal of media components must also trigger "negotiationneeded". Existing tests updated. * Modules/mediastream/MediaStream.cpp: (WebCore::MediaStream::addTrack): (WebCore::MediaStream::removeTrack): (WebCore::MediaStream::addObserver): (WebCore::MediaStream::removeObserver): * Modules/mediastream/MediaStream.h: * Modules/mediastream/RTCPeerConnection.cpp: (WebCore::RTCPeerConnection::~RTCPeerConnection): (WebCore::RTCPeerConnection::addStream): (WebCore::RTCPeerConnection::removeStream): (WebCore::RTCPeerConnection::didAddOrRemoveTrack): * Modules/mediastream/RTCPeerConnection.h: * platform/mock/RTCPeerConnectionHandlerMock.cpp: (WebCore::RTCPeerConnectionHandlerMock::addStream): 2013-12-05 Beth Dakin Bad repaints on twitter when the tile cache has a margin https://bugs.webkit.org/show_bug.cgi?id=125263 -and corresponding- Reviewed by Tim Horton. When tiles that used to be margin tiles become real-content tiles, they need to be invalidated. Two new helper functions will make it so that we don’t have to manually factor out the margin from the bounds in more than one place in the code. * platform/graphics/ca/mac/TileController.h: * platform/graphics/ca/mac/TileController.mm: (WebCore::TileController::boundsWithoutMargin): (WebCore::TileController::boundsAtLastRevalidateWithoutMargin): Here is one existing place where we used to factor out the margin, but now we can call boundsWithoutMargin(). (WebCore::TileController::adjustRectAtTileIndexForMargin): And here is where we invalidate the formerly-margin tiles. (WebCore::TileController::revalidateTiles): 2013-12-05 Zoltan Horvath Remove the forward declaration of BidiContext class from RenderBlock.h https://bugs.webkit.org/show_bug.cgi?id=125265 Reviewed by Csaba Osztrogonác. No new tests, no behavior change. * rendering/RenderBlock.h: BidiContext is not used in RenderBlock.h 2013-12-05 Aloisio Almeida Jr [Cairo] Avoid extra copy when drawing images https://bugs.webkit.org/show_bug.cgi?id=124209 Reviewed by Carlos Garcia Campos. This commit applies some changes proposed after the original patch has been landed. It fixes the logic to create the subsurface (as it was inverted). It also remove an unnecessary RefPtr variable to hold the subsurface. No new tests. It's an enhancement. Already covered by existing tests. * platform/graphics/cairo/PlatformContextCairo.cpp: (WebCore::PlatformContextCairo::drawSurfaceToContext): 2013-12-05 Zoltan Horvath [CSS Shapes] Fix inset when only a subset of the arguments are defined https://bugs.webkit.org/show_bug.cgi?id=125277 Reviewed by David Hyatt. I thought Length's default value is fixed-0, but actually it's auto-0. For the optional arguments of inset shape, we need to use fixed-0, so I updated the code and the tests to use that explicitly. No new tests, I updated the old ones. * css/BasicShapeFunctions.cpp: (WebCore::basicShapeForValue): 2013-12-05 Carlos Garcia Campos [GTK] Do not use deprecated gtk-doc 'Rename to' tag https://bugs.webkit.org/show_bug.cgi?id=125303 Reviewed by Philippe Normand. GObject introspection rename-to annotation is available in since version 0.6.3 so we should use that instead. * bindings/gobject/WebKitDOMEventTarget.h: 2013-12-05 Carlos Garcia Campos [GTK] Add missing symbols to WebKitDOMDeprecated.symbols https://bugs.webkit.org/show_bug.cgi?id=125300 Reviewed by Philippe Normand. Add webkit_dom_html_element_get_id and webkit_dom_html_element_set_id to the symbols files. * bindings/gobject/WebKitDOMDeprecated.symbols: * bindings/gobject/webkitdom.symbols: 2013-12-05 Carlos Garcia Campos Unreviewed. Update GObject DOM bindings symbols file after r159711. * bindings/gobject/webkitdom.symbols: 2013-12-05 Zan Dobersek [GTK] Move platform sources free of layering violations under libPlatform https://bugs.webkit.org/show_bug.cgi?id=117509 Reviewed by Carlos Garcia Campos. * GNUmakefile.list.am: Move additional source files located in the platform layer under libPlatform. All moved sources are free of layering violations and thus ready for the migration. 2013-12-05 László Langó Remove bridge/testqtbindings.cpp. https://bugs.webkit.org/show_bug.cgi?id=125287 Reviewed by Alexey Proskuryakov. * bridge/testqtbindings.cpp: Removed. There is no QT anymore. We don't need this file. 2013-12-04 Gurpreet Kaur % unit heights don't work if parent block height is set in vh https://bugs.webkit.org/show_bug.cgi?id=118516 Reviewed by Simon Fraser. From Blink r156449 by An element having height as percentage needs to have the containingblock's height or availableheight to calculate its own height. The containing block having a height set in vh unit was not being considered for calculating the child's height. Tests: fast/css/viewport-percentage-compute-box-height.html fast/css/viewport-percentage-compute-box-width.html * rendering/RenderBox.cpp: (WebCore::RenderBox::computePercentageLogicalHeight): Correct child's height(in pecentage) was not being calculated incase of parent having height set in vh unit. Added condition to calculate the containing block height in terms of viewport size. 2013-12-04 Roger Fong [Windows] Unreviewed build fix. Copy headers from rendering/line to build directory. * WebCore.vcxproj/copyForwardingHeaders.cmd: 2013-12-04 Ryosuke Niwa bgColor, setBgColor, alinkColor, setAlinkColor, and etc... on HTMLBodyElement are useless https://bugs.webkit.org/show_bug.cgi?id=125208 Rubber-stamped by Anders Carlsson. Address Darin's comment to use fastGetAttribute instead of getAttribute. * html/HTMLDocument.cpp: (WebCore::HTMLDocument::bgColor): (WebCore::HTMLDocument::fgColor): (WebCore::HTMLDocument::alinkColor): (WebCore::HTMLDocument::linkColor): (WebCore::HTMLDocument::vlinkColor): 2013-12-04 Brian J. Burg Consolidate various frame snapshot capabilities. https://bugs.webkit.org/show_bug.cgi?id=124325 Reviewed by Darin Adler. Various snapshot creation methods had duplicated code and were split between Frame, DragImage, and platform-specific implementationss. This patch puts WebCore snapshot methods into FrameSnapshotting and removes platform implementations where possible. DragImage methods reuse snapshot methods where possible. Inspector will be able to take snapshots without using drag images. No new tests, this is a refactoring. * CMakeLists.txt: * GNUmakefile.list.am: * WebCore.exp.in: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.xcodeproj/project.pbxproj: * bindings/objc/DOM.mm: (-[DOMNode renderedImage]): (-[DOMRange renderedImageForcingBlackText:]): * dom/Clipboard.cpp: (WebCore::Clipboard::createDragImage): * dom/ClipboardMac.mm: (WebCore::Clipboard::createDragImage): * page/DragController.cpp: (WebCore::DragController::startDrag): * page/Frame.cpp: * page/Frame.h: * page/FrameSnapshotting.cpp: Added. (WebCore::ScopedFramePaintingState::ScopedFramePaintingState): (WebCore::ScopedFramePaintingState::~ScopedFramePaintingState): (WebCore::snapshotFrameRect): Move most buffer logic to here. (WebCore::snapshotSelection): Moved from Frame. (WebCore::snapshotNode): Moved from Frame. * page/FrameSnapshotting.h: Added. * page/mac/FrameMac.mm: Removed. * page/mac/FrameSnapshottingMac.h: Removed. * page/mac/FrameSnapshottingMac.mm: Removed. * page/win/FrameWin.cpp: remove duplicate implementation. * page/win/FrameWin.h: Fix an incorrect parameter name. * platform/DragImage.cpp: (WebCore::ScopedNodeDragState::ScopedNodeDragState): (WebCore::ScopedNodeDragState::~ScopedNodeDragState): (WebCore::createDragImageFromSnapshot): Boilerplate buffer conversion. (WebCore::createDragImageForNode): (WebCore::createDragImageForSelection): (WebCore::ScopedFrameSelectionState::ScopedFrameSelectionState): (WebCore::ScopedFrameSelectionState::~ScopedFrameSelectionState): (WebCore::createDragImageForRange): Moved from Frame. (WebCore::createDragImageForImage): Moved from FrameSnapshottingMac. (WebCore::createDragImageForLink): use nullptr. 2013-12-04 Benjamin Poulain Remove spaces on a blank line to have ResourceHandleCFNet.cpp identical to iOS Unreviewed. * platform/network/cf/ResourceHandleCFNet.cpp: (WebCore::ResourceHandle::platformLoadResourceSynchronously): 2013-12-04 Antti Koivisto Move pseudo element construction out from Element https://bugs.webkit.org/show_bug.cgi?id=125257 Reviewed by Anders Carlsson. This is logically part of the style resolve/render tree construction. This will make future refactoring easier. * dom/Element.cpp: * dom/Element.h: * style/StyleResolveTree.cpp: (WebCore::Style::beforeOrAfterPseudoElement): (WebCore::Style::setBeforeOrAfterPseudoElement): (WebCore::Style::clearBeforeOrAfterPseudoElement): (WebCore::Style::needsPseudeElement): (WebCore::Style::attachBeforeOrAfterPseudoElementIfNeeded): (WebCore::Style::attachRenderTree): (WebCore::Style::updateBeforeOrAfterPseudoElement): (WebCore::Style::resolveTree): 2013-12-04 Zoltan Horvath Move TrailingObjects class into its own h/cpp https://bugs.webkit.org/show_bug.cgi?id=124956 Reviewed by David Hyatt. Since I moved space-ignoring inline functions into MidpointState in r160074, I can nicely separate TrailingObjects class from BreakingContextInlineHeader.h. This change improves the readability, and it's part of the RenderBlockLineLayout refactoring campaign, which is tracked under bug #121261. No new tests, no behavior change. * CMakeLists.txt: * GNUmakefile.list.am: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.xcodeproj/project.pbxproj: * rendering/RenderBlock.h: * rendering/RenderBlockFlow.h: * rendering/line/BreakingContextInlineHeaders.h: * rendering/line/TrailingObjects.cpp: Added. (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): * rendering/line/TrailingObjects.h: Added. (WebCore::TrailingObjects::TrailingObjects): (WebCore::TrailingObjects::setTrailingWhitespace): (WebCore::TrailingObjects::clear): (WebCore::TrailingObjects::appendBoxIfNeeded): 2013-12-04 Oliver Hunt Refactor static getter function prototype to include thisValue in addition to the base object https://bugs.webkit.org/show_bug.cgi?id=124461 Reviewed by Geoffrey Garen. Change bindings codegen to produce static getter functions with the correct types. Also update the many custom implementations to the new type. No change in behaviour. * bindings/js/JSCSSStyleDeclarationCustom.cpp: (WebCore::cssPropertyGetterPixelOrPosPrefixCallback): (WebCore::cssPropertyGetterCallback): * bindings/js/JSDOMBinding.cpp: (WebCore::objectToStringFunctionGetter): * bindings/js/JSDOMBinding.h: * bindings/js/JSDOMMimeTypeArrayCustom.cpp: (WebCore::JSDOMMimeTypeArray::nameGetter): * bindings/js/JSDOMPluginArrayCustom.cpp: (WebCore::JSDOMPluginArray::nameGetter): * bindings/js/JSDOMPluginCustom.cpp: (WebCore::JSDOMPlugin::nameGetter): * bindings/js/JSDOMStringMapCustom.cpp: (WebCore::JSDOMStringMap::nameGetter): * bindings/js/JSDOMWindowCustom.cpp: (WebCore::nonCachingStaticFunctionGetter): (WebCore::childFrameGetter): (WebCore::indexGetter): (WebCore::namedItemGetter): * bindings/js/JSHTMLAllCollectionCustom.cpp: (WebCore::JSHTMLAllCollection::nameGetter): * bindings/js/JSHTMLCollectionCustom.cpp: (WebCore::JSHTMLCollection::nameGetter): * bindings/js/JSHTMLDocumentCustom.cpp: (WebCore::JSHTMLDocument::nameGetter): * bindings/js/JSHTMLFormControlsCollectionCustom.cpp: (WebCore::JSHTMLFormControlsCollection::nameGetter): * bindings/js/JSHTMLFormElementCustom.cpp: (WebCore::JSHTMLFormElement::nameGetter): * bindings/js/JSHTMLFrameSetElementCustom.cpp: (WebCore::JSHTMLFrameSetElement::nameGetter): * bindings/js/JSHistoryCustom.cpp: (WebCore::nonCachingStaticBackFunctionGetter): (WebCore::nonCachingStaticForwardFunctionGetter): (WebCore::nonCachingStaticGoFunctionGetter): * bindings/js/JSJavaScriptCallFrameCustom.cpp: (WebCore::JSJavaScriptCallFrame::scopeType): * bindings/js/JSLocationCustom.cpp: (WebCore::nonCachingStaticReplaceFunctionGetter): (WebCore::nonCachingStaticReloadFunctionGetter): (WebCore::nonCachingStaticAssignFunctionGetter): * bindings/js/JSNamedNodeMapCustom.cpp: (WebCore::JSNamedNodeMap::nameGetter): * bindings/js/JSNodeListCustom.cpp: (WebCore::JSNodeList::nameGetter): * bindings/js/JSPluginElementFunctions.cpp: (WebCore::pluginElementPropertyGetter): * bindings/js/JSPluginElementFunctions.h: * bindings/js/JSRTCStatsResponseCustom.cpp: (WebCore::JSRTCStatsResponse::nameGetter): * bindings/js/JSStorageCustom.cpp: (WebCore::JSStorage::nameGetter): * bindings/js/JSStyleSheetListCustom.cpp: (WebCore::JSStyleSheetList::nameGetter): * bindings/scripts/CodeGeneratorJS.pm: (GenerateHeader): (GenerateImplementation): (GenerateParametersCheck): * bridge/runtime_array.cpp: (JSC::RuntimeArray::lengthGetter): (JSC::RuntimeArray::indexGetter): * bridge/runtime_array.h: * bridge/runtime_method.cpp: (JSC::RuntimeMethod::lengthGetter): * bridge/runtime_method.h: * bridge/runtime_object.cpp: (JSC::Bindings::RuntimeObject::fallbackObjectGetter): (JSC::Bindings::RuntimeObject::fieldGetter): (JSC::Bindings::RuntimeObject::methodGetter): * bridge/runtime_object.h: 2013-12-04 Zoltan Horvath [CSS Shapes] Support inset for shape-outside Reviewed by David Hyatt. This patch adds inset support for shape-outside. Parsing has previously landed in r159968. Specification: http://dev.w3.org/csswg/css-shapes/#supported-basic-shapes Tests: fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-left.html fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-bottom-right.html fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-left.html fast/shapes/shape-outside-floats/shape-outside-floats-inset-rounded-top-right.html fast/shapes/shape-outside-floats/shape-outside-floats-inset.html * platform/LengthSize.h: (WebCore::LengthSize::floatSize): Add conversion to FloatSize. * rendering/shapes/Shape.cpp: (WebCore::Shape::createShape): Handle inset case. 2013-12-04 Bear Travis Web Inspector: [CSS Shapes] Support raster shape visualizations https://bugs.webkit.org/show_bug.cgi?id=124080 Reviewed by Joseph Pecoraro. Create an inspector visualization for a shape created from an image. The visualization takes each line of the image, combining where possible. Test added to inspector-protocol/model/highlight-shape-outside.html * rendering/shapes/RasterShape.cpp: (WebCore::RasterShapeIntervals::buildBoundsPath): Create a path representing the RasterShapeIntervals. * rendering/shapes/RasterShape.h: 2013-12-04 Zoltan Horvath [CSS Shapes] Remove explicit numbering from BasicShape::Type and CSSBasicShape::Type enums https://bugs.webkit.org/show_bug.cgi?id=125163 Reviewed by Rob Buis. I don't see any reason to have explicit numbering for the Type enum in our [CSS]BasicShape classes. I removed numbering, which will decrease for instance the merge conflicts on Type changes. No new tests, no behavior change. * css/CSSBasicShapes.h: * rendering/style/BasicShapes.h: 2013-12-04 Myles C. Maxfield Allow ImageBuffer to use an IOSurface that is larger than necessary https://bugs.webkit.org/show_bug.cgi?id=124626 Reviewed by Simon Fraser. Because creating ImageBuffer's backing store can be so expensive, it would be beneficial to have a pool of pre-created backing stores available. However, this means that ImageBuffer might have to use a backing store that is larger than the exact dimensions that it needs. This patch adds a field, m_backingStoreSize, to CG's ImageBufferData class, and uses this new field when performing ImageBuffer operations to allow for larger-than-necessary backing stores. Content is always drawn in the top left corner of the backing store. No new tests are necessary because there is no behavior change. * platform/graphics/ImageBuffer.h: (WebCore::ImageBuffer::baseTransform): The base transform has to put content at the top left corner instead of bottom left * platform/graphics/cg/ImageBufferCG.cpp: (WebCore::createCroppedImageIfNecessary): Convenience function to figure out the dimensions of the backing texture in user space (WebCore::ImageBuffer::ImageBuffer): Set up new m_backingStoreSize member (WebCore::maybeCropToBounds): Some ImageBuffer API functions require outputting an image with logical size. This function performs the cropping (WebCore::ImageBuffer::copyImage): Updated for larger-than-necessary backing stores (WebCore::ImageBuffer::copyNativeImage): Ditto (WebCore::ImageBuffer::draw): Ditto (WebCore::ImageBuffer::clip): Ditto (WebCore::ImageBuffer::putByteArray): Ditto (WebCore::ImageBuffer::toDataURL): Ditto * platform/graphics/cg/ImageBufferDataCG.cpp: (WebCore::ImageBufferData::getData): Ditto (WebCore::ImageBufferData::putData): Ditto * platform/graphics/cg/ImageBufferDataCG.h: New m_backingStoreSize field 2013-12-03 Dean Jackson [WebGL] Support for texImage2D of type HALF_FLOAT_OES https://bugs.webkit.org/show_bug.cgi?id=110936 Reviewed by Brent Fulgham. Add support for the HALF_FLOAT_OES texture format from texImage2D and texSubImage2D. A lot of this patch comes from the original patch on the bug by Nayan Kumar, and the Blink commit: https://codereview.chromium.org/13842017 Tests: fast/canvas/webgl/oes-texture-half-float-with-canvas.html fast/canvas/webgl/oes-texture-half-float-with-image.html fast/canvas/webgl/oes-texture-half-float-with-video.html * html/canvas/OESTextureHalfFloat.idl: New HALF_FLOAT_OES constant value. * html/canvas/WebGLRenderingContext.cpp: (WebCore::WebGLRenderingContext::validateTexFunc): Remove the code that would bail if half-float values were used. * platform/graphics/GraphicsContext3D.cpp: - Return appropriate DataFormats for half floating point types. - Copy the float -> half-float code from Blink - New pack functions for half floats * platform/graphics/GraphicsContext3D.h: New format types. * platform/graphics/opengl/GraphicsContext3DOpenGLCommon.cpp: (WebCore::GraphicsContext3D::texSubImage2D): Use GL_HALF_FLOAT_ARB if we're passed a HALF_FLOAT_OES. 2013-12-04 Daniel Bates Fix the Apple Windows build after (https://bugs.webkit.org/show_bug.cgi?id=125193) * rendering/RenderThemeWin.cpp: (WebCore::RenderThemeWin::paintMenuList): Substitute paintInfo for i. 2013-12-04 Daniel Bates Rename RenderTheme::paintMenuListButton() https://bugs.webkit.org/show_bug.cgi?id=125193 Reviewed by Simon Fraser. Towards upstreaming the iOS concept of render theme decorations we should rename RenderTheme::paintMenuListButton() to RenderTheme::paintMenuListButtonDecorations() to better describe its purpose. Also, fix code style issues. * platform/blackberry/RenderThemeBlackBerry.cpp: (WebCore::RenderThemeBlackBerry::paintMenuListButtonDecorations): * platform/blackberry/RenderThemeBlackBerry.h: * platform/efl/RenderThemeEfl.cpp: (WebCore::RenderThemeEfl::paintMenuListButtonDecorations): * platform/efl/RenderThemeEfl.h: * platform/gtk/RenderThemeGtk.cpp: (WebCore::RenderThemeGtk::paintMenuListButtonDecorations): * platform/gtk/RenderThemeGtk.h: * platform/nix/RenderThemeNix.h: * rendering/RenderTheme.cpp: (WebCore::RenderTheme::paintDecorations): Rename argument o, r to renderer and rect, respectively. * rendering/RenderTheme.h: (WebCore::RenderTheme::paintMenuListButtonDecorations): * rendering/RenderThemeMac.h: * rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::paintMenuListButtonDecorations): Rename argument o, r to renderer and rect, respectively; also remove extraneous white space and substitute 1 for 1.0f. * rendering/RenderThemeSafari.cpp: (WebCore::RenderThemeSafari::paintMenuListButtonDecorations): Ditto. * rendering/RenderThemeSafari.h: * rendering/RenderThemeWin.cpp: (WebCore::RenderThemeWin::paintMenuList): Rename argument o, i, r to renderer, paintInfo, and rect, respectively. (WebCore::RenderThemeWin::paintMenuListButtonDecorations): Ditto. * rendering/RenderThemeWin.h: * rendering/RenderThemeWinCE.cpp: (WebCore::RenderThemeWinCE::paintMenuList): Ditto. (WebCore::RenderThemeWinCE::paintMenuListButtonDecorations): Ditto. * rendering/RenderThemeWinCE.h: 2013-12-04 Andy Estes [iOS] Build projects with $(ARCHS_STANDARD_32_64_BIT) https://bugs.webkit.org/show_bug.cgi?id=125236 Reviewed by Sam Weinig. $(ARCHS_STANDARD_32_64_BIT) is what we want for both device and simulator builds. * Configurations/DebugRelease.xcconfig: 2013-12-04 Joseph Pecoraro Unreviewed Windows build fix attempt after r160099. * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.vcxproj/copyForwardingHeaders.cmd: 2013-12-03 Joseph Pecoraro Web Inspector: Push Remote Inspector debugging connection management into JavaScriptCore https://bugs.webkit.org/show_bug.cgi?id=124613 Reviewed by Timothy Hatcher. Make a WebCore::Page a "Web" Remote Debuggable. * bindings/js/JSDOMGlobalObject.cpp: Disable JavaScript context inspection on JSGlobalObjects inside WebCore::Page's. * page/Page.cpp: (WebCore::Page::Page): (WebCore::Page::remoteInspectionAllowed): (WebCore::Page::setRemoteInspectionAllowed): (WebCore::Page::remoteInspectorInformationDidChange): * page/Page.h: * page/PageDebuggable.h: * page/PageDebuggable.cpp: Added. (WebCore::PageDebuggable::PageDebuggable): (WebCore::PageDebuggable::name): (WebCore::PageDebuggable::url): (WebCore::PageDebuggable::hasLocalDebugger): (WebCore::PageDebuggable::connect): (WebCore::PageDebuggable::disconnect): (WebCore::PageDebuggable::dispatchMessageFromRemoteFrontend): (WebCore::PageDebuggable::setIndicating): Make a page a "Web" debuggable. * GNUmakefile.list.am: * WebCore.exp.in: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: * WebCore.xcodeproj/project.pbxproj: Misc. * inspector/InspectorClient.h: (WebCore::InspectorClient::indicate): (WebCore::InspectorClient::hideIndicate): Forward indicate methods to WebKit clients. * loader/FrameLoader.cpp: (WebCore::FrameLoader::didChangeTitle): (WebCore::FrameLoader::dispatchDidCommitLoad): Push updates when remote debuggable information like the Page's URL or title change. * ForwardingHeaders/inspector/InspectorFrontendChannel.h: * inspector/InspectorForwarding.h: Re-export Inspector::InspectorFrontendChannel as WebCore::InspectorFrontendChannel to avoid needlessly updating code all over the place. * inspector/CodeGeneratorInspectorStrings.py: * inspector/InspectorWorkerAgent.cpp: * inspector/WorkerInspectorController.cpp: * testing/Internals.cpp: Update include names. * page/ContextMenuController.cpp: (WebCore::ContextMenuController::populate): Make the "Inspect Element" context menu work correctly when there is a remote inspector instead of a local inspector. 2013-12-03 Joseph Pecoraro Web Inspector: Add missing folders and files to Xcode project https://bugs.webkit.org/show_bug.cgi?id=124802 Reviewed by Timothy Hatcher. * WebCore.xcodeproj/project.pbxproj: 2013-12-04 José Dapena Paz [texmap] Borders on rotating images are hidden/wrongly rendered with edge distance antialiasing https://bugs.webkit.org/show_bug.cgi?id=124653 Reviewed by Noam Rosenthal. Texture mapper edge distance antialiasing texture sampling was causing borders to be shaded (and made them almost disappear in some cases). This was because calculation of sampling happened on vertex shader, so the border of the texture would go to the border of the inflation area. What algorithm should do is sampling the border pixel for all the inflation area (it is the closest pixel to all the samples in inflation area), and then use the standard sampling for the other parts of the texture. No new test because this is already covered by test transforms/3d/point-mapping/3d-point-mapping.html * platform/graphics/texmap/TextureMapperShaderProgram.cpp: fix edge distance antialiasing texture sampling. 2013-12-04 László Langó Typo fix after r160074 to fix debug builds. Reviewed by Csaba Osztrogonác. * platform/text/BidiResolver.h: (WebCore::MidpointState::stopIgnoringSpaces): 2013-12-04 Zoltan Horvath Move space-ignoring inline functions into MidpointState Reviewed by David Hyatt. Since: - The following inline functions were used only with a mandatory LineMidpointState argument: startIgnoringSpaces, stopIgnoringSpaces, ensureLineBoxInsideIgnoredSpaces, deprecatedAddMidpoint. - TrailingObjects class uses these functions. Since they're inline in BreakingContextInlineHeaders.h, it's hard to separate TrailingObjects into it's own file. (blocks bug #124956) I made these functions as a member of LineMidpointState, and I also updated the call sites. No new tests, no behavior change. * platform/text/BidiResolver.h: (WebCore::MidpointState::startIgnoringSpaces): (WebCore::MidpointState::stopIgnoringSpaces): (WebCore::MidpointState::ensureLineBoxInsideIgnoredSpaces): (WebCore::MidpointState::deprecatedAddMidpoint): * rendering/RenderBlock.h: * rendering/line/BreakingContextInlineHeaders.h: (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): (WebCore::BreakingContext::handleBR): (WebCore::BreakingContext::handleOutOfFlowPositioned): (WebCore::shouldSkipWhitespaceAfterStartObject): (WebCore::BreakingContext::handleEmptyInline): (WebCore::BreakingContext::handleReplaced): (WebCore::ensureCharacterGetsLineBox): (WebCore::BreakingContext::handleText): 2013-12-03 Zoltan Horvath Remove BreakingContext's friendship from RenderBlockFlow Reviewed by David Hyatt. BreakingContext uses only 2 functions from RenderBlockFlow: insertFloatingObject/positionNewFloatOnLine. I added helper functions to LineBreaker, what is already a friend of RenderBlockFlow, so BreakingContext doesn't need to be anymore. No new tests, no behavior change. * rendering/RenderBlockFlow.h: * rendering/line/BreakingContextInlineHeaders.h: (WebCore::BreakingContext::handleFloat): * rendering/line/LineBreaker.h: (WebCore::LineBreaker::insertFloatingObject): (WebCore::LineBreaker::positionNewFloatOnLine): 2013-12-03 Ryosuke Niwa bgColor, setBgColor, alinkColor, setAlinkColor, and etc... on HTMLBodyElement are useless https://bugs.webkit.org/show_bug.cgi?id=125208 Reviewed by Antti Koivisto. Merge https://chromium.googlesource.com/chromium/blink/+/49b1eeabbbf573d5271288c66d2b566cf33a09cf These member functions of HTMLBodyElement were only used by corresponding functions in HTMLDocument since they had the Reflect option specified in HTMLBodyElement.idl. Removed the functions and directly called getAttribute and setAttribute in relevant functions in HTMLDocument. The optimization to avoid assignment is no longer needed here since we've added that optimization to setAttributeInternal a while ago. * html/HTMLBodyElement.cpp: * html/HTMLBodyElement.h: * html/HTMLDocument.cpp: (WebCore::HTMLDocument::bgColor): (WebCore::HTMLDocument::setBgColor): (WebCore::HTMLDocument::fgColor): (WebCore::HTMLDocument::setFgColor): (WebCore::HTMLDocument::alinkColor): (WebCore::HTMLDocument::setAlinkColor): (WebCore::HTMLDocument::linkColor): (WebCore::HTMLDocument::setLinkColor): (WebCore::HTMLDocument::vlinkColor): (WebCore::HTMLDocument::setVlinkColor): * html/HTMLDocument.h: 2013-12-03 Andreas Kling Add a CSSProperty::isDirectionAwareProperty() helper. Move the block of case labels for checking whether a CSS property ID is a directional property into a separate function. Also removed an outdated comment about CSS variables. Reviewed by Antti Koivisto. 2013-12-03 Ryosuke Niwa Revert the inadvertently committed change. * html/HTMLElement.idl: 2013-12-03 Ryosuke Niwa Remove nodeIsDetachedFromDocument and visualWordMovementEnabled in FrameSelection https://bugs.webkit.org/show_bug.cgi?id=125210 Reviewed by Antti Koivisto. Inspired by https://chromium.googlesource.com/chromium/blink/+/92409870f0ff8fafe31217830db0838a9e1ffb98 Removed some unused code. * editing/FrameSelection.cpp: (WebCore::FrameSelection::textWasReplaced): * editing/FrameSelection.h: * page/Settings.in: 2013-12-03 Ryosuke Niwa Potential crash in RenderView::selectionBounds and RenderView::repaintSelection https://bugs.webkit.org/show_bug.cgi?id=125207 Reviewed by Simon Fraser. Merge https://chromium.googlesource.com/chromium/blink/+/f9e6e288a5aa959f05c374806121aaf0fc52d440 Update style in FrameSelection instead of RenderView's member functions. These are the last two member functions of RenderView that updates the style. * editing/FrameSelection.cpp: (WebCore::FrameSelection::focusedOrActiveStateChanged): (WebCore::FrameSelection::bounds): * rendering/RenderView.cpp: (WebCore::RenderView::selectionBounds): (WebCore::RenderView::repaintSelection): 2013-12-03 Mark Rowe Improve the formatting in the generated Objective-C headers. Add a space between @property and any parenthesized attributes. Prefer strong over retain when specifying memory management semantics. Reviewed by Darin Adler. * bindings/objc/PublicDOMInterfaces.h: * bindings/scripts/CodeGeneratorObjC.pm: (GetPropertyAttributes): Generate strong instead of retain. Include a space before the parenthesis. * bindings/scripts/test/ObjC/DOMTestActiveDOMObject.h: * bindings/scripts/test/ObjC/DOMTestEventConstructor.h: * bindings/scripts/test/ObjC/DOMTestException.h: * bindings/scripts/test/ObjC/DOMTestInterface.h: * bindings/scripts/test/ObjC/DOMTestObj.h: * bindings/scripts/test/ObjC/DOMTestSerializedScriptValueInterface.h: * bindings/scripts/test/ObjC/DOMTestTypedefs.h: * bindings/scripts/test/ObjC/DOMattribute.h: 2013-12-03 Alexey Proskuryakov Update WebCrypto JWK mapping to newer proposal https://bugs.webkit.org/show_bug.cgi?id=124218 Reviewed by Anders Carlsson. Tests: crypto/subtle/jwk-export-use-values.html crypto/subtle/jwk-import-use-values.html 1. "extractable" renamed to "ext" in JWK. 2. New values for "use" mapping, which can now be combined into comma separated lists, and cover all possible WebCrypto usages. * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::JSCryptoKeySerializationJWK::reconcileUsages): (WebCore::JSCryptoKeySerializationJWK::reconcileExtractable): (WebCore::JSCryptoKeySerializationJWK::addJWKAlgorithmToJSON): (WebCore::processUseValue): (WebCore::JSCryptoKeySerializationJWK::addJWKUseToJSON): (WebCore::JSCryptoKeySerializationJWK::serialize): 2013-12-03 Simon Fraser Remove some iOS-related documentScale code https://bugs.webkit.org/show_bug.cgi?id=125194 Reviewed by Enrica Casucci. Remove exports of nonexistent documentScale-related functions on Frame. * WebCore.exp.in: 2013-12-03 Eric Carlson Fix regression caused by r158599 https://bugs.webkit.org/show_bug.cgi?id=125188 Reviewed by Jer Noble. * html/HTMLMediaElement.cpp: (HTMLMediaElement::clearMediaPlayer): Do not clear m_player when PLUGIN_PROXY_FOR_VIDEO is enabled. 2013-12-03 Thiago de Barros Lacerda Nix Upstream: Updating WebCore files https://bugs.webkit.org/show_bug.cgi?id=124981 Reviewed by Benjamin Poulain. Just to sync our github repo files and the trunk, as part of the upstream process No new tests needed. * PlatformNix.cmake: * css/mediaControlsNix.css: (audio): (video::-webkit-media-controls): (audio::-webkit-media-controls-enclosure, video::-webkit-media-controls-enclosure): (video::-webkit-media-controls-enclosure): (audio::-webkit-media-controls-panel, video::-webkit-media-controls-panel): (video:-webkit-full-page-media): (audio:-webkit-full-page-media, video:-webkit-full-page-media): (audio::-webkit-media-controls-mute-button, video::-webkit-media-controls-mute-button): (audio::-webkit-media-controls-overlay-play-button, video::-webkit-media-controls-overlay-play-button): (audio::-webkit-media-controls-play-button, video::-webkit-media-controls-play-button): (audio::-webkit-media-controls-timeline-container, video::-webkit-media-controls-timeline-container): (audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display): (audio::-webkit-media-controls-timeline, video::-webkit-media-controls-timeline): (audio::-webkit-media-controls-volume-slider, video::-webkit-media-controls-volume-slider): (input[type="range"]::-webkit-media-slider-container): (input[type="range"]::-webkit-media-slider-container > div): (input[type="range"]::-webkit-media-slider-thumb): (audio::-webkit-media-controls-seek-back-button, video::-webkit-media-controls-seek-back-button): (audio::-webkit-media-controls-seek-forward-button, video::-webkit-media-controls-seek-forward-button): (audio::-webkit-media-controls-fullscreen-button, video::-webkit-media-controls-fullscreen-button): (audio::-webkit-media-controls-toggle-closed-captions-button, video::-webkit-media-controls-toggle-closed-captions-button): (audio::-webkit-media-controls-fullscreen-volume-slider, video::-webkit-media-controls-fullscreen-volume-slider): (audio::-webkit-media-controls-fullscreen-volume-min-button, video::-webkit-media-controls-fullscreen-volume-min-button): (audio::-webkit-media-controls-fullscreen-volume-max-button, video::-webkit-media-controls-fullscreen-volume-max-button): (video::-webkit-media-text-track-container): (video::cue): (video::-webkit-media-text-track-region): (video::-webkit-media-text-track-region-container): (video::-webkit-media-text-track-region-container.scrolling): (video::-webkit-media-text-track-display): (video::cue(:future)): (video::-webkit-media-text-track-container b): (video::-webkit-media-text-track-container u): (video::-webkit-media-text-track-container i): * editing/Editor.cpp: (WebCore::Editor::cut): (WebCore::Editor::copy): (WebCore::Editor::copyImage): * editing/Editor.h: * html/HTMLCanvasElement.h: * platform/Cursor.h: * platform/audio/FFTFrame.h: * platform/audio/nix/AudioBusNix.cpp: (WebCore::AudioBus::loadPlatformResource): * platform/graphics/GLContext.h: * platform/nix/CursorNix.cpp: (WebCore::Cursor::ensurePlatformCursor): * platform/nix/GamepadsNix.cpp: (WebCore::sampleGamepads): * platform/nix/RenderThemeNix.cpp: (WebCore::toIntSize): (WebCore::toNixRect): (WebCore::RenderThemeNix::platformActiveSelectionBackgroundColor): (WebCore::RenderThemeNix::platformInactiveSelectionBackgroundColor): (WebCore::RenderThemeNix::platformActiveSelectionForegroundColor): (WebCore::RenderThemeNix::platformInactiveSelectionForegroundColor): (WebCore::RenderThemeNix::platformActiveListBoxSelectionBackgroundColor): (WebCore::RenderThemeNix::platformInactiveListBoxSelectionBackgroundColor): (WebCore::RenderThemeNix::platformActiveListBoxSelectionForegroundColor): (WebCore::RenderThemeNix::platformInactiveListBoxSelectionForegroundColor): (WebCore::RenderThemeNix::platformActiveTextSearchHighlightColor): (WebCore::RenderThemeNix::platformInactiveTextSearchHighlightColor): (WebCore::RenderThemeNix::platformFocusRingColor): (WebCore::RenderThemeNix::platformTapHighlightColor): (WebCore::RenderThemeNix::paintButton): (WebCore::RenderThemeNix::paintTextField): (WebCore::RenderThemeNix::paintCheckbox): (WebCore::RenderThemeNix::setCheckboxSize): (WebCore::RenderThemeNix::paintRadio): (WebCore::RenderThemeNix::setRadioSize): (WebCore::RenderThemeNix::paintMenuList): (WebCore::RenderThemeNix::paintProgressBar): (WebCore::RenderThemeNix::paintSliderTrack): (WebCore::RenderThemeNix::paintSliderThumb): (WebCore::RenderThemeNix::paintInnerSpinButton): (WebCore::RenderThemeNix::paintMeter): (WebCore::RenderThemeNix::extraMediaControlsStyleSheet): (WebCore::RenderThemeNix::paintMediaPlayButton): (WebCore::RenderThemeNix::paintMediaMuteButton): (WebCore::RenderThemeNix::paintMediaSeekBackButton): (WebCore::RenderThemeNix::paintMediaSeekForwardButton): (WebCore::RenderThemeNix::paintMediaSliderTrack): (WebCore::RenderThemeNix::paintMediaVolumeSliderContainer): (WebCore::RenderThemeNix::paintMediaVolumeSliderTrack): (WebCore::RenderThemeNix::paintMediaRewindButton): * platform/nix/RenderThemeNix.h: * rendering/SimpleLineLayout.cpp: (WebCore::SimpleLineLayout::canUseFor): 2013-12-03 Ralph Thomas Typo: FixedPositionConstaint -> FixedPositionConstraint https://bugs.webkit.org/show_bug.cgi?id=125171 Reviewed by Simon Fraser. No new tests, no change in behavior. * page/scrolling/ScrollingConstraints.h: * page/scrolling/coordinatedgraphics/ScrollingCoordinatorCoordinatedGraphics.cpp: (WebCore::ScrollingCoordinatorCoordinatedGraphics::updateViewportConstrainedNode): * page/scrolling/mac/ScrollingCoordinatorMac.mm: (WebCore::ScrollingCoordinatorMac::updateViewportConstrainedNode): 2013-12-03 Samuel White AXPress event coordinates are always sent as (0, 0) https://bugs.webkit.org/show_bug.cgi?id=76677 Reviewed by Simon Fraser. Set the coordinates of a simulated press equal to the center of the target element when the simulated press does not have a related mouse event. Test: accessibility/press-targets-center-point.html * dom/Element.cpp: (WebCore::Element::clientRect): (WebCore::Element::screenRect): * dom/Element.h: * dom/EventDispatcher.cpp: (WebCore::EventDispatcher::dispatchSimulatedClick): * dom/MouseEvent.cpp: (WebCore::SimulatedMouseEvent::create): (WebCore::SimulatedMouseEvent::SimulatedMouseEvent): * dom/MouseEvent.h: 2013-12-03 Dean Jackson [WebGL] Implement OES texture float linear https://bugs.webkit.org/show_bug.cgi?id=124871 Reviewed by Brent Fulgham. Implement the OES_texture_float_linear extension. Generally we'd also enable OES_texture_half_float_linear at the same time, but that's blocked on webkit.org/b/110936. Test: fast/canvas/webgl/oes-texture-float-linear.html * CMakeLists.txt: Add new files. * DerivedSources.cpp: Ditto. * DerivedSources.make: Generate new file from IDL. * GNUmakefile.list.am: Add new files. * WebCore.vcxproj/WebCore.vcxproj: Ditto. * WebCore.vcxproj/WebCore.vcxproj.filters: Ditto. * WebCore.xcodeproj/project.pbxproj: New files for OESTextureFloatLinear. * bindings/js/JSWebGLRenderingContextCustom.cpp: (WebCore::toJS): Map the new name into the appropriate type. * html/canvas/OESTextureFloatLinear.cpp: Added. This is a very simple class that's mostly empty. (WebCore::OESTextureFloatLinear::OESTextureFloatLinear): (WebCore::OESTextureFloatLinear::~OESTextureFloatLinear): (WebCore::OESTextureFloatLinear::getName): (WebCore::OESTextureFloatLinear::create): * html/canvas/OESTextureFloatLinear.h: Added. * html/canvas/OESTextureFloatLinear.idl: Added. * html/canvas/WebGLExtension.h: Declare the new name in the enum of extensions. * html/canvas/WebGLRenderingContext.cpp: (WebCore::WebGLRenderingContext::drawArrays): Call new name. (WebCore::WebGLRenderingContext::drawElements): Call new name. (WebCore::WebGLRenderingContext::getExtension): Create the new extension if asked. (WebCore::WebGLRenderingContext::checkTextureCompleteness): Renamed from handleNPOTTextures. Now checks for the type of the texture too. * html/canvas/WebGLRenderingContext.h: Member variable for new extension. * html/canvas/WebGLTexture.cpp: (WebCore::WebGLTexture::WebGLTexture): (WebCore::WebGLTexture::needToUseBlackTexture): Takes an extra parameter which indicates if it has an extension enabled. (WebCore::WebGLTexture::update): Note it is a float type when updating. * html/canvas/WebGLTexture.h: New flag to indicate float type. * platform/graphics/Extensions3D.h: New flag type. * platform/graphics/opengl/Extensions3DOpenGL.cpp: (WebCore::Extensions3DOpenGL::supportsExtension): Add a comment about the extension. 2013-12-03 Alexey Proskuryakov Support exporting private WebCrypto RSA keys https://bugs.webkit.org/show_bug.cgi?id=124483 Reviewed by Anders Carlsson. Test: crypto/subtle/rsa-export-private-key.html It might be better to have our own bignum implementation in WTF, but we currently don't, and the need for this computation is Common Crypto specific anyway. * crypto/CommonCryptoUtilities.h: * crypto/CommonCryptoUtilities.cpp: (WebCore::CCBigNum::CCBigNum): (WebCore::CCBigNum::~CCBigNum): (WebCore::CCBigNum::operator=): (WebCore::CCBigNum::data): (WebCore::CCBigNum::operator-): (WebCore::CCBigNum::operator%): (WebCore::CCBigNum::inverse): Added a minimal wrapper around CommonCrypto BigNum. * crypto/mac/CryptoKeyRSAMac.cpp: (WebCore::getPrivateKeyComponents): Compute missing parts using CCBigNum. (WebCore::CryptoKeyRSA::exportData): Implemented private key case. 2013-12-03 Ryosuke Niwa XML fragment parsing algorithm doesn't use the context element's default namespace URI https://bugs.webkit.org/show_bug.cgi?id=125132 Reviewed by Darin Adler. Always use the context element's namespace as the default namespace URI when one is not specified by xmlns. The new behavior matches that of Internet Explorer and the specified behavior in HTML5: http://www.w3.org/TR/2013/CR-html5-20130806/the-xhtml-syntax.html#parsing-xhtml-fragments "The default namespace is the namespace for which the DOM isDefaultNamespace() method on the element would return true." Test: fast/parser/fragment-parsing-in-document-without-xmlns.html * xml/parser/XMLDocumentParserLibxml2.cpp: (WebCore::XMLDocumentParser::XMLDocumentParser): 2013-12-03 Nick Diego Yamane Remove some CSS Variables leftovers https://bugs.webkit.org/show_bug.cgi?id=125167 Reviewed by Darin Adler. No new tests needed. Only removing leftover code. * css/CSSBasicShapes.cpp: * css/CSSBasicShapes.h: 2013-12-03 Myles C. Maxfield Checking second-to-last bit in address is a typo https://bugs.webkit.org/show_bug.cgi?id=125162 Reviewed by Darin Adler. After talking with the original author of this line, is was a typo to make sure that the second-to-last bit in an address is 0. Instead, we want to make sure that the address is aligned to a 4-byte boundary No behavior change, so no test is necessary * platform/graphics/cg/ImageBufferCG.cpp: (WebCore::ImageBuffer::ImageBuffer): 2013-12-03 Radu Stavila The overflow border of a relatively positioned element inside a region is not painted https://bugs.webkit.org/show_bug.cgi?id=124919 Relative positioned elements have self-painting layers that don't propagate the visual overflow so the layer's position should be used when determining the clipping rectangle for box decorations. Reviewed by Mihnea Ovidenie. Test: fast/regions/relative-borders-overflow.html * rendering/RenderFlowThread.cpp: (WebCore::RenderFlowThread::decorationsClipRectForBoxInRegion): 2013-12-03 Seokju Kwon Web Inspector: Get rid of 'hasFrontend()' in InspectorController and WorkerInspectorController https://bugs.webkit.org/show_bug.cgi?id=125135 Reviewed by Darin Adler. Remove 'hasFrontend()' from InspectorController and WorkerInspectorController as it's never called. No new tests, no behavior changes. * inspector/InspectorController.h: * inspector/WorkerInspectorController.h: 2013-12-03 Seokju Kwon Web Inspector: webViewResized() is not used anywhere in WebInspectorUI https://bugs.webkit.org/show_bug.cgi?id=125137 Reviewed by Darin Adler. Remove leftover code. No new tests, no behavior changes. * inspector/InspectorController.cpp: * inspector/InspectorController.h: * inspector/InspectorOverlay.cpp: * inspector/InspectorOverlay.h: * inspector/InspectorPageAgent.cpp: * inspector/InspectorPageAgent.h: 2013-12-03 László Langó ASSERTION FAILED: !value || (value->isPrimitiveValue()) in WebCore::StyleProperties::getLayeredShorthandValue. https://bugs.webkit.org/show_bug.cgi?id=125146 Reviewed by Darin Adler. Do not presume that |yValue| is primitive if |value| is implicit in StylePropertySerializer. An implicit y-value can become explicit if specified as a separate longhand. At the same time, its new value can be non-primitive. Backported from Blink: http://src.chromium.org/viewvc/blink?view=rev&rev=153678 Test: fast/css/webkit-mask-crash-implicit.html * css/StyleProperties.cpp: (WebCore::StyleProperties::getLayeredShorthandValue): 2013-12-03 Rob Buis Fix build break after r160007. * rendering/style/BasicShapes.cpp: (WebCore::BasicShape::canBlend): 2013-12-03 Rob Buis [css shapes] layout for new ellipse syntax https://bugs.webkit.org/show_bug.cgi?id=124621 Reviewed by Dirk Schulze. Implement support for doing layout with the new ellipse shape syntax, including basic animation support. Test: fast/shapes/shape-outside-floats/shape-outside-floats-ellipse-000.html * rendering/shapes/Shape.cpp: (WebCore::Shape::createShape): Convert new ellipse to a layout shape. * rendering/style/BasicShapes.cpp: (WebCore::BasicShape::canBlend): Ignore ellipses with values that cannot be interpolated. (WebCore::BasicShapeEllipse::floatValueForRadiusInBox): Helper function to calculate either radiusX or radiusY, shared by clip-path and shape code paths. (WebCore::BasicShapeEllipse::path): * rendering/style/BasicShapes.h: 2013-12-03 Frédéric Wang Add an MathMLSelectElement class to implement and . Reviewed by Chris Fleizach. Tests: mathml/presentation/maction-dynamic.html mathml/presentation/maction.html mathml/presentation/semantics.html This adds a new MathMLSelectElement class to prepare the implementation of the and elements, for which only one "selected" child is visible. We now simply display the first child of the element instead of hiding the annotations and this allows to handle the use case of SVG-in-MathML as generated by Instiki when bug 124128 is fixed ; Gecko's selection algorithm will be implemented later (bug 100626). We now also rely on the @actiontype and @selection attributes to select the visible child ; It remains to deal with the user interaction (bug 85734). * CMakeLists.txt: add the new files. * GNUmakefile.list.am: ditto * Target.pri: ditto * WebCore.vcxproj/WebCore.vcxproj: ditto * WebCore.vcxproj/WebCore.vcxproj.filters: ditto * WebCore.xcodeproj/project.pbxproj: ditto * css/mathml.css: remove the CSS rule for annotation/annotation-xml. * mathml/MathMLAllInOne.cpp: add the new cpp file. * mathml/MathMLSelectElement.cpp: Added. (WebCore::MathMLSelectElement::MathMLSelectElement): (WebCore::MathMLSelectElement::create): (WebCore::MathMLSelectElement::createRenderer): (WebCore::MathMLSelectElement::childShouldCreateRenderer): (WebCore::MathMLSelectElement::finishParsingChildren): (WebCore::MathMLSelectElement::childrenChanged): (WebCore::MathMLSelectElement::attributeChanged): (WebCore::MathMLSelectElement::updateSelectedChild): basic implementation for maction, semantics, maction@actiontype and maction@selection. * mathml/MathMLSelectElement.h: Added. * mathml/mathattrs.in: add actiontype and selection attributes. * mathml/mathtags.in: set element classes for maction, semantics, annotation and annotation-xml. 2013-12-03 Thiago de Barros Lacerda Nix Upstream: Adding missing nix new files to WebCore https://bugs.webkit.org/show_bug.cgi?id=124987 Reviewed by Benjamin Poulain. No new tests needed. * PlatformNix.cmake: * platform/nix/ErrorsNix.cpp: Added. * platform/nix/ErrorsNix.h: Added. * platform/nix/FileSystemNix.cpp: Added. * platform/nix/MIMETypeRegistryNix.cpp: Added. * platform/nix/SharedTimerNix.cpp: Added. * platform/nix/TemporaryLinkStubs.cpp: Added. 2013-12-03 Tamas Gergely Correct broken build on efl port with --no-netscape-plugin-api configuration. https://bugs.webkit.org/show_bug.cgi?id=123997 Reviewed by Zoltan Herczeg. Build failed on efl port with --no-netscape-plugin-api configuration as ld did not found some methods. The configuration uses a minimal empty implementation of the class, which is now extended with empty method implementations. * plugins/PluginPackageNone.cpp: (WebCore::PluginPackage::createPackage): Returns NULL pointer. (WebCore::PluginPackage::hash): Returns 0. (WebCore::PluginPackage::equal): Returns true (equals). (WebCore::PluginPackage::compare): Returns 0 (equals). (WebCore::PluginPackage::~PluginPackage): Do nothing. 2013-12-02 Andreas Kling Avoid setting style twice for generated image content. Take care of a FIXME I added in r158097 and avoid redundant work in ImageContentData::createRenderer(). I changed the inheritance helper RenderImage::setPseudoStyle() into a new createStyleInheritingFromPseudoStyle() function instead so it can be used from both PseudoElement and ImageContentData. Reviewed by Antti Koivisto. 2013-12-02 Samuel White AX: Add AXUIElementCountForSearchPredicate parameterized attribute. https://bugs.webkit.org/show_bug.cgi?id=124561 Reviewed by Chris Fleizach. Added ability to fetch the number of elements that match a specific criteria. This will enable VoiceOver to interface with WebKit much more dynamically. We can now get an idea of how many interesting elements exist on a page, and then fetch them in chunks as needed. Test: platform/mac/accessibility/search-predicate-element-count.html * accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::isAccessibilityTextSearchMatch): * accessibility/AccessibilityObject.h: (WebCore::AccessibilitySearchCriteria::AccessibilitySearchCriteria): * accessibility/mac/WebAccessibilityObjectWrapperMac.mm: (accessibilitySearchCriteriaForSearchPredicateParameterizedAttribute): (-[WebAccessibilityObjectWrapper accessibilityParameterizedAttributeNames]): (-[WebAccessibilityObjectWrapper accessibilityAttributeValue:forParameter:]): 2013-12-02 Bem Jones-Bey [css shapes] Layout support for new circle shape syntax https://bugs.webkit.org/show_bug.cgi?id=124619 Reviewed by Dirk Schulze. Implement support for doing layout with the new circle shape syntax, inclduing basic animation support. Tests: fast/shapes/shape-outside-floats/shape-outside-floats-circle-000.html fast/shapes/shape-outside-floats/shape-outside-floats-circle-001.html fast/shapes/shape-outside-floats/shape-outside-floats-circle-002.html fast/shapes/shape-outside-floats/shape-outside-floats-circle-003.html fast/shapes/shape-outside-floats/shape-outside-floats-circle-004.html fast/shapes/shape-outside-floats/shape-outside-floats-circle-005.html * css/BasicShapeFunctions.cpp: (WebCore::floatValueForCenterCoordinate): Used by both the CSS Shapes layout code and the clip path code. * css/BasicShapeFunctions.h: * css/CSSBasicShapes.cpp: (WebCore::buildCircleString): Update to use appendLiteral, and remove call to reserveCapacity - if we find that it's actually slow when doing performance tests, we can hopefully do something smarter and less ugly than that. * css/CSSParser.cpp: (WebCore::CSSParser::parseShapeRadius): Fix a logic error that caused the radius keywords not to work properly. * rendering/shapes/Shape.cpp: (WebCore::Shape::createShape): Convert new circle to a layout shape. * rendering/style/BasicShapes.cpp: (WebCore::BasicShape::canBlend): Ignore circles with values that cannot be interpolated. (WebCore::BasicShapeCircle::floatValueForRadiusInBox): Convert circle radius keywords to a float value. (WebCore::BasicShapeCircle::path): (WebCore::BasicShapeCircle::blend): * rendering/style/BasicShapes.h: (WebCore::BasicShapeCenterCoordinate::canBlend): (WebCore::BasicShapeRadius::canBlend): 2013-12-02 Alexey Proskuryakov WebCrypto HMAC doesn't check key algorithm's hash https://bugs.webkit.org/show_bug.cgi?id=125114 Reviewed by Anders Carlsson. Test: crypto/subtle/hmac-check-algorithm.html * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::keyAlgorithmMatches): Check it. 2013-12-02 Brady Eidson Possible crash in ProgressTracker::progressHeartbeatTimerFired(Timer*) https://bugs.webkit.org/show_bug.cgi?id=125110 Reviewed by Darin Adler. FrameLoader::loadProgressingStatusChanged() might be called while the Frame has a null FrameView. It’s unclear how to reproduce, but there’s no harm in a null check. * loader/FrameLoader.cpp: (WebCore::FrameLoader::loadProgressingStatusChanged): 2013-12-02 Brady Eidson Possible crash in ProgressTracker::progressHeartbeatTimerFired(Timer*) https://bugs.webkit.org/show_bug.cgi?id=125110 Reviewed by Darin Adler. It’s possible to have a null m_originatingProgressFrame when the heartbeat timer fires. On the surface this seems impossible because the only time m_originatingProgressFrame is cleared out the heartbeat timer is also stopped. But there’s likely still a race condition in multi-threaded environments. There’s no harm in null-checking m_originatingProgressFrame before accessing its loader. * loader/ProgressTracker.cpp: (WebCore::ProgressTracker::progressHeartbeatTimerFired): 2013-12-02 Brady Eidson Add more CachedPage null checks https://bugs.webkit.org/show_bug.cgi?id=125106 Reviewed by Sam Weinig. Only some functions in PageCache.cpp null-check the CachedPages in HistoryItems. Every part that manipulates the CachedPage should. * history/PageCache.cpp: (WebCore::PageCache::markPagesForVistedLinkStyleRecalc): (WebCore::PageCache::markPagesForFullStyleRecalc): (WebCore::PageCache::markPagesForDeviceScaleChanged): (WebCore::PageCache::markPagesForCaptionPreferencesChanged): 2013-12-02 Zoltan Horvath [CSS Shapes] Support inset parsing https://bugs.webkit.org/show_bug.cgi?id=124903 Reviewed by David Hyatt. In this patch I added support for inset shape parsing for CSS Shapes. Inset is defined by CSS Shapes Level 1 (http://dev.w3.org/csswg/css-shapes-1/#supported-basic-shapes). Inset is going to be used by shape-outside (bug #124905), and eventually by shape-inside. No new tests, I updated existing tests to cover the changes. * css/BasicShapeFunctions.cpp: (WebCore::valueForBasicShape): Add support for inset. (WebCore::basicShapeForValue): Add support for inset. * css/CSSBasicShapes.cpp: (WebCore::buildInsetString): Create inset css string. (WebCore::CSSBasicShapeInset::cssText): Convert inset shape to a CSS string. (WebCore::CSSBasicShapeInset::equals): Compare two inset rectangles. (WebCore::CSSBasicShapeInset::serializeResolvingVariables): Create an inset string, with CSS variables resolved. (WebCore::CSSBasicShapeInset::hasVariableReference): Determine if this inset has any CSS Variable references. * css/CSSBasicShapes.h: Add inset class. (WebCore::CSSBasicShapeInset::create): (WebCore::CSSBasicShapeInset::top): (WebCore::CSSBasicShapeInset::right): (WebCore::CSSBasicShapeInset::bottom): (WebCore::CSSBasicShapeInset::left): (WebCore::CSSBasicShapeInset::topLeftRadius): (WebCore::CSSBasicShapeInset::topRightRadius): (WebCore::CSSBasicShapeInset::bottomRightRadius): (WebCore::CSSBasicShapeInset::bottomLeftRadius): (WebCore::CSSBasicShapeInset::setTop): (WebCore::CSSBasicShapeInset::setRight): (WebCore::CSSBasicShapeInset::setBottom): (WebCore::CSSBasicShapeInset::setLeft): (WebCore::CSSBasicShapeInset::setTopLeftRadius): (WebCore::CSSBasicShapeInset::setTopRightRadius): (WebCore::CSSBasicShapeInset::setBottomRightRadius): (WebCore::CSSBasicShapeInset::setBottomLeftRadius): (WebCore::CSSBasicShapeInset::CSSBasicShapeInset): * css/CSSParser.cpp: (WebCore::completeBorderRadii): Move static function before parseInsetBorderRadius. (WebCore::CSSParser::parseInsetRoundedCorners): I added this helper function for parsing the rounded corners (WebCore::CSSParser::parseBasicShapeInset): Parse inset. (WebCore::CSSParser::parseBasicShape): Add call to parse inset. * css/CSSParser.h: * css/CSSPrimitiveValue.cpp: (WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Add constructor for LengthSize. (WebCore::CSSPrimitiveValue::init): Initialize LengthSize. * css/CSSPrimitiveValue.h: (WebCore::CSSPrimitiveValue::create): Add support for creating PrimitiveValue from LengthSize. * css/CSSValuePool.h: (WebCore::CSSValuePool::createValue): Add support for LengthSize. * platform/LengthSize.h: (WebCore::LengthSize::blend): Add blend for LengthSize. * rendering/shapes/ShapeInsideInfo.cpp: (WebCore::ShapeInsideInfo::isEnabledFor): Keep inset disabled for shape-inside now. * rendering/style/BasicShapes.cpp: (WebCore::BasicShapeInset::path): Calculate path for an inset. (WebCore::BasicShapeInset::blend): Blend two insets. * rendering/style/BasicShapes.h: Add higher level inset. (WebCore::BasicShapeInset::create): (WebCore::BasicShapeInset::top): (WebCore::BasicShapeInset::right): (WebCore::BasicShapeInset::bottom): (WebCore::BasicShapeInset::left): (WebCore::BasicShapeInset::topLeftRadius): (WebCore::BasicShapeInset::topRightRadius): (WebCore::BasicShapeInset::bottomRightRadius): (WebCore::BasicShapeInset::bottomLeftRadius): (WebCore::BasicShapeInset::setTop): (WebCore::BasicShapeInset::setRight): (WebCore::BasicShapeInset::setBottom): (WebCore::BasicShapeInset::setLeft): (WebCore::BasicShapeInset::setTopLeftRadius): (WebCore::BasicShapeInset::setTopRightRadius): (WebCore::BasicShapeInset::setBottomRightRadius): (WebCore::BasicShapeInset::setBottomLeftRadius): (WebCore::BasicShapeInset::BasicShapeInset): 2013-12-02 Alexey Proskuryakov Support WebCrypto AES-KW https://bugs.webkit.org/show_bug.cgi?id=125105 Reviewed by Sam Weinig. Tests: crypto/subtle/aes-kw-key-manipulation.html crypto/subtle/aes-kw-wrap-unwrap-aes.html * WebCore.xcodeproj/project.pbxproj: Added new files. * crypto/CryptoAlgorithmIdentifier.h: (WebCore::CryptoAlgorithmIdentifier): Added AES-KW. It's not standardized yet, but there appears to be a consensus that it will be specified. * bindings/js/JSCryptoAlgorithmDictionary.cpp: (WebCore::JSCryptoAlgorithmDictionary::createParametersForEncrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDecrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForSign): (WebCore::JSCryptoAlgorithmDictionary::createParametersForVerify): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDigest): (WebCore::JSCryptoAlgorithmDictionary::createParametersForGenerateKey): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDeriveKey): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDeriveBits): (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey): (WebCore::JSCryptoAlgorithmDictionary::createParametersForExportKey): Added AES-KW cases everywhere. * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm): (WebCore::JSCryptoKeySerializationJWK::keySizeIsValid): (WebCore::JSCryptoKeySerializationJWK::addJWKAlgorithmToJSON): Support importing/exporting AES-KW keys in JWK. * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::JSSubtleCrypto::importKey): (WebCore::JSSubtleCrypto::exportKey): (WebCore::JSSubtleCrypto::wrapKey): (WebCore::JSSubtleCrypto::unwrapKey): Added some accidentally forgotten std::moves. * crypto/algorithms/CryptoAlgorithmAES_KW.cpp: Added. * crypto/algorithms/CryptoAlgorithmAES_KW.h: Added. * crypto/mac/CryptoAlgorithmAES_KWMac.cpp: Added. * crypto/keys/CryptoKeyAES.cpp: (WebCore::CryptoKeyAES::CryptoKeyAES): Allow AES-KW as valid algorithm for AES keys. * crypto/mac/CryptoAlgorithmRegistryMac.cpp: (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms): Register AES-KW. 2013-12-02 Beth Dakin Add a setting to opt into a mode where the background extends and fixed elements don't move on rubber-band https://bugs.webkit.org/show_bug.cgi?id=124745 Reviewed by Tim Horton. New setting backgroundShouldExtendBeyondPage() will cause the tile cache to have a margin, and it will also cause fixed elements and backgrounds to stick to the viewport on scroll instead of sticking to the document. * WebCore.exp.in: * page/FrameView.cpp: (WebCore::FrameView::scrollBehaviorForFixedElements): * page/Settings.in: * rendering/RenderLayerBacking.cpp: (WebCore::RenderLayerBacking::RenderLayerBacking): 2013-12-02 Roger Zanoni [MediaStream] Use iterator-based loops instead of index-based loops https://bugs.webkit.org/show_bug.cgi?id=125021 Reviewed by Eric Carlson. Also, changing iterator variable names from iter to it and initializing an 'end' variable in each loop instead of evaluating 'collection.end()' multiple times. No new tests, covered by existing ones. * Modules/mediastream/MediaStream.cpp: (WebCore::MediaStream::cloneMediaStreamTrackVector): (WebCore::MediaStream::haveTrackWithSource): (WebCore::MediaStream::getTrackById): (WebCore::MediaStream::trackDidEnd): (WebCore::MediaStream::scheduledEventTimerFired): 2013-12-02 Rob Buis [css shapes] Parse new ellipse shape syntax https://bugs.webkit.org/show_bug.cgi?id=124620 Reviewed by Dirk Schulze. Implement parsing of the new ellipse shape syntax. This closely follows the patch for the new circle syntax (https://bugs.webkit.org/show_bug.cgi?id=124618), with some refactoring of functionality shared by both. Updated existing parsing tests to cover this. * css/BasicShapeFunctions.cpp: (WebCore::BasicShapeRadiusToCSSValue): (WebCore::valueForBasicShape): (WebCore::CSSValueToBasicShapeRadius): (WebCore::basicShapeForValue): * css/CSSBasicShapes.cpp: (WebCore::buildEllipseString): (WebCore::CSSBasicShapeEllipse::cssText): (WebCore::CSSBasicShapeEllipse::equals): (WebCore::buildDeprecatedEllipseString): (WebCore::CSSDeprecatedBasicShapeEllipse::cssText): (WebCore::CSSDeprecatedBasicShapeEllipse::equals): * css/CSSBasicShapes.h: (WebCore::CSSDeprecatedBasicShapeEllipse::create): (WebCore::CSSDeprecatedBasicShapeEllipse::centerX): (WebCore::CSSDeprecatedBasicShapeEllipse::centerY): (WebCore::CSSDeprecatedBasicShapeEllipse::radiusX): (WebCore::CSSDeprecatedBasicShapeEllipse::radiusY): (WebCore::CSSDeprecatedBasicShapeEllipse::setCenterX): (WebCore::CSSDeprecatedBasicShapeEllipse::setCenterY): (WebCore::CSSDeprecatedBasicShapeEllipse::setRadiusX): (WebCore::CSSDeprecatedBasicShapeEllipse::setRadiusY): (WebCore::CSSDeprecatedBasicShapeEllipse::CSSDeprecatedBasicShapeEllipse): * css/CSSParser.cpp: (WebCore::CSSParser::parseBasicShapeEllipse): (WebCore::CSSParser::parseDeprecatedBasicShapeEllipse): (WebCore::CSSParser::parseBasicShape): * css/CSSParser.h: * rendering/shapes/Shape.cpp: (WebCore::Shape::createShape): * rendering/style/BasicShapes.cpp: (WebCore::DeprecatedBasicShapeEllipse::path): (WebCore::DeprecatedBasicShapeEllipse::blend): (WebCore::BasicShapeEllipse::path): (WebCore::BasicShapeEllipse::blend): * rendering/style/BasicShapes.h: (WebCore::BasicShapeEllipse::centerX): (WebCore::BasicShapeEllipse::centerY): (WebCore::BasicShapeEllipse::radiusX): (WebCore::BasicShapeEllipse::radiusY): (WebCore::BasicShapeEllipse::setCenterX): (WebCore::BasicShapeEllipse::setCenterY): (WebCore::BasicShapeEllipse::setRadiusX): (WebCore::BasicShapeEllipse::setRadiusY): (WebCore::BasicShapeEllipse::BasicShapeEllipse): (WebCore::DeprecatedBasicShapeEllipse::create): (WebCore::DeprecatedBasicShapeEllipse::DeprecatedBasicShapeEllipse): 2013-12-02 Alexey Proskuryakov Add support for WebCrypto RSA-OAEP https://bugs.webkit.org/show_bug.cgi?id=125084 Build fix. * crypto/CommonCryptoUtilities.h: * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: * crypto/mac/CryptoKeyRSAMac.cpp: 2013-12-02 Brendan Long Use GenericEventQueue in TrackListBase and reduce code duplication with scheduleTrackEvent() https://bugs.webkit.org/show_bug.cgi?id=124811 Reviewed by Eric Carlson. No new tests because this is just refactoring. * html/track/TrackListBase.cpp: (TrackListBase::TrackListBase): Replace event code with a GenericEventQueue. (TrackListBase::scheduleTrackEvent): Factor out duplicate code in schedule{Add,Remove}TrackEvent functions. (TrackListBase::scheduleAddTrackEvent): Same. (TrackListBase::scheduleRemoveTrackEvent): Same. (TrackListBase::scheduleChangeEvent): Use GenericEventQueue. * html/track/TrackListBase.h: Replace event code with GenericEventQueue. 2013-12-02 Alexey Proskuryakov Add support for WebCrypto RSA-OAEP https://bugs.webkit.org/show_bug.cgi?id=125084 Build fix. * WebCore.xcodeproj/project.pbxproj: Fix an automatic merge failure by re-adding CryptoAlgorithmRsaOaepParams.h. 2013-12-02 Victor Jaquez [Gstreamer] update webkitvideosink metadata https://bugs.webkit.org/show_bug.cgi?id=125082 Reviewed by Philippe Normand. No new tests, no behavior changes. * platform/graphics/gstreamer/VideoSinkGStreamer.cpp: (webkit_video_sink_class_init): 2013-12-02 Víctor Manuel Jáquez Leal Simplify MediaPlayerPrivateGStreamerBase::createVideoSink() https://bugs.webkit.org/show_bug.cgi?id=125077 Remove the method's unused parameter. Remove the GStreamer 0.10.22 run-time validation, since we are using GStreamer 1.0 officially. Remove the creation of a spurious Bin for the video sink, since either the fpssink or the webkitsink are valid sink elements. Change fpsink to a GRefPtr. Now, createVideoSink() returns a simple pointer to the created sink element. Reviewed by Philippe Normand. No new tests, no behavior changes. * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp: (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin): * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: (WebCore::MediaPlayerPrivateGStreamerBase::createVideoSink): (WebCore::MediaPlayerPrivateGStreamerBase::decodedFrameCount): (WebCore::MediaPlayerPrivateGStreamerBase::droppedFrameCount): * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h: 2013-12-02 Alexey Proskuryakov Add support for WebCrypto RSA-OAEP https://bugs.webkit.org/show_bug.cgi?id=125084 Reviewed by Sam Weinig. Tests: crypto/subtle/rsa-oaep-key-manipulation.html crypto/subtle/rsa-oaep-plaintext-length.html crypto/subtle/rsa-oaep-wrap-unwrap-aes.html * WebCore.xcodeproj/project.pbxproj: Added new files. * bindings/js/JSCryptoAlgorithmDictionary.cpp: (WebCore::createRsaOaepParams): (WebCore::JSCryptoAlgorithmDictionary::createParametersForEncrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForDecrypt): (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey): Added RSA-OAEP parameters. * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm): (WebCore::JSCryptoKeySerializationJWK::keySizeIsValid): (WebCore::JSCryptoKeySerializationJWK::addJWKAlgorithmToJSON): Support RSA-OAEP in JWK. It is more limited than general WebCrypto, as JWK only allows SHA-1 as hash. * crypto/CommonCryptoUtilities.cpp: Added. (WebCore::getCommonCryptoDigestAlgorithm): * crypto/CommonCryptoUtilities.h: Added. Extracted some shared code and forward declarations for CommonCrypto. * crypto/CryptoAlgorithmParameters.h: (WebCore::CryptoAlgorithmParameters::Class): * crypto/parameters/CryptoAlgorithmRsaOaepParams.h: Added. Added RsaOaepParams. * crypto/algorithms/CryptoAlgorithmRSA_OAEP.cpp: Added. * crypto/algorithms/CryptoAlgorithmRSA_OAEP.h: Added. * crypto/mac/CryptoAlgorithmRSA_OAEPMac.cpp: Added. * crypto/mac/CryptoAlgorithmHMACMac.cpp: (WebCore::getCommonCryptoHMACAlgorithm): (WebCore::CryptoAlgorithmHMAC::platformSign): (WebCore::CryptoAlgorithmHMAC::platformVerify): * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: * crypto/mac/CryptoKeyMac.cpp: * crypto/mac/CryptoKeyRSAMac.cpp: Use CommonCryptoUtilities. * crypto/mac/CryptoAlgorithmRegistryMac.cpp: (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms): Register RSA-OAEP. 2013-12-02 Andres Gomez [GTK] Fails to build with freetype 2.5.1 https://bugs.webkit.org/show_bug.cgi?id=125074 Reviewed by Carlos Garcia Campos. FreeType specifies a canonical way of including their own headers. Now, we are following this recommendation so the compilation won't be broken again due to an upgrade in FeeType's including paths. * platform/graphics/freetype/FontPlatformDataFreeType.cpp: * platform/graphics/freetype/SimpleFontDataFreeType.cpp: * platform/graphics/harfbuzz/HarfBuzzFaceCairo.cpp: 2013-12-02 Chris Fleizach AX: Crash at WebCore::commonTreeScope https://bugs.webkit.org/show_bug.cgi?id=125042 Reviewed by Mario Sanchez Prada. When an AX text marker that references a node in a detached document is used to create a text marker range, a crash occurs because the method to determine commonTreeScopes does not account for when there are no common tree scopes. Test: platform/mac/accessibility/ordered-textmarker-crash.html * accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::visiblePositionRangeForUnorderedPositions): * dom/TreeScope.cpp: (WebCore::commonTreeScope): 2013-12-02 Nick Diego Yamane Fix a crash in the webaudio source provider when the audio track is going away. https://bugs.webkit.org/show_bug.cgi?id=124975 Reviewed by Philippe Normand. Merged https://chromium.googlesource.com/chromium/blink/+/b21838b32bf11b1a972dfc449ddde71115490c23 Before this patch, it was hitting a use-after-free crash when the audio track in the media stream is going away and the webaudio mediastreamsourcenode is still running. * Modules/webaudio/AudioContext.cpp: (WebCore::AudioContext::createMediaStreamSource): Passing audio track pointer to MediaStreamAudioSourceNode constructor. * Modules/webaudio/MediaStreamAudioSourceNode.cpp: (WebCore::MediaStreamAudioSourceNode::create): (WebCore::MediaStreamAudioSourceNode::MediaStreamAudioSourceNode): * Modules/webaudio/MediaStreamAudioSourceNode.h: Added MediaStreamTrack class variable and change the constructor to receive it as parameter. 2013-12-02 Andrzej Badowski [ATK] Support active state for listbox elements. https://bugs.webkit.org/show_bug.cgi?id=125009 Reviewed by Chris Fleizach. Added support for ATK_STATE_ACTIVE for listbox elements. * accessibility/atk/WebKitAccessibleWrapperAtk.cpp: (setAtkStateSetFromCoreObject): 2013-12-02 Seokju Kwon Web Inspector: Remove unused functions from InspectorAgent https://bugs.webkit.org/show_bug.cgi?id=125061 Reviewed by Antoine Quint. Get rid of unused functions, redundant inclusion and forward declaration. No new tests, no behavior changes. * inspector/InspectorAgent.cpp: * inspector/InspectorAgent.h: 2013-12-02 Tibor Meszaros Fix build warning in EventHandler.cpp https://bugs.webkit.org/show_bug.cgi?id=125010 Reviewed by Csaba Osztrogonác. * page/EventHandler.cpp: (WebCore::EventHandler::eventInvertsTabsToLinksClientCallResult): 2013-12-02 Attila Dusnoki HTML5 required attribute validation messages implemented. https://bugs.webkit.org/show_bug.cgi?id=125003 Reviewed by Gyuyoung Kim. * platform/efl/LocalizedStringsEfl.cpp: (WebCore::validationMessagePatternMismatchText): (WebCore::validationMessageValueMissingText): (WebCore::validationMessageValueMissingForCheckboxText): (WebCore::validationMessageValueMissingForFileText): (WebCore::validationMessageValueMissingForMultipleFileText): (WebCore::validationMessageValueMissingForRadioText): (WebCore::validationMessageValueMissingForSelectText): (WebCore::validationMessageBadInputForNumberText): 2013-12-01 Andreas Kling SVG: Intersection/enclosure checks should use RenderElement. Make RenderSVGModelObject's checkIntersection() and checkEnclosure() take RenderElement* instead of RenderObject*. They are only ever called with SVGElement's renderers. Reviewed by Sam Weinig. 2013-12-01 Andreas Kling Remove unreachable labels for -webkit-margin-*-collapse properties. The following properties are implemented in DeprecatedStyleBuilder and should not have case labels in the applyProperty() switch: -webkit-margin-before-collapse -webkit-margin-top-collapse -webkit-margin-after-collapse -webkit-margin-bottom-collapse This seems counter-intuitive, but they are actually *not* like other directional properties. In this case, before/after are only aliases for top/bottom, and do not depend on writing-mode or text-direction. See also r68561, where the aliases were originally added. Reviewed by Anders Carlsson. 2013-12-01 Andreas Kling CSSFunctionValue constructors should return PassRef. Make CSSFunctionValue::create() helpers return PassRef instead of PassRefPtr since they will never return null. Reviewed by Anders Carlsson. 2013-12-01 Commit Queue Unreviewed, rolling out r159764. http://trac.webkit.org/changeset/159764 https://bugs.webkit.org/show_bug.cgi?id=125055 appears to hurt html5-full-render times (Requested by kling on #webkit). * html/parser/HTMLConstructionSite.cpp: (WebCore::HTMLConstructionSite::insertTextNode): * html/parser/HTMLConstructionSite.h: 2013-12-01 Andreas Kling Make more computed style helpers return PassRef. Reduce branchiness in computed style code by making more of the file-local helpers return PassRef instead of PassRefPtr. Reviewed by Anders Carlsson. 2013-11-30 Ryuan Choi [EFL] Implement scrollbarThickness for opaque scrollbar https://bugs.webkit.org/show_bug.cgi?id=125034 Reviewed by Gyuyoung Kim. Implemented scrollbarThickness to support opaque scrollbar. Now, edj can decide whether to support opaque scrollbar by adding scrollbar.thickness. In addition, added OVERRIDE/FINAL keyword and removed unnecessary destructor in ScrollbarThemeEfl.cpp. No new tests, no behavior changes with default theme. * platform/efl/RenderThemeEfl.cpp: (WebCore::RenderThemeEfl::loadTheme): Update thickness of scrollbar when theme was loaded. * platform/efl/ScrollbarThemeEfl.cpp: * platform/efl/ScrollbarThemeEfl.h: (WebCore::ScrollbarThemeEfl::setScrollbarThickness): (WebCore::ScrollbarThemeEfl::scrollbarThickness): (WebCore::ScrollbarThemeEfl::registerScrollbar): (WebCore::ScrollbarThemeEfl::unregisterScrollbar): 2013-11-29 Tamas Gergely Remove Symbian specific code. https://bugs.webkit.org/show_bug.cgi?id=124939 Reviewed by Zoltan Herczeg. Symbian is not supported, remove leftover code. * plugins/npapi.h: 2013-11-28 Gyuyoung Kim Rename InlineIterator::m_obj and make it private https://bugs.webkit.org/show_bug.cgi?id=124837 Reviewed by Antti Koivisto. InlineIterator has been exported m_obj as public though there is a getter function. Besides *object* name isn't ambigious. So, changed it with m_renderer and renderer(). Additionally, setRenderer() is added as well. No new tests, no behavior changes. * rendering/InlineIterator.h: (WebCore::InlineIterator::setObject): (WebCore::operator==): (WebCore::operator!=): (WebCore::InlineBidiResolver::appendRun): * rendering/RenderBlockLineLayout.cpp: (WebCore::RenderBlockFlow::appendRunsForObject): (WebCore::constructBidiRunsForLine): (WebCore::RenderBlockFlow::createLineBoxesFromBidiRuns): (WebCore::RenderBlockFlow::layoutRunsAndFloatsInRange): (WebCore::RenderBlockFlow::matchedEndLine): * rendering/line/BreakingContextInlineHeaders.h: (WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): (WebCore::BreakingContext::BreakingContext): (WebCore::BreakingContext::currentObject): (WebCore::BreakingContext::initializeForCurrentObject): (WebCore::BreakingContext::handleBR): (WebCore::BreakingContext::handleOutOfFlowPositioned): (WebCore::BreakingContext::handleFloat): (WebCore::BreakingContext::handleEmptyInline): (WebCore::BreakingContext::handleReplaced): (WebCore::iteratorIsBeyondEndOfRenderCombineText): (WebCore::ensureCharacterGetsLineBox): (WebCore::BreakingContext::handleText): (WebCore::BreakingContext::canBreakAtThisPosition): (WebCore::BreakingContext::commitAndUpdateLineBreakIfNeeded): (WebCore::checkMidpoints): (WebCore::BreakingContext::handleEndOfLine): * rendering/line/LineBreaker.cpp: (WebCore::LineBreaker::skipTrailingWhitespace): (WebCore::LineBreaker::skipLeadingWhitespace): * rendering/line/LineInlineHeaders.h: (WebCore::skipNonBreakingSpace): (WebCore::requiresLineBox): 2013-11-28 Antti Koivisto Rename StylePropertySet to StyleProperties https://bugs.webkit.org/show_bug.cgi?id=124990 Reviewed by Andreas Kling. "Set" does not add useful information here. Use less clunky plural name. 2013-11-28 Thiago de Barros Lacerda Nix Upstream: Adding EditorNix to WebCore https://bugs.webkit.org/show_bug.cgi?id=124984 Reviewed by Csaba Osztrogonác. No new tests needed. * PlatformNix.cmake: * editing/nix/EditorNix.cpp: Added. 2013-11-28 Zoltan Horvath [Win] Update vcxproj.filters, since LineInfo.h and LineLayoutState.h have been moved to rendering/line https://bugs.webkit.org/show_bug.cgi?id=124959 Reviewed by Brent Fulgham. Update WebCore.vcxproj.filters, since LineInfo.h (r155628) and LineLayoutState.h (158121) have been moved to rendering/line. No new tests, no behavior change. * WebCore.vcxproj/WebCore.vcxproj.filters: 2013-11-28 Laszlo Vidacs RenderTableSection Blink merge asserting https://bugs.webkit.org/show_bug.cgi?id=124857 Reviewed by Csaba Osztrogonác. Use border spacing at the end of all sections. * rendering/RenderTableSection.cpp: (WebCore::RenderTableSection::calcRowLogicalHeight): 2013-11-28 Antti Koivisto Remove feature: CSS variables https://bugs.webkit.org/show_bug.cgi?id=114119 Reviewed by Andreas Kling. The feature is unmaintained and it is getting in the way of refactoring. Code quality is not up to WebKit standards either. * Configurations/FeatureDefines.xcconfig: * GNUmakefile.list.am: * WebCore.xcodeproj/project.pbxproj: * css/CSSBasicShapes.cpp: * css/CSSBasicShapes.h: * css/CSSCalculationValue.cpp: (WebCore::unitCategory): (WebCore::hasDoubleValue): (WebCore::CSSCalcPrimitiveValue::toCalcValue): (WebCore::CSSCalcPrimitiveValue::computeLengthPx): (WebCore::determineCategory): (WebCore::CSSCalcBinaryOperation::primitiveType): * css/CSSCalculationValue.h: * css/CSSComputedStyleDeclaration.cpp: (WebCore::ComputedStyleExtractor::propertyValue): * css/CSSGrammar.y.in: * css/CSSParser.cpp: (WebCore::CSSParserContext::CSSParserContext): (WebCore::operator==): (WebCore::filterProperties): (WebCore::CSSParser::createStylePropertySet): (WebCore::CSSParser::addProperty): (WebCore::CSSParser::validCalculationUnit): (WebCore::CSSParser::validUnit): (WebCore::CSSParser::createPrimitiveNumericValue): (WebCore::CSSParser::parseValidPrimitive): (WebCore::CSSParser::parseValue): (WebCore::CSSParser::parseReflect): (WebCore::CSSParser::detectDashToken): (WebCore::CSSParser::realLex): * css/CSSParser.h: * css/CSSParserMode.h: * css/CSSParserValues.cpp: (WebCore::CSSParserValue::createCSSValue): * css/CSSParserValues.h: * css/CSSPrimitiveValue.cpp: (WebCore::isValidCSSUnitTypeForDoubleConversion): (WebCore::CSSPrimitiveValue::primitiveType): (WebCore::CSSPrimitiveValue::cleanup): (WebCore::CSSPrimitiveValue::getStringValue): (WebCore::CSSPrimitiveValue::customCSSText): (WebCore::CSSPrimitiveValue::equals): * css/CSSPrimitiveValue.h: * css/CSSPrimitiveValueMappings.h: (WebCore::CSSPrimitiveValue::convertToLength): * css/CSSProperty.cpp: * css/CSSProperty.h: (WebCore::CSSProperty::CSSProperty): * css/CSSReflectValue.cpp: * css/CSSReflectValue.h: * css/CSSValue.cpp: (WebCore::CSSValue::equals): (WebCore::CSSValue::cssText): (WebCore::CSSValue::destroy): * css/CSSValue.h: (WebCore::CSSValue::setCssText): * css/CSSValueList.cpp: * css/CSSValueList.h: * css/CSSVariableValue.h: Removed. * css/Pair.h: * css/Rect.h: * css/StylePropertySet.cpp: (WebCore::StylePropertySet::asText): (WebCore::StylePropertySet::PropertyReference::cssName): * css/StyleResolver.cpp: (WebCore::StyleResolver::styleForPage): (WebCore::StyleResolver::applyProperties): (WebCore::StyleResolver::applyMatchedProperties): (WebCore::StyleResolver::applyProperty): * css/StyleResolver.h: * css/WebKitCSSTransformValue.cpp: * css/WebKitCSSTransformValue.h: (WebCore::WebKitCSSTransformValue::equals): * css/makeprop.pl: * page/Settings.cpp: (WebCore::Settings::Settings): * page/Settings.h: * rendering/style/RenderStyle.h: * rendering/style/StyleRareInheritedData.cpp: (WebCore::StyleRareInheritedData::StyleRareInheritedData): (WebCore::StyleRareInheritedData::operator==): * rendering/style/StyleRareInheritedData.h: * rendering/style/StyleVariableData.h: Removed. * testing/InternalSettings.cpp: (WebCore::InternalSettings::Backup::Backup): (WebCore::InternalSettings::Backup::restoreTo): * testing/InternalSettings.h: * testing/InternalSettings.idl: 2013-11-28 Thiago de Barros Lacerda Updating RTCPeerConnectionHandlerMock after r159769 https://bugs.webkit.org/show_bug.cgi?id=124947 Reviewed by Philippe Normand. Adding its create function back, in order to run RTCPeerConnection LayoutTests. No new tests needed. * platform/mock/RTCPeerConnectionHandlerMock.cpp: (WebCore::RTCPeerConnectionHandlerMock::create): * platform/mock/RTCPeerConnectionHandlerMock.h: 2013-11-27 Gustavo Noronha Silva [GTK] Support custom types for drag and drop data https://bugs.webkit.org/show_bug.cgi?id=124659 Reviewed by Martin Robinson. Covered by fast/events/drag-customData.html. * platform/gtk/DataObjectGtk.cpp: (WebCore::DataObjectGtk::unknownTypes): returns a hash map with all custom types set. (WebCore::DataObjectGtk::clearAllExceptFilenames): clear custom types. * platform/gtk/DataObjectGtk.h: (WebCore::DataObjectGtk::hasUnknownTypeData): returns whether custom types are set. (WebCore::DataObjectGtk::unknownTypeData): returns the data for a custom type. (WebCore::DataObjectGtk::setUnknownTypeData): sets the data for a custom type. * platform/gtk/PasteboardGtk.cpp: (WebCore::Pasteboard::writeString): handle unknown types as custom. (WebCore::Pasteboard::writePasteboard): ditto. (WebCore::Pasteboard::hasData): also check for custom types. (WebCore::Pasteboard::types): also obtain the list of custom types. (WebCore::Pasteboard::readString): handle unknown types as custom. * platform/gtk/PasteboardHelper.cpp: (WebCore::initGdkAtoms): new unknown atom. (WebCore::PasteboardHelper::PasteboardHelper): add custom type to the list of targets. (WebCore::PasteboardHelper::fillSelectionData): turns any custom types' data into a GVariant, which is in turn serialized to a single string for GtkSelectionData to hold. (WebCore::PasteboardHelper::targetListForDataObject): add custom data to the target list if any is set. (WebCore::PasteboardHelper::fillDataObjectFromDropData): retrieve the custom types and their data from the serialized GVariant string held by GtkSelectionData. (WebCore::PasteboardHelper::dropAtomsForContext): handle custom types. 2013-11-27 Eric Carlson Allow the QuickTime plug-in to be replaced by script in an isolated word https://bugs.webkit.org/show_bug.cgi?id=124900 Reviewed by Dean Jackson. Test: plugins/quicktime-plugin-replacement.html * CMakeLists.txt: Add new Modules path. * DerivedSources.make: Add new files. * GNUmakefile.am: Add new Modules path. * GNUmakefile.list.am: Add new header. * WebCore.vcxproj/WebCore.vcxproj: Add new header. * WebCore.vcxproj/WebCoreCommon.props: Add new Modules path. * WebCore.xcodeproj/project.pbxproj: Add new files. * Modules/plugins: Added. * Modules/plugins/PluginReplacement.h: Added. Defines the interface for a plug-in replacement. Create a replacement for the QuickTime plug-in. * Modules/plugins/QuickTimePluginReplacement.cpp: Added. * Modules/plugins/QuickTimePluginReplacement.css: Added. * Modules/plugins/QuickTimePluginReplacement.h: Added. * Modules/plugins/QuickTimePluginReplacement.idl: Added. * Modules/plugins/QuickTimePluginReplacement.js: Added. Allow plug-in replacement to be enabled at runtime. * bindings/generic/RuntimeEnabledFeatures.h: (WebCore::RuntimeEnabledFeatures::setPluginReplacementEnabled): (WebCore::RuntimeEnabledFeatures::pluginReplacementEnabled): * bindings/js/JSDOMBinding.h: (WebCore::toJS): Add toJS(... const String& ...). * bindings/js/JSPluginElementFunctions.cpp: (WebCore::pluginScriptObject): Give a plug-in replacement a first shot at defining the script interface. * html/HTMLEmbedElement.cpp: (WebCore::HTMLEmbedElement::updateWidget): Call base class requestObject. * html/HTMLMediaElement.cpp: (HTMLMediaElement::fileSize): New, passthrough to media engine. * html/HTMLMediaElement.h: * html/HTMLObjectElement.cpp: (WebCore::HTMLObjectElement::updateWidget): Call base class requestObject. Moved some logic that was previously used only for creating a plug-in snapshot to the base class so it can be shared by a plug-in replacement. * html/HTMLPlugInElement.cpp: (WebCore::HTMLPlugInElement::HTMLPlugInElement): Initialize timer used to swap renderers. (WebCore::HTMLPlugInElement::createRenderer): Allow plug-in replacement to create the renderer. (WebCore::HTMLPlugInElement::swapRendererTimerFired): Create a shadow root. (WebCore::HTMLPlugInElement::setDisplayState): Set the new state, prime the swap renderer timer if necessary. (WebCore::HTMLPlugInElement::didAddUserAgentShadowRoot): Tell the plug-in replacement to install itself in the new shadow DOM. (WebCore::registeredPluginReplacements): Return vector of all registered plug-in replacements. (WebCore::registerPluginReplacement): Add a plug-in replacement. (WebCore::pluginReplacementForType): Find a plug-in replacement for a MIME type. (WebCore::HTMLPlugInElement::requestObject): If there is a plug-in replacement for the MIME type, create it and set the display state. (WebCore::HTMLPlugInElement::scriptObjectForPluginReplacement): Return the script object for the current plug-in replacement, if any. * html/HTMLPlugInElement.h: Move some plug-in snapshot code into the base class. * html/HTMLPlugInImageElement.cpp: (WebCore::HTMLPlugInImageElement::HTMLPlugInImageElement): No need to initialize timer. (WebCore::HTMLPlugInImageElement::setDisplayState): Call base class. (WebCore::HTMLPlugInImageElement::createRenderer): Ditto. (WebCore::HTMLPlugInImageElement::didAddUserAgentShadowRoot): Ditto. (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): Remove unnecessary class name. (WebCore::HTMLPlugInImageElement::requestObject): New. * html/HTMLPlugInImageElement.h: * html/HTMLVideoElement.h: Make createRenderer public so the QuickTime plug-in replacement can call it. * platform/graphics/MediaPlayer.cpp: (WebCore::MediaPlayer::fileSize): New. * platform/graphics/MediaPlayer.h: * platform/graphics/MediaPlayerPrivate.h: * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp: (WebCore::MediaPlayerPrivateAVFoundation::extraMemoryCost): totalBytes returns an unsigned long long. * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h: (WebCore::MediaPlayerPrivateAVFoundation::fileSize): * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp: (WebCore::MediaPlayerPrivateAVFoundationCF::totalBytes): Return an unsigned long long. * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::totalBytes): Ditto. * testing/InternalSettings.cpp: (WebCore::InternalSettings::Backup::Backup): Backup the plug-in replacement runtime setting. (WebCore::InternalSettings::Backup::restoreTo): Restore it. (WebCore::InternalSettings::setPluginReplacementEnabled): Set it. * testing/InternalSettings.h: * testing/InternalSettings.idl: 2013-11-27 Thiago de Barros Lacerda Adding MediaConstraintsMock class https://bugs.webkit.org/show_bug.cgi?id=124902 Reviewed by Eric Carlson. Validate constraints used in RTCPeerConnection LayoutTests Existing test was updated. * CMakeLists.txt: * GNUmakefile.list.am: * platform/mock/MediaConstraintsMock.cpp: Added. * platform/mock/MediaConstraintsMock.h: Added. * platform/mock/MockMediaStreamCenter.cpp: (WebCore::MockMediaStreamCenter::validateRequestConstraints): Now using MediaConstraintsMock (WebCore::MockMediaStreamCenter::createMediaStream): Ditto. * platform/mock/RTCPeerConnectionHandlerMock.cpp: (WebCore::RTCPeerConnectionHandlerMock::initialize): Ditto. 2013-11-27 Bear Travis [CSS Shapes] Shape-Inside Should Default to 'auto' https://bugs.webkit.org/show_bug.cgi?id=124851 Reviewed by Alexandru Chiculita. The current shape-inside specification has the property default to the 'auto' value, not 'outside-shape'. Updated tests are under fast/shapes. * rendering/style/RenderStyle.cpp: * rendering/style/RenderStyle.h: 2013-11-27 Hans Muller [CSS Shapes] shape-inside rectangle layout can fail https://bugs.webkit.org/show_bug.cgi?id=124784 Reviewed by Andreas Kling. Apply LayoutUnit::fromFloatCeil() consistently in RectangleShape::firstIncludedIntervalLogicalTop(). Test: fast/shapes/shape-inside/shape-inside-subpixel-rectangle-top.html * rendering/shapes/RectangleShape.cpp: (WebCore::RectangleShape::firstIncludedIntervalLogicalTop): 2013-11-27 Nick Diego Yamane Remove Qt-specific .qrc files https://bugs.webkit.org/show_bug.cgi?id=124944 Reviewed by Andreas Kling. No new tests needed. * WebCore.qrc: Removed. 2013-11-27 Xabier Rodriguez Calvar [GStreamer] Invalid command line error when visiting www.chessbase.com https://bugs.webkit.org/show_bug.cgi?id=124715 Reviewed by Philippe Normand. We were not handling the HTTP errors in the WebKit GStreamer source and therefore the 404 error page was being 'decoded'. As no decoder could be found (for obvious reasons), playback failed, but it should be failing for the source not being found instead of the decoding problem. Test: http/tests/media/video-error-does-not-exist.html * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp: (StreamingClient::handleResponseReceived): Handle HTTP errors in the source and raise a GStreamer error to the pipeline. 2013-11-14 Sergio Villar Senin [CSS Grid Layout] Fix positioning of grid items with margins https://bugs.webkit.org/show_bug.cgi?id=124345 Reviewed by David Hyatt. From Blink r157925 and r158041 by Test: fast/css-grid-layout/grid-item-margin-resolution.html Adds margin start/before to the positions of grid items (removing several FIXME's in the current code). This means calling findChildLogicalPosition() after the layout in order to have the right values for the margins. In order to match flexbox and author's intents we're also including the margins of grid items in the intrinsic size of the grid. That's why flexbox's marginLogicalPositionForChild() is moved up to RenderBlock in order to share it with RenderGrid. * rendering/RenderBlock.cpp: (WebCore::RenderBlock::marginIntrinsicLogicalWidthForChild): Moved from RenderFlexibleBox::marginLogicalWidthForChild(). * rendering/RenderBlock.h: * rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::computeIntrinsicLogicalWidths): * rendering/RenderGrid.cpp: (WebCore::RenderGrid::computePreferredTrackWidth): (WebCore::RenderGrid::layoutGridItems): (WebCore::RenderGrid::findChildLogicalPosition): 2013-11-26 Sergio Villar Senin [CSS Grid Layout] Support grid-definition-{rows|columns} repeat() syntax https://bugs.webkit.org/show_bug.cgi?id=103312 Reviewed by Andreas Kling. Added support for the repeat() syntax inside grid-definition-{rows|columns} by just adding the repeated values to our list of column|row definitions. The parsing of was refactored in a new function as it's used now in three different places. The parsing was also refactored to share it with the repeat() parsing. Test: fast/css-grid-layout/grid-element-repeat-get-set.html * css/CSSParser.cpp: (WebCore::CSSParser::parseValue): (WebCore::CSSParser::parseGridTrackNames): (WebCore::CSSParser::parseGridTrackList): (WebCore::CSSParser::parseGridTrackRepeatFunction): (WebCore::CSSParser::parseGridTrackSize): * css/CSSParser.h: 2013-11-26 Marcelo Lira Nix upstreaming - Adding build files and supporting scripts https://bugs.webkit.org/show_bug.cgi?id=118367 Reviewed by Ryosuke Niwa. No new tests needed. * CMakeLists.txt: * PlatformNix.cmake: Added. 2013-11-26 Tim Horton Don't parent the TileController root layer in two places https://bugs.webkit.org/show_bug.cgi?id=124873 Reviewed by Brent Fulgham. * platform/graphics/ca/mac/TileController.mm: (WebCore::TileController::TileController): The TileController's layer is already parented by callers of TileController::create, and in a special way. TileController shouldn't parent itself, anyway... 2013-11-26 Nick Diego Yamane [MediaStream API] HTMLMediaElement should be able to use MediaStream as source https://bugs.webkit.org/show_bug.cgi?id=121943 Reviewed by Eric Carlson. Implement MediaStream direct assignment to Media Elements using the new 'srcObject' attribute: http://www.w3.org/TR/mediacapture-streams/#direct-assignment-to-media-elements Test: fast/mediastream/MediaStream-MediaElement-srcObject.html * CMakeLists.txt: Added new HTMLMediaElementMediaStream.h and .cpp to cmake build. * DerivedSources.make: Added HTMLMediaElementMediaStream.idl. * GNUmakefile.list.am: Added new HTMLMediaElementMediaStream* to autotools build. * WebCore.xcodeproj/project.pbxproj: Added new files. * Modules/mediastream/HTMLMediaElementMediaStream.cpp: Added. (WebCore::HTMLMediaElementMediaStream::srcObject): implements srcObject getter. (WebCore::HTMLMediaElementMediaStream::setSrcObject): implements srcObject setter. * Modules/mediastream/HTMLMediaElementMediaStream.h: Added. * Modules/mediastream/HTMLMediaElementMediaStream.idl: Added. * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::setSrcObject): This is an initial implementation, and is still incomplete, that will be addressed in a separate bug: https://webkit.org/b/124896 * html/HTMLMediaElement.h: Added m_mediaStreamSrcObject class variable and its corresponding getter. 2013-11-26 Andreas Kling Use child iterator to find operators in RenderMathMLRow::layout(). Replace manual children walk with childrenOfType. Minor update to fix build. Reviewed by Martin Robinson. 2013-11-26 Andreas Kling RenderObject: Inline isBody() and isHR(). Together these account for ~0.3% of samples on HTML5-8266. Almost all of it is call overhead. Reviewed by Anders Carlsson. 2013-11-26 Bear Travis [CSS Shapes] Layout using [ || ] value https://bugs.webkit.org/show_bug.cgi?id=124428 Reviewed by David Hyatt. When a box value is supplied, use it to size and position the shape. Otherwise, use a default value (content-box for shape-inside, margin-box for shape-outside). This patch extends the sizing and positioning code used for the box patch (Bug 124227) to also apply to shapes. With this patch, we also no longer use the box-sizing property to size and position shapes. Tests: fast/shapes/shape-outside-floats/shape-outside-shape-boxes-001.html fast/shapes/shape-outside-floats/shape-outside-shape-boxes-002.html fast/shapes/shape-outside-floats/shape-outside-shape-boxes-003.html * css/CSSComputedStyleDeclaration.cpp: (WebCore::ComputedStyleExtractor::propertyValue): Adjust for ShapeValues storing BasicShape::ReferenceBox as their box value, rather than a CSSValueID. * css/DeprecatedStyleBuilder.cpp: (WebCore::ApplyPropertyShape::applyValue): Ditto. * rendering/shapes/ShapeInfo.h: (WebCore::ShapeInfo::setShapeSize): Adjust for BasicShapes with reference boxes as well as plain box values. Also, remove old box-sizing code. (WebCore::ShapeInfo::logicalTopOffset): Ditto. (WebCore::ShapeInfo::logicalLeftOffset): Ditto. * rendering/shapes/ShapeInsideInfo.h: * rendering/shapes/ShapeOutsideInfo.h: * rendering/style/ShapeValue.h: (WebCore::ShapeValue::createBoxValue): Adjust for boxes being stored as BasicShape::ReferenceBoxes. (WebCore::ShapeValue::box): Ditto. (WebCore::ShapeValue::ShapeValue): Ditto. 2013-11-26 Brian J. Burg ImageBuffer::create should return a std::unique_ptr instead of OwnPtr. https://bugs.webkit.org/show_bug.cgi?id=124822 Reviewed by Andreas Kling. Replace all uses of OwnPtr and PassOwnPtr with std::unique_ptr. Replace calls to OwnPtr::clear() and OwnPtr::release() with reset() and std::move(). Remove unnecessary includes. No new tests. This is a mechanical refactoring. * css/CSSFilterImageValue.cpp: (WebCore::CSSFilterImageValue::image): * html/HTMLCanvasElement.cpp: (WebCore::HTMLCanvasElement::setSurfaceSize): * html/HTMLCanvasElement.h: * html/canvas/CanvasRenderingContext2D.cpp: (WebCore::CanvasRenderingContext2D::createCompositingBuffer): (WebCore::CanvasRenderingContext2D::fullCanvasCompositedDrawImage): (WebCore::CanvasRenderingContext2D::fullCanvasCompositedFill): (WebCore::CanvasRenderingContext2D::drawTextInternal): * html/canvas/CanvasRenderingContext2D.h: * html/canvas/WebGLRenderingContext.cpp: (WebCore::WebGLRenderingContext::LRUImageBufferCache::LRUImageBufferCache): (WebCore::WebGLRenderingContext::LRUImageBufferCache::imageBuffer): * html/canvas/WebGLRenderingContext.h: * html/shadow/MediaControlElements.cpp: (WebCore::MediaControlTextTrackContainerElement::createTextTrackRepresentationImage): * page/Frame.cpp: (WebCore::Frame::nodeImage): (WebCore::Frame::dragImageForSelection): * platform/graphics/BitmapImage.cpp: (WebCore::BitmapImage::drawPattern): * platform/graphics/CrossfadeGeneratedImage.cpp: (WebCore::CrossfadeGeneratedImage::drawPattern): * platform/graphics/GradientImage.h: * platform/graphics/GraphicsContext.cpp: (WebCore::GraphicsContext::createCompatibleBuffer): * platform/graphics/GraphicsContext.h: * platform/graphics/ImageBuffer.cpp: (WebCore::ImageBuffer::createCompatibleBuffer): * platform/graphics/ImageBuffer.h: (WebCore::ImageBuffer::create): * platform/graphics/ShadowBlur.cpp: * platform/graphics/cg/ImageBufferCG.cpp: (WebCore::ImageBuffer::putByteArray): * platform/graphics/cg/PDFDocumentImage.h: * platform/graphics/filters/FETile.cpp: (WebCore::FETile::platformApplySoftware): * platform/graphics/filters/Filter.h: (WebCore::Filter::setSourceImage): * platform/graphics/filters/FilterEffect.cpp: (WebCore::FilterEffect::clearResult): * platform/graphics/filters/FilterEffect.h: * platform/graphics/texmap/TextureMapper.cpp: (WebCore::BitmapTexture::updateContents): * platform/graphics/texmap/TextureMapperImageBuffer.h: * rendering/InlineTextBox.cpp: (WebCore::InlineTextBox::paintDecoration): * rendering/RenderBoxModelObject.cpp: (WebCore::RenderBoxModelObject::paintFillLayerExtended): * rendering/RenderThemeMac.mm: (WebCore::RenderThemeMac::paintProgressBar): * rendering/shapes/Shape.cpp: (WebCore::Shape::createShape): * rendering/svg/RenderSVGImage.cpp: (WebCore::RenderSVGImage::invalidateBufferedForeground): * rendering/svg/RenderSVGImage.h: * rendering/svg/RenderSVGResourceClipper.cpp: (WebCore::RenderSVGResourceClipper::applyClippingToContext): * rendering/svg/RenderSVGResourceClipper.h: * rendering/svg/RenderSVGResourceFilter.cpp: (WebCore::RenderSVGResourceFilter::applyResource): (WebCore::RenderSVGResourceFilter::postApplyResource): * rendering/svg/RenderSVGResourceFilter.h: * rendering/svg/RenderSVGResourceGradient.cpp: Remove method parameter wrapping/indentation. (WebCore::createMaskAndSwapContextForTextGradient): (WebCore::clipToTextMask): (WebCore::RenderSVGResourceGradient::applyResource): * rendering/svg/RenderSVGResourceGradient.h: * rendering/svg/RenderSVGResourceMasker.cpp: (WebCore::RenderSVGResourceMasker::applyResource): * rendering/svg/RenderSVGResourceMasker.h: * rendering/svg/RenderSVGResourcePattern.cpp: Remove method parameter wrapping/indentation. (WebCore::RenderSVGResourcePattern::buildPattern): (WebCore::RenderSVGResourcePattern::createTileImage): * rendering/svg/RenderSVGResourcePattern.h: Remove method parameter wrapping/indentation. * rendering/svg/SVGRenderingContext.cpp: (WebCore::SVGRenderingContext::createImageBuffer): (WebCore::SVGRenderingContext::createImageBufferForPattern): (WebCore::SVGRenderingContext::clipToImageBuffer): (WebCore::SVGRenderingContext::bufferForeground): * rendering/svg/SVGRenderingContext.h: * svg/graphics/SVGImage.cpp: (WebCore::SVGImage::nativeImageForCurrentFrame): (WebCore::SVGImage::drawPatternForContainer): 2013-11-26 Eric Carlson video.currentSrc should return empty when no resource is loaded https://bugs.webkit.org/show_bug.cgi?id=124898 Reviewed by Dan Bernstein. Test: media/video-currentsrc-cleared.html * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::prepareForLoad): Set m_currentSrc to empty in preparation for attempting to load a new url. 2013-11-26 Hans Muller [CSS Shapes] Support for shape-margin in BoxShape https://bugs.webkit.org/show_bug.cgi?id=124788 Reviewed by Andreas Kling. Corrected BoxShape's internal shape-margin/padding bounds FloatRoundedRect initialization. Tests for the padding bounds will be added when the rest of shape-padding for box shapes implementation is ready. Tests: fast/shapes/shape-outside-floats/shape-outside-margin-boxes-001.html fast/shapes/shape-outside-floats/shape-outside-margin-boxes-002.html * rendering/shapes/BoxShape.cpp: Use constructor shape-margin,shape-padding parameters. (WebCore::BoxShape::BoxShape): * rendering/shapes/BoxShape.h: * rendering/shapes/Shape.cpp: (WebCore::createBoxShape): Pass the shape-margin and shape-padding values along to the BoxShape constructor. (WebCore::Shape::createShape): Ditto. 2013-11-26 Nick Diego Yamane Remove unnecessary webaudio include from MediaStreamSource header https://bugs.webkit.org/show_bug.cgi?id=124897 Reviewed by Eric Carlson. AudioDestinationConsumer.h is included but not used anywhere in MediaStreamSource implementation. * platform/mediastream/MediaStreamSource.h: 2013-11-26 Andreas Kling Avoid unnecessary copy-on-write in FillLayer style application. We ended up with a lot of cloned StyleBackgroundData objects on HTML5-8266. This happened because we always forced a copy-on-write when applying background-image:inherit / background-image:initial. This patch adds early returns to both functions. In the "inherit" case, we bail early if the target style already has the same fill layer data as its parent style. In the "initial" case, we optimize for the single-FillLayer case and add an early return if the relevant value is either unset or equal to the templatized initial value. 2.46 MB progression on HTML5-8266 locally. Reviewed by Antti Koivisto. 2013-11-26 Antoine Quint Web Inspector: Allow showing a context menu on all mouse events. https://bugs.webkit.org/show_bug.cgi?id=124747 Reviewed by Joseph Pecoraro. Add a new InspectorFrontendHost::dispatchEventAsContextMenuEvent(Event*) method to let the inspector front-end dispatch a native contextmenu event that will allow for a context menu to be shown from within a non-contextmenu event handler. * inspector/InspectorFrontendHost.cpp: (WebCore::InspectorFrontendHost::dispatchEventAsContextMenuEvent): Check that we're dealing with a mouse event, get the frame for the event target and the event's location to call ContextMenuController::showContextMenuAt() which will handle the new contextmenu event dispatch to the original event target. * inspector/InspectorFrontendHost.h: * inspector/InspectorFrontendHost.idl: 2013-11-25 Sam Weinig Convert some Shape code to use references https://bugs.webkit.org/show_bug.cgi?id=124876 Reviewed by Andreas Kling. * inspector/InspectorOverlay.cpp: * rendering/FloatingObjects.cpp: * rendering/LayoutState.cpp: * rendering/RenderBlock.cpp: * rendering/RenderBlock.h: * rendering/RenderBlockLineLayout.cpp: * rendering/RenderBox.cpp: * rendering/RenderBox.h: * rendering/line/BreakingContextInlineHeaders.h: * rendering/line/LineWidth.cpp: * rendering/shapes/ShapeInfo.cpp: * rendering/shapes/ShapeInfo.h: * rendering/shapes/ShapeInsideInfo.cpp: * rendering/shapes/ShapeInsideInfo.h: * rendering/shapes/ShapeOutsideInfo.cpp: * rendering/shapes/ShapeOutsideInfo.h: Replace yet more pointers with references. 2013-11-25 Simon Pena [EFL] X11Helper::createPixmap doesn't initialise out value handleId https://bugs.webkit.org/show_bug.cgi?id=124722 Reviewed by Gyuyoung Kim. The overloaded functions X11Helper::createPixmap don't initialise out value handleId, and they do early returns on error situations. Since the functions are void and they don't communicate their failure in any way, returning an out value without initialising it could make the error go farther unnoticed. With the variable being initialised, it can be reliably checked for errors when the function returns. * platform/graphics/surfaces/glx/X11Helper.cpp: (WebCore::X11Helper::createPixmap): Initialise handleId to 0. 2013-11-25 Nick Diego Yamane Mark URLRegistry's lookup() as const and its child classes as final https://bugs.webkit.org/show_bug.cgi?id=124865 Reviewed by Eric Carlson. No new tests needed. No behavior changes. * Modules/mediasource/MediaSourceRegistry.cpp: (WebCore::MediaSourceRegistry::lookup): marked as const. * Modules/mediasource/MediaSourceRegistry.h: MediaSourceRegistry marked as final. * Modules/mediastream/MediaStreamRegistry.cpp: (WebCore::MediaStreamRegistry::lookup): marked as const. * Modules/mediastream/MediaStreamRegistry.h: MediaStreamRegistry marked as final. * fileapi/Blob.cpp: * html/URLRegistry.h: lookup() marked as const. (WebCore::URLRegistry::lookup): marked as const. 2013-11-25 Sergio Correia [MediaStream] Use std::unique_ptr instead of OwnPtr/PassOwnPtr https://bugs.webkit.org/show_bug.cgi?id=124858 Reviewed by Eric Carlson. Another step of the OwnPtr/PassOwnPtr => std::unique_ptr conversion, now targeting mediastream-related code. No new tests, covered by existing ones. * Modules/mediastream/RTCDTMFSender.cpp: * Modules/mediastream/RTCDTMFSender.h: * Modules/mediastream/RTCDataChannel.cpp: * Modules/mediastream/RTCDataChannel.h: * Modules/mediastream/RTCPeerConnection.cpp: * Modules/mediastream/RTCPeerConnection.h: * platform/mediastream/MediaStreamSource.cpp: * platform/mediastream/RTCPeerConnectionHandler.cpp: * platform/mediastream/RTCPeerConnectionHandler.h: * platform/mediastream/RTCPeerConnectionHandlerClient.h: * platform/mock/RTCNotifiersMock.cpp: * platform/mock/RTCPeerConnectionHandlerMock.cpp: * platform/mock/RTCPeerConnectionHandlerMock.h: 2013-11-25 Nick Diego Yamane MediaStreamRegistry should store MediaStreams instead of MediaStreamPrivates https://bugs.webkit.org/show_bug.cgi?id=124860 Reviewed by Eric Carlson. MediaStreamRegistry::lookup() should return a MediaStream instead of MediaStreamPrivate. No new tests needed. No behavior changes. * Modules/mediastream/MediaStreamRegistry.cpp: (WebCore::MediaStreamRegistry::registerURL): m_privateStreams -> m_mediaStreams (WebCore::MediaStreamRegistry::unregisterURL): Ditto. (WebCore::MediaStreamRegistry::lookup): Override URLRegistry::lookup() instead of add a new method MediaStream::lookupMediaStreamPrivate(). * Modules/mediastream/MediaStreamRegistry.h: * html/HTMLMediaElement.cpp: (HTMLMediaElement::loadResource): call lookup() instead of lookupMediaStreamPrivate() 2013-11-25 peavo@outlook.com [WinCairo] Compile fails when GSTREAMER is not used. https://bugs.webkit.org/show_bug.cgi?id=124853 Reviewed by Philippe Normand. * platform/graphics/gstreamer/GStreamerUtilities.cpp: Don't include GStreamerUtilities.h when GSTREAMER is not used. 2013-11-25 Andreas Kling Deduplicate shortish Text node strings during tree construction. Let HTMLConstructionSite keep a hash set of already seen strings over its lifetime. Use this to deduplicate the strings inside Text nodes for any string up to 64 characters of length. This optimization already sort-of existed for whitespace-only Texts, but those are laundered in the AtomicString table which we definitely don't want to pollute with every single Text. It might be a good idea to stop using the AtomicString table for all-whitespace Text too. 3.82 MB progression on HTML5-8266 locally. Reviewed by Anders Carlsson. 2013-11-25 Nick Diego Yamane Remove unnecessary MediaStreamTrackDescriptor forward declaration https://bugs.webkit.org/show_bug.cgi?id=124854 Reviewed by Eric Carlson. No new tests needed. No behavior changed. * Modules/mediastream/VideoStreamTrack.h: 2013-11-25 Robert Hogan Remove code now unnecessary after r159575 https://bugs.webkit.org/show_bug.cgi?id=124809 Reviewed by Antti Koivisto. Covered by existing tests fast/block/margin-collapse/self-collapsing-block-with-float* * rendering/line/LineBreaker.cpp: (WebCore::LineBreaker::skipLeadingWhitespace): 2013-11-25 Laszlo Vidacs Vertical border spacing is doubled between table row groups https://bugs.webkit.org/show_bug.cgi?id=20040 Reviewed by Csaba Osztrogonác. Based on Chromium fix https://chromium.googlesource.com/chromium/blink/+/eb615069267f895c59bc576f9d65b3fa5add41e9 Rebaseline needed for table related tests (100+). * rendering/RenderTableSection.cpp: (WebCore::RenderTableSection::calcRowLogicalHeight): 2013-11-25 Andres Gomez [GStreamer] Seeking fails on media content provided by servers not supporting Range requests https://bugs.webkit.org/show_bug.cgi?id=85994 Reviewed by Philippe Normand. Based on the patch written by Andre Moreira Magalhaes. When the GStreamer web source was doing a "Range" request we were expecting to receive a 206 status reply with the "Content-Range" header and just the requested data. Supporting "Range" requests is not mandatory so, for the servers not supporting it they will be replying with a 200 status and the whole content of the media element. Now, we are properly handling these replies too. Test: http/tests/media/media-seeking-no-ranges-server.html * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp: (StreamingClient::handleResponseReceived): Do not fail when receiving 200 as response for HTTP range requests. (StreamingClient::handleDataReceived): Manually seek on stream when receiving the full data after a seek. 2013-11-25 Radu Stavila Removed obsolete FIXME after the landing of visual overflow patch (https://bugs.webkit.org/show_bug.cgi?id=118665). https://bugs.webkit.org/show_bug.cgi?id=124833 Reviewed by Mihnea Ovidenie. * rendering/RenderRegion.cpp: (WebCore::RenderRegion::layoutBlock): 2013-11-18 Sergio Villar Senin [CSS Grid Layout] Cache several vectors to avoid malloc/free churn https://bugs.webkit.org/show_bug.cgi?id=123995 Reviewed by Dean Jackson. From Blink r158228 by Laying-out the grid items means a lot of calls to distributeSpaceToTracks() and resolveContentBasedTrackSizingFunctionsForItems() as they're called in a loop. This means that there is a lot of malloc/free going on there. By moving the vectors used by these methods to a new class which is kept during the whole layout process we save a lot of those calls. This obviously mean that the price we pay for a significant perfomance improvement is that we keep the maximum allocation till the end of each layout, but it's an amount of memory that we have to allocate anyway. The improvement in the auto-grid-lots-of-data.html perf test is ~24% (165 runs/s vs 207 runs/s). No new tests required as we're just refactoring code to a new helper class. Nevertheless the performance improvement is backed by the perf test mentioned above. * rendering/RenderGrid.cpp: (WebCore::RenderGrid::GridSizingData::GridSizingData): (WebCore::RenderGrid::computedUsedBreadthOfGridTracks): (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctions): (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForItems): (WebCore::RenderGrid::distributeSpaceToTracks): (WebCore::RenderGrid::layoutGridItems): (WebCore::RenderGrid::findChildLogicalPosition): * rendering/RenderGrid.h: 2013-11-24 Brady Eidson DatabaseProcess: Add "UniqueIDBDatabase" that multiple WebProcesses can connect to https://bugs.webkit.org/show_bug.cgi?id=124819 Reviewed by Dan Bernstein. * Modules/indexeddb/IDBDatabaseBackend.cpp: (WebCore::IDBDatabaseBackend::~IDBDatabaseBackend): Unregister from the IDBFactory. 2013-11-24 Gyuyoung Kim Generate toHTMLMarquee|OListElement() to cleanup static_cast<> https://bugs.webkit.org/show_bug.cgi?id=124707 Reviewed by Darin Adler. As a step to use toFoo(), we need to generate toHTMLMarquee|OListElement(). Besides this patch cleans up remaining static_cast<> usage. No new tests, no behavior changes. * css/StyleResolver.cpp: (WebCore::StyleResolver::State::initElement): (WebCore::StyleResolver::locateCousinList): (WebCore::StyleResolver::findSiblingForStyleSharing): * dom/Attr.cpp: (WebCore::Attr::style): * dom/Element.cpp: (WebCore::Element::removeAttribute): * editing/ApplyStyleCommand.cpp: (WebCore::ApplyStyleCommand::removeEmbeddingUpToEnclosingBlock): (WebCore::ApplyStyleCommand::pushDownInlineStyleAroundNode): * editing/EditingStyle.cpp: (WebCore::EditingStyle::wrappingStyleForSerialization): * editing/Editor.cpp: (WebCore::Editor::applyEditingStyleToElement): * editing/ReplaceSelectionCommand.cpp: (WebCore::ReplaceSelectionCommand::removeRedundantStylesAndKeepStyleSpanInline): * html/HTMLMarqueeElement.h: * html/HTMLOListElement.h: * html/HTMLTagNames.in: * inspector/InspectorCSSAgent.cpp: (WebCore::InspectorCSSAgent::buildObjectForAttributesStyle): * inspector/InspectorOverlay.cpp: (WebCore::buildObjectForElementInfo): * page/PageSerializer.cpp: (WebCore::PageSerializer::serializeFrame): * rendering/RenderCounter.cpp: (WebCore::planCounter): * rendering/RenderLayer.cpp: (WebCore::RenderLayer::resize): * rendering/RenderListItem.cpp: (WebCore::RenderListItem::calcValue): (WebCore::RenderListItem::updateListMarkerNumbers): * rendering/RenderMarquee.cpp: (WebCore::RenderMarquee::marqueeSpeed): 2013-11-24 Tim Horton REGRESSION (r156291): TileController tiles don't always repaint when they resize https://bugs.webkit.org/show_bug.cgi?id=124796 Reviewed by Simon Fraser. In removing platformCALayerDidCreateTiles, r156291 also removed the call to setNeedsDisplay when tiles are resized, without putting it somewhere else. * platform/graphics/ca/mac/TileController.mm: (WebCore::TileController::setNeedsDisplay): Use hasStaleContent when invalidating a whole tile, just like we do for partial tile repaints. (WebCore::TileController::setTileNeedsDisplayInRect): Mark hasStaleContent for any unparented layers, so they'll be painted when they are reparented. (WebCore::TileController::ensureTilesForRect): Invalidate the whole tile when it changes size. 2013-11-23 Xabier Rodriguez Calvar [GStreamer] Remove 0.10 codepath https://bugs.webkit.org/show_bug.cgi?id=124534 Reviewed by Philippe Normand. All GStreamer ports are using 1.0 now so we remove the 0.10 codepath. * GNUmakefile.list.am: * PlatformEfl.cmake: * PlatformGTK.cmake: * WebCore.vcxproj/WebCore.vcxproj: * WebCore.vcxproj/WebCore.vcxproj.filters: Removed GStreamerVersioning. * platform/audio/gstreamer/AudioDestinationGStreamer.cpp: (onGStreamerWavparsePadAddedCallback): Removed. (WebCore::AudioDestinationGStreamer::AudioDestinationGStreamer): Replaced webkitGstPipelineGetBus and removed 0.10 codepath. (WebCore::AudioDestinationGStreamer::~AudioDestinationGStreamer): Replaced webkitGstPipelineGetBus. * platform/audio/gstreamer/AudioFileReaderGStreamer.cpp: (WebCore::copyGstreamerBuffersToAudioChannel): (WebCore::onAppsinkPullRequiredCallback): Removed 0.10 codepath. (WebCore::AudioFileReader::~AudioFileReader): Replaced webkitGstPipelineGetBus and removed 0.10 codepath. (WebCore::AudioFileReader::handleSample): Left as only codepath. (WebCore::AudioFileReader::handleBuffer): Removed. (WebCore::AudioFileReader::handleNewDeinterleavePad): Removed 0.10 codepath. (WebCore::AudioFileReader::plugDeinterleave): Replaced getGstAudioCaps. (WebCore::AudioFileReader::decodeAudioForBusCreation): Replaced webkitGstPipelineGetBus. (WebCore::AudioFileReader::createBus): Removed 0.10 codepath. * platform/audio/gstreamer/WebKitWebAudioSourceGStreamer.cpp: (getGStreamerMonoAudioCaps): (webKitWebAudioGStreamerChannelPosition): Removed 0.10 codepath. (webkit_web_audio_src_class_init): Replaced setGstElementClassMetadata. (webkit_web_audio_src_init): (webKitWebAudioSrcConstructed): (webKitWebAudioSrcFinalize): (webKitWebAudioSrcLoop): Removed 0.10 codepath. * platform/graphics/gstreamer/AudioTrackPrivateGStreamer.cpp: * platform/graphics/gstreamer/AudioTrackPrivateGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/GRefPtrGStreamer.cpp: (WTF::GstElement): (WTF::GstPad): (WTF::GstPadTemplate): (WTF::GstTask): (WTF::GstBus): (WTF::GstElementFactory): (WTF::adoptGRef): Replaced gstObjectIsFloating. (WTF::refGRef): Replaced webkitGstObjectRefSink. (WTF::GstTagList): (WTF::GstSample): Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/GRefPtrGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/GStreamerUtilities.cpp: (WebCore::webkitGstGhostPadFromStaticTemplate): (WebCore::getVideoSizeAndFormatFromCaps): (WebCore::createGstBuffer): (WebCore::createGstBufferForData): (WebCore::getGstBufferDataPointer): (WebCore::mapGstBuffer): (WebCore::unmapGstBuffer): Moved here from GstVersioning and added to WebCore namespace. * platform/graphics/gstreamer/GStreamerUtilities.h: (WebCore::webkitGstCheckVersion): Moved here from GstVersioning and added to WebCore namespace. * platform/graphics/gstreamer/GStreamerVersioning.cpp: Removed. * platform/graphics/gstreamer/GStreamerVersioning.h: Removed. * platform/graphics/gstreamer/ImageGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/ImageGStreamerCairo.cpp: (ImageGStreamer::ImageGStreamer): Removed 0.10 codepath. (ImageGStreamer::~ImageGStreamer): Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/InbandMetadataTextTrackPrivateGStreamer.h: * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.cpp: * platform/graphics/gstreamer/InbandTextTrackPrivateGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp: (WebCore::setAudioStreamPropertiesCallback): Removed 0.10 codepath. (WebCore::mediaPlayerPrivateTextChangedCallback): Removed checks for 1.0 as it is the only codepath now. (WebCore::MediaPlayerPrivateGStreamer::isAvailable): Replaced gPlaybinName. (WebCore::MediaPlayerPrivateGStreamer::~MediaPlayerPrivateGStreamer): Removed checks for 1.0 and replaced webkitGstPipelineGetBus. (WebCore::MediaPlayerPrivateGStreamer::duration): Removed 0.10 codepath. (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfVideo): (WebCore::MediaPlayerPrivateGStreamer::notifyPlayerOfAudio): (WebCore::MediaPlayerPrivateGStreamer::textChanged): Removed checks for 1.0 as it is the only codepath now. (WebCore::MediaPlayerPrivateGStreamer::buffered): Replaced gPercentMax. (WebCore::MediaPlayerPrivateGStreamer::handleMessage): Removed 0.10 codepath. (WebCore::MediaPlayerPrivateGStreamer::processTableOfContents): Removed checks for 1.0 as it is the only codepath now. (WebCore::MediaPlayerPrivateGStreamer::totalBytes): Removed 0.10 codepath. (WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin): Replaced gPlaybinName and webkitGstPipelineGetBus and removed checks for 1.0. * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: (WebCore::MediaPlayerPrivateGStreamerBase::naturalSize): (WebCore::MediaPlayerPrivateGStreamerBase::updateTexture): (WebCore::MediaPlayerPrivateGStreamerBase::paint): Removed 0.10 codepath. * platform/graphics/gstreamer/TextCombinerGStreamer.cpp: * platform/graphics/gstreamer/TextCombinerGStreamer.h: * platform/graphics/gstreamer/TextSinkGStreamer.cpp: * platform/graphics/gstreamer/TextSinkGStreamer.h: * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.cpp: * platform/graphics/gstreamer/TrackPrivateBaseGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/VideoSinkGStreamer.cpp: (webkitVideoSinkRender): Removed 0.10 codepath and added WebCore as createGstBuffer namespace. (webkitVideoSinkSetCaps): Removed 0.10 codepath. (webkitVideoSinkProposeAllocation): Removed checks for 1.0 as it is the only codepath now. (webkitVideoSinkMarshalVoidAndMiniObject): Removed as it was 0.10. (webkit_video_sink_class_init): Removed 0.10 codepath and replaced setGstElementClassMetadata. * platform/graphics/gstreamer/VideoTrackPrivateGStreamer.cpp: * platform/graphics/gstreamer/VideoTrackPrivateGStreamer.h: Removed checks for 1.0 as it is the only codepath now. * platform/graphics/gstreamer/WebKitMediaSourceGStreamer.cpp: (webkit_media_src_class_init): Replaced setGstElementClassMetadata. (webKitMediaSrcAddSrc): Added WebCore namespace to webkitGstGhostPadFromStaticTemplate. (MediaSourceClientGstreamer::didReceiveData): Added WebCore namespace to createGstBufferForData. * platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp: Removed 0.10 codepath. (webKitWebSrcQuery): Removed as it was 0.10 only. (void webkit_web_src_class_init): Replaced setGstElementClassMetadata. (webkit_web_src_init): Removed haveAppSrc27 private attribute and 0.10 codepath. (webKitWebSrcStop): Removed checks for 1.0 as it is the only codepath now. (webKitWebSrcSetProperty): (webKitWebSrcUriGetType): (webKitWebSrcGetProtocols): (webKitWebSrcGetUri): (webKitWebSrcSetUri): Removed 0.10 codepath. (StreamingClient::createReadBuffer): Removed checks for 1.0 and replaced getGstBufferSize. (StreamingClient::handleResponseReceived): Removed 0.10 codepath and replaced notifyGstTagsOnPad. (StreamingClient::handleDataReceived): Removed 0.10 codepath and replaced setGstBufferSize and gst_buffer_get_size. 2013-11-22 Jer Noble [Mac] Can't drag full-screen video to another monitor https://bugs.webkit.org/show_bug.cgi?id=124798 Reviewed by Geoffrey Garen. Make full screen windows movable by default. Previously, we wanted non-movable full screen windows since they were in the same space and were just placed atop non-full screen windows. Now that all our supported Mac platforms have explicit full screen support, we can remove this non-movable restriction. * platform/mac/WebCoreFullScreenWindow.mm: (-[WebCoreFullScreenWindow initWithContentRect:styleMask:backing:defer:]): 2013-11-22 Brent Fulgham [Win] Clean up ColorSpace handling in Windows code https://bugs.webkit.org/show_bug.cgi?id=124795 Reviewed by Tim Horton. Functionality covered by existing fast/css/color test suite. * platform/graphics/cg/GraphicsContextCG.cpp: (WebCore::safeRGBColorSpaceRef): Handle case of Windows CG implementation not handling sRGB correctly. (WebCore::sRGBColorSpaceRef): Use new helper function. * platform/graphics/win/FontCGWin.cpp: (WebCore::Font::drawGlyphs): Pass correct color space to fill functions. * platform/graphics/win/GraphicsContextCGWin.cpp: (WebCore::GraphicsContext::platformInit): Initialize color space to value passed via the style to the constructor. 2013-11-22 Alexey Proskuryakov WebCrypto algorithms should check that key algorithm matches https://bugs.webkit.org/show_bug.cgi?id=123628 Reviewed by Anders Carlsson. No change in behavior yet, because we have one algorithm per key class. Will be tested once more algorithms are added. * WebCore.xcodeproj/project.pbxproj: Updated for file renames. * bindings/js/JSCryptoAlgorithmDictionary.cpp: (WebCore::createRsaKeyParamsWithHash): (WebCore::JSCryptoAlgorithmDictionary::createParametersForImportKey): * bindings/js/JSCryptoKeySerializationJWK.cpp: (WebCore::createRSAKeyParametersWithHash): (WebCore::JSCryptoKeySerializationJWK::reconcileAlgorithm): * crypto/CryptoAlgorithmParameters.h: (WebCore::CryptoAlgorithmParameters::ENUM_CLASS): * crypto/parameters/CryptoAlgorithmRsaKeyParamsWithHash.h: Copied from Source/WebCore/crypto/parameters/CryptoAlgorithmRsaSsaKeyParams.h. * crypto/parameters/CryptoAlgorithmRsaSsaKeyParams.h: Removed. Renamed RsaSsaKeyParams to RsaKeyParamsWithHash, because other algorithms (like RSA-OAEP) are in the same boat. Depending on where the spec goes, we might need to introduce algorithm specific RSA parameter classes later, but let's reduce copy/pasted code at least for now. * crypto/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: Moved to the correct directory. * crypto/mac/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp: Copied from Source/WebCore/crypto/CryptoAlgorithmRSASSA_PKCS1_v1_5Mac.cpp. (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformSign): Factored out Mac specific code, leaving type casting to cross-platform files. (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::platformVerify): Ditto. * crypto/CryptoAlgorithmRegistry.h: (WebCore::CryptoAlgorithmRegistry::registerAlgorithm): * crypto/mac/CryptoAlgorithmRegistryMac.cpp: (WebCore::CryptoAlgorithmRegistry::platformRegisterAlgorithms): Reduce copy/pasting in registration code. * crypto/algorithms/CryptoAlgorithmAES_CBC.cpp: (WebCore::CryptoAlgorithmAES_CBC::keyAlgorithmMatches): Check key type and algorithm. (WebCore::CryptoAlgorithmAES_CBC::encrypt): Cross platform type casting code. Maybe we'll find a way to autogenerate or eliminate it one day. (WebCore::CryptoAlgorithmAES_CBC::decrypt): Ditto. * crypto/algorithms/CryptoAlgorithmAES_CBC.h: * crypto/algorithms/CryptoAlgorithmHMAC.cpp: (WebCore::CryptoAlgorithmHMAC::keyAlgorithmMatches): (WebCore::CryptoAlgorithmHMAC::sign): (WebCore::CryptoAlgorithmHMAC::verify): * crypto/algorithms/CryptoAlgorithmHMAC.h: * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.cpp: (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::keyAlgorithmMatches): (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::sign): (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::verify): (WebCore::CryptoAlgorithmRSASSA_PKCS1_v1_5::importKey): * crypto/algorithms/CryptoAlgorithmRSASSA_PKCS1_v1_5.h: * crypto/mac/CryptoAlgorithmAES_CBCMac.cpp: (WebCore::CryptoAlgorithmAES_CBC::platformEncrypt): (WebCore::CryptoAlgorithmAES_CBC::platformDecrypt): * crypto/mac/CryptoAlgorithmHMACMac.cpp: (WebCore::CryptoAlgorithmHMAC::platformSign): (WebCore::CryptoAlgorithmHMAC::platformVerify): Same changes for all algorithms that have keys. 2013-11-22 Brendan Long Fire "change" event on TextTrackList when a TextTrack's mode changes https://bugs.webkit.org/show_bug.cgi?id=124789 Reviewed by Eric Carlson. Since AudioTrackList and VideoTrackList already have this event, the interesting bits are in TrackListBase::scheduleChangeEvent(), and we just need to call it for TextTrackList changes. Test: media/track/track-change-event.html * html/HTMLMediaElement.cpp: (HTMLMediaElement::textTrackModeChanged): Call TrackListBase::scheduleChangeEvent(). * html/track/TextTrackList.idl: Add onchange event listener. 2013-11-22 Brendan Long Add TextTrackList::getTrackById(). https://bugs.webkit.org/show_bug.cgi?id=124785 Reviewed by Eric Carlson. Test: media/track/track-id.html * html/track/TextTrackList.cpp: Add getTrackById() (TextTrackList::getTrackById): * html/track/TextTrackList.h: Same. * html/track/TextTrackList.idl: Same. 2013-11-22 Hans Muller [CSS Shapes] When the value is set, derive radii from border-radius https://bugs.webkit.org/show_bug.cgi?id=124228 Reviewed by Dean Jackson. Add support for BoxShape elliptical corners. Tests: fast/shapes/shape-outside-floats/shape-outside-rounded-boxes-001.html fast/shapes/shape-outside-floats/shape-outside-rounded-boxes-002.html * platform/graphics/FloatRoundedRect.h: (WebCore::FloatRoundedRect::bottomLeftCorner): Corrected a copy-and-pasteO. * rendering/shapes/BoxShape.cpp: (WebCore::BoxShape::getExcludedIntervals): Returned interval now depends on the top and bottom of the line. * rendering/shapes/Shape.cpp: (WebCore::Shape::createShape): Rounded rect parameters are now specified with a RoundedRect parameter. * rendering/shapes/Shape.h: * rendering/shapes/ShapeInfo.cpp: (WebCore::::computedShape): Pass style's rounded border to createShape(). 2013-11-22 Andres Gomez Several missing/incorrect guards for LOG_DISABLED=0 against Release build (Mac) https://bugs.webkit.org/show_bug.cgi?id=78735 Reviewed by Mario Sanchez Prada. In a "Debug" build the CString.h header comes from another indirect dependency. Now, we explicitly add this missing include. * page/CaptionUserPreferencesMediaAF.cpp: Explicitly adding missing include. 2013-11-22 Robert Sipka [curl] Fix of SSL certificate chain storage https://bugs.webkit.org/show_bug.cgi?id=124768 Reviewed by Brent Fulgham. Change the certificates storage type into ListHashSet from HashSet to keep the chain order in each case. This ensures that there is no difference between the stored and the recieved certificate chain. * platform/network/curl/SSLHandle.cpp: (WebCore::allowsAnyHTTPSCertificateHosts): (WebCore::sslIgnoreHTTPSCertificate): (WebCore::pemData): (WebCore::certVerifyCallback): 2013-11-22 Brent Fulgham [Win] Avoid deadlock when interacting with some AVFoundationCF content and https://bugs.webkit.org/show_bug.cgi?id=124752 Prevent deadlock caused by conflict over the "mapLock" mutex. Notification handling in the file, which modify assets and make other changes, are required to happen on the main thread. This patch enforces this requirement. Reviewed by Eric Carlson. * platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp: (WebCore::NotificationCallbackData::NotificationCallbackData): Added (WebCore::AVFWrapper::processNotification): Moved logic from 'notificationCallback', which was sometimes happening on a background thread. (WebCore::AVFWrapper::notificationCallback): Dispatch calls to main thread. 2013-11-22 peavo@outlook.com [WinCairo] Compile error when ACCELERATED_COMPOSITING is not used. https://bugs.webkit.org/show_bug.cgi?id=124773 Reviewed by Brent Fulgham. * rendering/RenderView.cpp: (WebCore::RenderView::paintBoxDecorations): Added USE(ACCELERATED_COMPOSITING) guard. 2013-11-18 Sergio Villar Senin [CSS Grid Layout] Improve content-sized track layout https://bugs.webkit.org/show_bug.cgi?id=124408 Reviewed by Dean Jackson. Test: fast/css-grid-layout/grid-item-with-percent-min-max-height-dynamic.html From Blink r156122 & r157633 by Added a couple of optimizations to speed up the layout of content based tracks. The idea is to narrow down the conditions for relayouting when the height of a grid area changes. We basically just need to layout tracks with percentage heights as they're the only ones that change. A new performance test is attached to demonstrate the effect of these optimizations. We get a ~1000% improvement on a i7 M620 going from 14.5 runs/s to 165 runs/s. * rendering/RenderGrid.cpp: (WebCore::RenderGrid::logicalContentHeightForChild): (WebCore::RenderGrid::layoutGridItems): 2013-11-08 Sergio Villar Senin [CSS Grid Layout] Run the content-sized tracks sizing algorithm only when required https://bugs.webkit.org/show_bug.cgi?id=124039 Reviewed by Dean Jackson. The current code runs the content sized track sizing algorithm all the time, which forces a layout even when the track is not content-sized. This change improves the situation by applying two optimizations. In the first one, we bail out the algorithm if we detect that we don't need to run it. And by the second one we reduce the amount of recomputations by only iterating over the content sized tracks instead of all of them. Both changes follow the ideas introduced in Blink r156028 and r156168 by . As we changed the way we iterate over children (we use the GridIterator now) the way they're stored in the RenderGrid changes too. If a item spans through several "cells" inside the grid, we will have a reference to it on each of them. These two changes account for a ~3200% improvement on a i7 M620 in the test that accompanies this change (15.5 vs 520 run/s). New perf test: PerformanceTests/Layout/fixed-grid-lots-of-data.html * rendering/RenderGrid.cpp: (WebCore::RenderGrid::computedUsedBreadthOfGridTracks): Keep track of content sized tracks and only iterate over them. (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctions): (WebCore::RenderGrid::resolveContentBasedTrackSizingFunctionsForItems): Early return if there are no tracks to pass to the algorithm. * rendering/RenderGrid.h: * rendering/style/GridLength.h: (WebCore::GridLength::isContentSized): * rendering/style/GridTrackSize.h: (WebCore::GridTrackSize::isContentSized): 2013-11-22 Manuel Rego Casasnovas [CSS Regions] Move code after early break in RenderRegion::repaintFlowThreadContentRectangle https://bugs.webkit.org/show_bug.cgi?id=124743 Reviewed by Mihnea Ovidenie. No new tests, covered by existing tests. * rendering/RenderRegion.cpp: (WebCore::RenderRegion::repaintFlowThreadContentRectangle): Variable flippedFlowThreadPortionRect is not used before the early break, so we can move it after and save some unneeded operations. 2013-11-22 Manuel Rego Casasnovas [CSS Regions] Use hasOverflowClip() in RenderRegion https://bugs.webkit.org/show_bug.cgi?id=124746 Reviewed by Mihnea Ovidenie. Implement the suggested FIXME in RenderRegion using hasOverflowClip(). No new tests, covered by existing tests. * rendering/RenderRegion.cpp: (WebCore::RenderRegion::overflowRectForFlowThreadPortion): Use hasOverflowClip(). (WebCore::RenderRegion::rectFlowPortionForBox): Ditto. 2013-11-21 Frédéric Wang Map the dir attribute to the CSS direction property. https://bugs.webkit.org/show_bug.cgi?id=124572. Reviewed by Darin Adler. Test: mathml/presentation/mstyle-css-attributes.html * mathml/MathMLElement.cpp: (WebCore::MathMLElement::isPresentationAttribute): reorder attributes (WebCore::MathMLElement::collectStyleForPresentationAttribute): reorder tags that accept dir (WebCore::MathMLElement::isMathMLToken): add an inline function to test that a tag corresponds to a MathML Token Element. * mathml/MathMLElement.h: Follow-up work to address Darin's comments. 2013-11-21 Peter Molnar Remove ENABLE_WORKERS https://bugs.webkit.org/show_bug.cgi?id=105784 Reviewed by Darin Adler. 2013-11-21 Alex Christensen [Win] Unreviewed build fix after r159632. * platform/network/curl/SSLHandle.cpp: (WebCore::certVerifyCallback): Fixed template syntax. 2013-11-21 Bear Travis Web Inspector: [CSS Shapes] Refactor highlighting code to decrease Shapes API surface https://bugs.webkit.org/show_bug.cgi?id=124737 Reviewed by Timothy Hatcher. Add a virtual method to Shapes, buildPath, that can be used to build the path (in the Shape coordinate system) for display in the Inspector. This allows us to remove methods such as type(), polygon(), and logicalRx/Ry() which exposed the inner workings of the Shapes classes. Also covers the addition of the BoxShape type. Refactoring, existing test is inspector-protocol/model/highlight-shape-outside.html. * inspector/InspectorOverlay.cpp: (WebCore::appendPathCommandAndPoints): Points need to be translated from shape space to renderer space using ShapeInfo. (WebCore::buildObjectForShapeOutside): Add the ShapeOutsideInfo to the path info struct. * rendering/shapes/BoxShape.cpp: (WebCore::BoxShape::buildPath): Build the path for a BoxShape. * rendering/shapes/BoxShape.h: * rendering/shapes/PolygonShape.cpp: (WebCore::PolygonShape::buildPath): Build the path for a PolygonShape. * rendering/shapes/PolygonShape.h: * rendering/shapes/RasterShape.h: * rendering/shapes/RectangleShape.cpp: (WebCore::RectangleShape::buildPath): Build the path for a RectangleShape. * rendering/shapes/RectangleShape.h: * rendering/shapes/Shape.h: 2013-11-21 Mark Rowe Stop overriding VALID_ARCHS. All modern versions of Xcode set it appropriately for our needs. Reviewed by Alexey Proskuryakov. * Configurations/Base.xcconfig: 2013-11-21 Gwang Yoon Hwang [GTK] Unreviewed buildfix after r159614 and r159656. * bindings/gobject/WebKitDOMCustom.cpp: Add missing header 2013-11-21 Laszlo Vidacs Fix WinCairo unreachable code warnings in SimpleLineLayout.cpp https://bugs.webkit.org/show_bug.cgi?id=124704 Reviewed by Antti Koivisto. Fix unreachable code warnings using conditional directives. * rendering/SimpleLineLayout.cpp: (WebCore::SimpleLineLayout::canUseFor): 2013-11-21 Mark Rowe Fix an error in a few Xcode configuration setting files. Reviewed by Alexey Proskuryakov. * Configurations/Base.xcconfig: 2013-11-21 Mark Rowe Fix some deprecation warnings. Reviewed by Anders Carlsson. * platform/mac/HTMLConverter.mm: (fileWrapperForURL): Move off a deprecated NSFileWrapper method. 2013-11-21 Daniel Bates [iOS] Build fix; export symbol for WebCore::provideDeviceOrientationTo() Add the symbol __ZN7WebCore26provideDeviceOrientationToEPNS_4PageEPNS_23DeviceOrientationClientE. * WebCore.exp.in: 2013-11-21 Daniel Bates Add !USE(NETWORK_CFDATA_ARRAY_CALLBACK)-guard https://bugs.webkit.org/show_bug.cgi?id=124741 Reviewed by Alexey Proskuryakov. Add !USE(NETWORK_CFDATA_ARRAY_CALLBACK)-guard around code that is unused when building with feature NETWORK_CFDATA_ARRAY_CALLBACK. Additionally, add a declaration for allocateSegment() with attribute WARN_UNUSED_RETURN to have the compiler warn when the return value of this function is unused. Together with warnings treated as errors this change will prevent a memory leak. * platform/SharedBuffer.cpp: 2013-11-21 Daniel Bates Remove unused functions from WebCore and WebKit2 https://bugs.webkit.org/show_bug.cgi?id=124739 Reviewed by Alexey Proskuryakov. * editing/markup.cpp: Remove unused functions isHTMLBlockElement and ancestorToRetainStructureAndAppearanceWithNoRenderer. * rendering/InlineElementBox.cpp: Append newline to the end of the file. 2013-11-21 Daniel Bates Only generate isObservable() when IDL specifies GenerateIsReachable https://bugs.webkit.org/show_bug.cgi?id=124729 Reviewed by Geoffrey Garen. We should only generate the static inline function isObservable() when the IDL specifies GenerateIsReachable. Otherwise, this function is unused. Added a new test IDL TestGenerateIsReachable.idl and expected results to test that we generate isObservable() when an IDL specifies GenerateIsReachable. Additionally, rebased existing test results. * bindings/scripts/CodeGeneratorJS.pm: (GenerateImplementation): * bindings/scripts/test/CPP/WebDOMTestGenerateIsReachable.cpp: Added. * bindings/scripts/test/CPP/WebDOMTestGenerateIsReachable.h: Added. * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.cpp: Added. * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachable.h: Added. * bindings/scripts/test/GObject/WebKitDOMTestGenerateIsReachablePrivate.h: Added. * bindings/scripts/test/JS/JSTestActiveDOMObject.cpp: Removed unused function isObservable(). * bindings/scripts/test/JS/JSTestCustomNamedGetter.cpp: Ditto. * bindings/scripts/test/JS/JSTestEventConstructor.cpp: Ditto. * bindings/scripts/test/JS/JSTestEventTarget.cpp: Ditto. * bindings/scripts/test/JS/JSTestException.cpp: Ditto. * bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp: Added. * bindings/scripts/test/JS/JSTestGenerateIsReachable.h: Added. * bindings/scripts/test/JS/JSTestInterface.cpp: Removed unused function isObservable(). * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp: Ditto. * bindings/scripts/test/JS/JSTestNamedConstructor.cpp: Ditto. * bindings/scripts/test/JS/JSTestObj.cpp: Ditto. * bindings/scripts/test/JS/JSTestOverloadedConstructors.cpp: Ditto. * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp: Ditto. * bindings/scripts/test/JS/JSTestTypedefs.cpp: Ditto. * bindings/scripts/test/JS/JSattribute.cpp: Ditto. * bindings/scripts/test/JS/JSreadonly.cpp: Ditto. * bindings/scripts/test/ObjC/DOMTestGenerateIsReachable.h: Added. * bindings/scripts/test/ObjC/DOMTestGenerateIsReachable.mm: Added. * bindings/scripts/test/ObjC/DOMTestGenerateIsReachableInternal.h: Added. * bindings/scripts/test/TestGenerateIsReachable.idl: Added. 2013-11-21 Beth Dakin Add a new mode to extend the tile cache beyond the page https://bugs.webkit.org/show_bug.cgi?id=124216 Reviewed by Simon Fraser. This patch makes it possible to give the tile cache a margin of tiles. If there is a margin of tiles, this patch paints those tiles with the background color. Note that this patch does not actually give the tile cache a margin at this time. You opt into a margined tiled cache by called setTileMargins() with number of pixels that the margin on that side should be. * platform/graphics/TiledBacking.h: * platform/graphics/ca/mac/TileController.h: * platform/graphics/ca/mac/TileController.mm: (WebCore::TileController::TileController): (WebCore::TileController::tilesWouldChangeForVisibleRect): TileController::bounds() now computes the bounds INCLUDING the margin. (WebCore::TileController::bounds): adjustRectAtTileIndexForMargin() is a new function that is required to get the rect size for tiles in the margin right. rectForTileIndex() assumes all tiles strive to be the size of m_tileSize, but now margin tiles will be whatever the margin sizes were set to. (WebCore::TileController::adjustRectAtTileIndexForMargin): (WebCore::TileController::rectForTileIndex): This is another instance where m_tileSize is not always the right size to use. (WebCore::TileController::getTileIndexRangeForRect): The tile coverage rect now might include the margin tiles. Only include them in slow-scrolling mode if the current position is within one tile of the edge. (WebCore::TileController::computeTileCoverageRect): tileSizeForCoverageRect() does not make sense in a world where the coverage rect will include margin. Instead, this patch implements the current strategy more explicitly by returning the visibleRect in the slow scrolling case, and in the process this patch also re-names tileSizeForCoverageRect() to computeTileSize() since it no longer takes a coverageRect. (WebCore::TileController::computeTileSize): (WebCore::TileController::revalidateTiles): New setters and getters for the tile margins on each side. (WebCore::TileController::setTileMargins): (WebCore::TileController::hasMargins): (WebCore::TileController::topMarginHeight): (WebCore::TileController::bottomMarginHeight): (WebCore::TileController::leftMarginWidth): (WebCore::TileController::rightMarginWidth): New function to add margin onto the composited bounds if there is one. * rendering/RenderLayerBacking.cpp: (WebCore::RenderLayerBacking::tiledBackingHasMargin): (WebCore::RenderLayerBacking::paintContents): (WebCore::RenderLayerBacking::compositedBoundsIncludingMargin): * rendering/RenderLayerBacking.h: Do not set masks to bounds if there is a margin on the root layer. * rendering/RenderLayerCompositor.cpp: (WebCore::RenderLayerCompositor::updateBacking): (WebCore::RenderLayerCompositor::mainFrameBackingIsTiledWithMargin): * rendering/RenderLayerCompositor.h: Allow background color to paint into the margin tiles. * rendering/RenderView.cpp: (WebCore::RenderView::paintBoxDecorations): 2013-11-21 Alexey Proskuryakov Implement WebCrypto wrapKey https://bugs.webkit.org/show_bug.cgi?id=124738 Reviewed by Anders Carlsson. Tests: crypto/subtle/aes-cbc-wrap-rsa-non-extractable.html crypto/subtle/aes-cbc-wrap-rsa.html * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::exportKey): Factored out the actual operation that can be chained with encryption for wrapKey. (WebCore::JSSubtleCrypto::exportKey): (WebCore::JSSubtleCrypto::wrapKey): (WebCore::JSSubtleCrypto::unwrapKey): Fixed a memory leak in failure code path. * crypto/SubtleCrypto.idl: Added wrapKey. 2013-11-21 Alexey Proskuryakov Implement WebCrypto unwrapKey https://bugs.webkit.org/show_bug.cgi?id=124725 Reviewed by Anders Carlsson. Tests: crypto/subtle/aes-cbc-unwrap-failure.html crypto/subtle/aes-cbc-unwrap-rsa.html * bindings/js/JSCryptoAlgorithmDictionary.cpp: * bindings/js/JSCryptoAlgorithmDictionary.h: Removed calls for wrap/unwrap parameter parsing, these are just the same as encrypt/decrypt. * bindings/js/JSCryptoOperationData.cpp: (WebCore::cryptoOperationDataFromJSValue): * bindings/js/JSCryptoOperationData.h: * crypto/CryptoKeySerialization.h: More Vector elimination. * bindings/js/JSDOMPromise.cpp: * bindings/js/JSDOMPromise.h: Removed unneccessary copy constructor and assignment operator, they are no diffdrent than compiler generated ones. * bindings/js/JSSubtleCryptoCustom.cpp: (WebCore::cryptoKeyUsagesFromJSValue): Minor style fixes. (WebCore::JSSubtleCrypto::encrypt): Ditto. (WebCore::JSSubtleCrypto::decrypt): Ditto. (WebCore::JSSubtleCrypto::sign): Ditto. (WebCore::JSSubtleCrypto::verify): Ditto. (WebCore::JSSubtleCrypto::generateKey): Ditto. (WebCore::importKey): Separated actual import operation and the parts that read arguments from ExecState, and call the promise. Logically, this should be outside of bindings code even, but JWK makes that quite challenging. (WebCore::JSSubtleCrypto::importKey): This only does the more mundane arguments and return parts now. (WebCore::JSSubtleCrypto::exportKey): Minor style fixes. (WebCore::JSSubtleCrypto::unwrapKey): Chain decrypt and import. * crypto/CryptoAlgorithm.cpp: (WebCore::CryptoAlgorithm::encryptForWrapKey): (WebCore::CryptoAlgorithm::decryptForUnwrapKey): * crypto/CryptoAlgorithm.h: There are algorithms that expose wrap/unwrap, but not encrypt/decrypt. These will override these new functions, and leave encrypt/decrypt to raise NOT_SUPPORTED_ERR. * crypto/SubtleCrypto.idl: Added unwrapKey. 2013-11-21 Robert Sipka [curl]Improve ssl certificate storage and check https://bugs.webkit.org/show_bug.cgi?id=124569 Reviewed by Brent Fulgham. Storage and check the whole certificate chain, not just the root certificate. * platform/network/curl/SSLHandle.cpp: (WebCore::allowsAnyHTTPSCertificateHosts): (WebCore::sslIgnoreHTTPSCertificate): (WebCore::pemData): (WebCore::certVerifyCallback): 2013-11-21 Mihai Maerean Fix hover area for divs with css transforms https://bugs.webkit.org/show_bug.cgi?id=124647 Reviewed by Allan Sandfeld Jensen. Non transformed layers are now being hit last, not through or in-between transformed layers. The paint order says that the divs creating stacking contexts (including transforms) are painted after the other siblings so they should be hit tested in the reverse order. Also, a rotated div in a non-rotated parent should be hit in its entire area, not hit its parent's background, even if the z-coordinate is negative where the mouse is located. Test: transforms/3d/hit-testing/hover-rotated-negative-z.html * rendering/RenderLayer.cpp: (WebCore::computeZOffset): 2013-11-21 Andres Gomez [GTK] Release compilation fails when defining "LOG_DISABLED=0" https://bugs.webkit.org/show_bug.cgi?id=124661 Reviewed by Mario Sanchez Prada. In a "Debug" build the CString.h header comes from another indirect dependency. Now, we explicitly add this missing include. * html/HTMLTrackElement.cpp: Explicitly adding missing include. 2013-11-21 Ryosuke Niwa Fix Range.insertNode when the inserted node is in the same container as the Range https://bugs.webkit.org/show_bug.cgi?id=123957 Reviewed by Antti Koivisto. Inspired by https://chromium.googlesource.com/chromium/blink/+/fb6ca1f488703e8d4f20ce6449cc8ea210be6edb When a node from the same container is inserted, we can't simply adjust m_end with the offset. Compute m_start and m_end from the inserted nodes instead. Also, don't adjust m_start and m_end to nodes outside of the document if the inserted nodes had been removed by mutation events. Test: fast/dom/Range/range-insertNode-same-container.html * dom/Range.cpp: (WebCore::Range::insertNode): 2013-11-21 Ryosuke Niwa nextBoundary and previousBoundary are very slow when there is a password field https://bugs.webkit.org/show_bug.cgi?id=123973 Reviewed by Antti Koivisto. Merge https://chromium.googlesource.com/chromium/blink/+/57366eec5e3edea54062d4e74c0e047f8681dbad When iterating through DOM nodes nextBoundary and previousBoundary convert the contents of nodes using text security to a sequence of 'x' characters. The SimplifiedBackwardsTextIterator and TextIterator may iterate past node boundaries. Before this patch, the transformation was done looking at the starting node rather than the current node. In some situations, this replaced all boundaries with 'x' and caused the text iterator to continue iterating and transforming until the extent of the document. Test: editing/deleting/password-delete-performance.html * editing/TextIterator.h: (WebCore::SimplifiedBackwardsTextIterator::node): * editing/VisibleUnits.cpp: (WebCore::previousBoundary): (WebCore::nextBoundary): 2013-11-21 Ryosuke Niwa HTML parser should not associate elements inside templates with forms https://bugs.webkit.org/show_bug.cgi?id=117779 Reviewed by Antti Koivisto. Merge https://chromium.googlesource.com/chromium/blink/+/45aadf7ee7ee010327eb692066cf013315ef3ed7 When parsing