WebKit-https.git
6 years agoUnreviewed. Removing the remaining Automake cruft.
zandobersek@gmail.com [Wed, 26 Mar 2014 09:09:08 +0000 (09:09 +0000)]
Unreviewed. Removing the remaining Automake cruft.

Source/JavaScriptCore:

* GNUmakefile.list.am: Removed.

Source/WebCore:

* GNUmakefile.list.am: Removed.

Source/WebKit2:

* GNUmakefile.list.am: Removed.

Source/WTF:

* GNUmakefile.list.am: Removed.

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

6 years ago[GTK] The gnumake package is no longer needed in jhbuild
philn@webkit.org [Wed, 26 Mar 2014 07:33:08 +0000 (07:33 +0000)]
[GTK] The gnumake package is no longer needed in jhbuild
https://bugs.webkit.org/show_bug.cgi?id=130121

Reviewed by Martin Robinson.

For GTK build-webkit now relies on cmake and ninja/gnumake. Even
for a debug build cmake/system-gnumake worked just fine for me.

* gtk/jhbuild.modules: Removed gnumake.
* gtk/patches/make-3.82-arg-list-length.patch: Removed.
* gtk/patches/make-3.82-parallel-build.patch: Removed.

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

6 years agoBlog-files: combobox demo needs aria-expanded support
commit-queue@webkit.org [Wed, 26 Mar 2014 07:03:20 +0000 (07:03 +0000)]
Blog-files: combobox demo needs aria-expanded support
https://bugs.webkit.org/show_bug.cgi?id=130766

Patch by James Craig <jcraig@apple.com> on 2014-03-25
Reviewed by Chris Fleizach.

* blog-files/aria1.0/combobox_with_live_region_status.html: Added missing aria-expanded.

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

6 years agoiOS build fix. Add missing semicolon.
psolanki@apple.com [Wed, 26 Mar 2014 05:37:00 +0000 (05:37 +0000)]
iOS build fix. Add missing semicolon.

* editing/cocoa/HTMLConverter.mm:
(HTMLConverter::_addAttachmentForElement):

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

6 years agoSpeculative iOS build fix.
weinig@apple.com [Wed, 26 Mar 2014 04:22:52 +0000 (04:22 +0000)]
Speculative iOS build fix.

* editing/cocoa/HTMLConverter.mm:
(HTMLConverter::_addAttachmentForElement):

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

6 years ago[MSE] Duplicate 'seeked' events.
jer.noble@apple.com [Wed, 26 Mar 2014 04:16:53 +0000 (04:16 +0000)]
[MSE] Duplicate 'seeked' events.
https://bugs.webkit.org/show_bug.cgi?id=130754

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/media-source/media-source-duplicate-seeked.html

During certain seek operations, HTMLMediaElement::finishSeek() can be called re-entrantly due to
the ready state changing as a result of MediaSource::monitorSourceBuffers(). Move this call to the
end of finishSeek() after m_seeking has been cleared.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):

LayoutTests:

* media/media-source/media-source-duplicate-seeked-expected.txt: Added.
* media/media-source/media-source-duplicate-seeked.html: Added.

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

6 years agoArguments simplification phase should be fine with marking the arguments local itself...
fpizlo@apple.com [Wed, 26 Mar 2014 04:08:52 +0000 (04:08 +0000)]
Arguments simplification phase should be fine with marking the arguments local itself as an arguments alias
https://bugs.webkit.org/show_bug.cgi?id=130764
<rdar://problem/16304788>

Reviewed by Sam Weinig.

Being an arguments alias just means that your OSR exit recovery should attempt arguments
creation. This is true of arguments locals. We had special cases that tried to make it not
true of arguments locals. The only consequence of those special cases was to cause crashes
in case of arguments that are also captured variables (i.e. we have SlowArguments). This
change just removes those special cases.

This change means that the FTL will now see SetLocals with a FlushedArguments format.
Previously you wouldn't see them because previously only non-captured variable would be
arguments aliases, and non-captured variables get completely SSAified - i.e. no SetLocals
left. Adding handling for FlushedArguments is a benign and simple change since its
behavior is identical to FlushedJSValue for that code's purposes.

* dfg/DFGArgumentsSimplificationPhase.cpp:
(JSC::DFG::ArgumentsSimplificationPhase::run):
* ftl/FTLLowerDFGToLLVM.cpp:
(JSC::FTL::LowerDFGToLLVM::compileSetLocal):
* tests/stress/captured-arguments-variable.js: Added.
(foo):
(noInline):

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

6 years agoAdd illustrations for a potential blog post
benjamin@webkit.org [Wed, 26 Mar 2014 03:35:30 +0000 (03:35 +0000)]
Add illustrations for a potential blog post

First version, let see how that works out.

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-03-25

* blog-files/css-jit-introduction: Added.
* blog-files/css-jit-introduction/clicktostart.js: Added.
* blog-files/css-jit-introduction/css-jit-illustration.html: Added.
* blog-files/css-jit-introduction/html5-single-page-microbenchmark.html: Added.
* blog-files/css-jit-introduction/old-selectorchecker-illustration.html: Added.
* blog-files/css-jit-introduction/timing-illustration-eight-run.svg: Added.
* blog-files/css-jit-introduction/timing-illustration-five-run.svg: Added.
* blog-files/css-jit-introduction/timing-illustration-one-run.svg: Added.

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

6 years agoWeb Inspector: AXI: add support for aria-activedescendant and reconcile UI/testing...
commit-queue@webkit.org [Wed, 26 Mar 2014 03:03:39 +0000 (03:03 +0000)]
Web Inspector: AXI: add support for aria-activedescendant and reconcile UI/testing with parentNode
https://bugs.webkit.org/show_bug.cgi?id=130712

Patch by James Craig <jcraig@apple.com> on 2014-03-25
Reviewed by Timothy Hatcher.

Source/WebCore:

Test: inspector-protocol/dom/getAccessibilityPropertiesForNode.html

Support for @aria-activedescendant; code reuse changes w/ parentNode and activeDescendantNode.

* inspector/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
* inspector/protocol/DOM.json:

Source/WebInspectorUI:

Support for @aria-activedescendant; code reuse changes w/ parentNode and activeDescendantNode.

* Localizations/en.lproj/localizedStrings.js:
* UserInterface/Models/DOMNode.js:
* UserInterface/Views/DOMNodeDetailsSidebarPanel.js:

LayoutTests:

Support for @aria-activedescendant; code reuse changes w/ parentNode and activeDescendantNode.

* inspector-protocol/dom/getAccessibilityPropertiesForNode-expected.txt:
* inspector-protocol/dom/getAccessibilityPropertiesForNode.html:

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

6 years agoAdd HeapInlines
mhahnenberg@apple.com [Wed, 26 Mar 2014 02:37:51 +0000 (02:37 +0000)]
Add HeapInlines
https://bugs.webkit.org/show_bug.cgi?id=130759

Reviewed by Filip Pizlo.

* GNUmakefile.list.am:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj.filters:
* JavaScriptCore.xcodeproj/project.pbxproj:
* heap/Heap.cpp:
(JSC::MarkedBlockSnapshotFunctor::MarkedBlockSnapshotFunctor):
(JSC::MarkedBlockSnapshotFunctor::operator()):
* heap/Heap.h: Also reindented while we're here.
(JSC::Heap::writeBarrierBuffer):
(JSC::Heap::vm):
(JSC::Heap::objectSpace):
(JSC::Heap::machineThreads):
(JSC::Heap::operationInProgress):
(JSC::Heap::allocatorForObjectWithoutDestructor):
(JSC::Heap::allocatorForObjectWithNormalDestructor):
(JSC::Heap::allocatorForObjectWithImmortalStructureDestructor):
(JSC::Heap::storageAllocator):
(JSC::Heap::notifyIsSafeToCollect):
(JSC::Heap::isSafeToCollect):
(JSC::Heap::handleSet):
(JSC::Heap::handleStack):
(JSC::Heap::lastFullGCLength):
(JSC::Heap::lastEdenGCLength):
(JSC::Heap::increaseLastFullGCLength):
(JSC::Heap::sizeBeforeLastEdenCollection):
(JSC::Heap::sizeAfterLastEdenCollection):
(JSC::Heap::sizeBeforeLastFullCollection):
(JSC::Heap::sizeAfterLastFullCollection):
(JSC::Heap::jitStubRoutines):
(JSC::Heap::isDeferred):
(JSC::Heap::structureIDTable):
(JSC::Heap::removeCodeBlock):
* heap/HeapInlines.h: Added.
(JSC::Heap::shouldCollect):
(JSC::Heap::isBusy):
(JSC::Heap::isCollecting):
(JSC::Heap::heap):
(JSC::Heap::isLive):
(JSC::Heap::isInRememberedSet):
(JSC::Heap::isMarked):
(JSC::Heap::testAndSetMarked):
(JSC::Heap::setMarked):
(JSC::Heap::isWriteBarrierEnabled):
(JSC::Heap::writeBarrier):
(JSC::Heap::reportExtraMemoryCost):
(JSC::Heap::forEachProtectedCell):
(JSC::Heap::forEachCodeBlock):
(JSC::Heap::allocateWithNormalDestructor):
(JSC::Heap::allocateWithImmortalStructureDestructor):
(JSC::Heap::allocateWithoutDestructor):
(JSC::Heap::tryAllocateStorage):
(JSC::Heap::tryReallocateStorage):
(JSC::Heap::ascribeOwner):
(JSC::Heap::blockAllocator):
(JSC::Heap::releaseSoon):
(JSC::Heap::incrementDeferralDepth):
(JSC::Heap::decrementDeferralDepth):
(JSC::Heap::collectIfNecessaryOrDefer):
(JSC::Heap::decrementDeferralDepthAndGCIfNeeded):
(JSC::Heap::markListSet):
* runtime/JSCInlines.h:

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

6 years agoWhen the mouse is upped after dragged out of shadowDOM, it should lose :active.
commit-queue@webkit.org [Wed, 26 Mar 2014 02:30:27 +0000 (02:30 +0000)]
When the mouse is upped after dragged out of shadowDOM, it should lose :active.
https://bugs.webkit.org/show_bug.cgi?id=130660

Patch by Sanghyup Lee <sh53.lee@samsung.com> on 2014-03-25
Reviewed by Darin Adler.

Source/WebCore:

This caused a regression after r165037.
When we have to clear :active style of shadow DOM, we should clear host's style.
This patch replaces parentElement() by parentOrShadowHostElement().

* dom/Document.cpp:
(WebCore::Document::updateHoverActiveState):

LayoutTests:

* fast/css/hover-active-drag-expected.txt: Added a test for textarea.
* fast/css/hover-active-drag.html: Updated.

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

6 years agoDFG::ByteCodeParser::SetMode should distinguish between setting immediately without...
fpizlo@apple.com [Wed, 26 Mar 2014 02:14:40 +0000 (02:14 +0000)]
DFG::ByteCodeParser::SetMode should distinguish between setting immediately without a flush and setting immediately with a flush
https://bugs.webkit.org/show_bug.cgi?id=130760

Reviewed by Mark Hahnenberg.

* dfg/DFGByteCodeParser.cpp:
(JSC::DFG::ByteCodeParser::setLocal):
(JSC::DFG::ByteCodeParser::setArgument):
(JSC::DFG::ByteCodeParser::handleInlining):
(JSC::DFG::ByteCodeParser::parseBlock):
* tests/stress/assign-argument-in-inlined-call.js: Added.
(f1):
(getF2Arguments):
(f2):
(f3):
* tests/stress/assign-captured-argument-in-inlined-call.js: Added.
(f1):
(f2):
(f3):

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

6 years agoFix a failing API test on Mountain Lion and remove temporary debug logging.
aestes@apple.com [Wed, 26 Mar 2014 01:47:26 +0000 (01:47 +0000)]
Fix a failing API test on Mountain Lion and remove temporary debug logging.

* TestWebKitAPI/Tests/WebKit2Cocoa/Download.mm:
(-[DownloadDelegate _download:didReceiveData:]):
(-[DownloadDelegate _downloadDidFinish:]):

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

6 years ago[Mac] Always retry a failed MediaDocument as a PluginDocument
eric.carlson@apple.com [Wed, 26 Mar 2014 00:57:25 +0000 (00:57 +0000)]
[Mac] Always retry a failed MediaDocument as a PluginDocument
https://bugs.webkit.org/show_bug.cgi?id=130742

Reviewed by Jer Noble.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::mediaLoadingFailedFatally): If the element is in a media document,
    tell it that loading failed so it can retry as a plug-in.

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

6 years agoReplace HTMLConverter::_stringForNode by propertyValueForNode
rniwa@webkit.org [Wed, 26 Mar 2014 00:49:05 +0000 (00:49 +0000)]
Replace HTMLConverter::_stringForNode by propertyValueForNode
https://bugs.webkit.org/show_bug.cgi?id=130711

Reviewed by Sam Weinig.

Replaced all calls to HTMLConverter::_stringForNode by that to propertyValueForNode.

* editing/cocoa/HTMLConverter.mm:
(HTMLConverter::_computedAttributesForElement):
(HTMLConverter::_addAttachmentForElement):
(HTMLConverter::_enterElement):
(HTMLConverter::_addTableForElement):
(HTMLConverter::_addTableCellForElement):
(HTMLConverter::_processElement):
(HTMLConverter::_exitElement):
(HTMLConverter::_processText):
(HTMLConverter::_traverseNode):
(HTMLConverter::_traverseFooterNode):
(HTMLConverter::_stringForNode): Deleted.

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

6 years agoAttempt to fix iOS build after r166261.
psolanki@apple.com [Wed, 26 Mar 2014 00:39:55 +0000 (00:39 +0000)]
Attempt to fix iOS build after r166261.

* WebCore.xcodeproj/project.pbxproj: Make SystemSleepListener.h a private header.

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

6 years agoRemove PLATFORM(IOS) from NetworkProcessMac.mm
psolanki@apple.com [Wed, 26 Mar 2014 00:31:55 +0000 (00:31 +0000)]
Remove PLATFORM(IOS) from NetworkProcessMac.mm
https://bugs.webkit.org/show_bug.cgi?id=130751

Reviewed by Alexey Proskuryakov.

Code in NetworkProcessMac.mm is guarded by PLATFORM(MAC) and so is not compiled on iOS.
Having PLATFORM(IOS) code in this file is unnecessary and confusing.

* NetworkProcess/mac/NetworkProcessMac.mm:
(WebKit::NetworkProcess::initializeProcessName):
(WebKit::overrideSystemProxies):
(WebKit::NetworkProcess::platformInitializeNetworkProcess):

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

6 years agoAdd a UI delegate callback for handling window.open
andersca@apple.com [Wed, 26 Mar 2014 00:01:09 +0000 (00:01 +0000)]
Add a UI delegate callback for handling window.open
https://bugs.webkit.org/show_bug.cgi?id=130757

Reviewed by Sam Weinig.

* UIProcess/API/Cocoa/WKUIDelegate.h:
* UIProcess/API/Cocoa/WKWebView.mm:
* UIProcess/API/Cocoa/WKWebViewInternal.h:
* UIProcess/Cocoa/UIClient.h:
* UIProcess/Cocoa/UIClient.mm:
(WebKit::UIClient::setDelegate):
(WebKit::UIClient::createNewPage):

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

6 years agoMove stopLoading: back for now.
andersca@apple.com [Wed, 26 Mar 2014 00:00:17 +0000 (00:00 +0000)]
Move stopLoading: back for now.

* UIProcess/API/Cocoa/WKWebView.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView stopLoading:]):

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

6 years ago[iOS] Enable caption support in full screen.
jer.noble@apple.com [Tue, 25 Mar 2014 23:43:13 +0000 (23:43 +0000)]
[iOS] Enable caption support in full screen.
https://bugs.webkit.org/show_bug.cgi?id=130603

Reviewed by Eric Carlson.

Add TextTrackRepresentation support to MediaPlayerPrivateAVFoundationObjC.

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Add the m_textTrackRepresenationLayer if present.
(WebCore::MediaPlayerPrivateAVFoundationObjC::setVideoFullscreenLayer): Ditto.
(WebCore::MediaPlayerPrivateAVFoundationObjC::requiresTextTrackRepresentation): True, if a m_videoFullscreenLayer is present.
(WebCore::MediaPlayerPrivateAVFoundationObjC::setTextTrackRepresentation): Remove the old, and add the new m_textTrackRepresenationLayer.

Make the text track container a stacking context for painting purposes.
* Modules/mediacontrols/mediaControlsiOS.css:
(video::-webkit-media-text-track-container):

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

6 years agoChange toolbarVisibility back to toolbarsVisibility
andersca@apple.com [Tue, 25 Mar 2014 23:37:01 +0000 (23:37 +0000)]
Change toolbarVisibility back to toolbarsVisibility
https://bugs.webkit.org/show_bug.cgi?id=130749

Reviewed by Tim Horton.

* UIProcess/API/Cocoa/WKWindowFeatures.h:
* UIProcess/API/Cocoa/WKWindowFeatures.mm:
(-[WKWindowFeatures _initWithWindowFeatures:WebCore::]):

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

6 years agoFix 32-bit getter call alignment.
fpizlo@apple.com [Tue, 25 Mar 2014 23:28:48 +0000 (23:28 +0000)]
Fix 32-bit getter call alignment.

Reviewed by Mark Hahnenberg.

* jit/Repatch.cpp:
(JSC::generateGetByIdStub):

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

6 years agoPass the source frame to the CreateNewPage message
andersca@apple.com [Tue, 25 Mar 2014 23:20:14 +0000 (23:20 +0000)]
Pass the source frame to the CreateNewPage message
https://bugs.webkit.org/show_bug.cgi?id=130752

Reviewed by Tim Horton.

* UIProcess/API/APIUIClient.h:
(API::UIClient::createNewPage):
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageUIClient):
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::createNewPage):
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::createWindow):

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

6 years agoSource/WebCore: Web Replay: resource unique identifiers should be unique-per-frame...
bburg@apple.com [Tue, 25 Mar 2014 22:56:58 +0000 (22:56 +0000)]
Source/WebCore: Web Replay: resource unique identifiers should be unique-per-frame, not globally
https://bugs.webkit.org/show_bug.cgi?id=130632

Reviewed by Timothy Hatcher.

For replay purposes, we want to deterministically assign resource load identifiers
to resource loaders, provided that the resource loaders are created in the same
order.

To do this, we convert unique identifiers from being globally-unique to being
frame-unique. When a new frame is being loaded, unique identifiers for
subresources of that frame begin counting from 1.

No new tests. Identifier invariants are exercised by existing assertions and tests.

* loader/ProgressTracker.cpp:
(WebCore::ProgressTracker::ProgressTracker):
(WebCore::ProgressTracker::reset):
(WebCore::ProgressTracker::createUniqueIdentifier):
* loader/ProgressTracker.h:

Tools: Web Replay: resource unique identifiers should be unique-per-frame, not globally
https://bugs.webkit.org/show_bug.cgi?id=130623

Reviewed by Timothy Hatcher.

The resource loader callback dumping routines assumed that resource identifiers
were globally unique. Its map of resource identifiers to URLs must also track the
frame associated with the resource.

* WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::dumpResourceURL): Additionally take a WKBundleFrameRef argument, and use the
opaque pointer as part of the key for assignedUrlsCache. The frame pointer is
stable as long as the frame is valid.
(WTR::InjectedBundlePage::didInitiateLoadForResource):
(WTR::InjectedBundlePage::willSendRequestForFrame):
(WTR::InjectedBundlePage::didReceiveResponseForResource):
(WTR::InjectedBundlePage::didFinishLoadForResource):
(WTR::InjectedBundlePage::didFailLoadForResource):

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

6 years agoRepatch should plant calls to getters directly rather than through a C helper
fpizlo@apple.com [Tue, 25 Mar 2014 22:38:52 +0000 (22:38 +0000)]
Repatch should plant calls to getters directly rather than through a C helper
https://bugs.webkit.org/show_bug.cgi?id=129589

Source/JavaScriptCore:

Reviewed by Mark Hahnenberg.

As the title says. All of the superstructure for this was already in place, so now it
was just a matter of actually emitting the call.

8x speed-up for getter microbenchmarks.

* CMakeLists.txt:
* JavaScriptCore.vcxproj/JavaScriptCore.vcxproj:
* JavaScriptCore.xcodeproj/project.pbxproj:
* bytecode/PolymorphicGetByIdList.h:
(JSC::GetByIdAccess::doesCalls):
* jit/AccessorCallJITStubRoutine.cpp: Added.
(JSC::AccessorCallJITStubRoutine::AccessorCallJITStubRoutine):
(JSC::AccessorCallJITStubRoutine::~AccessorCallJITStubRoutine):
(JSC::AccessorCallJITStubRoutine::visitWeak):
* jit/AccessorCallJITStubRoutine.h: Added.
* jit/AssemblyHelpers.h:
(JSC::AssemblyHelpers::storeCell):
* jit/GCAwareJITStubRoutine.h:
* jit/Repatch.cpp:
(JSC::generateGetByIdStub):
* runtime/GetterSetter.h:
(JSC::GetterSetter::offsetOfGetter):
(JSC::GetterSetter::offsetOfSetter):

LayoutTests:

Reviewed by Mark Hahnenberg.

* js/regress/getter-expected.txt: Added.
* js/regress/getter.html: Added.
* js/regress/script-tests/getter.js: Added.
* js/regress/script-tests/string-char-code-at.js: Added.
(foo):
* js/regress/string-char-code-at-expected.txt: Added.
* js/regress/string-char-code-at.html: Added.

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

6 years agoAdd a WebFrame::fromCoreFrame static member function and use it where possible
andersca@apple.com [Tue, 25 Mar 2014 22:34:47 +0000 (22:34 +0000)]
Add a WebFrame::fromCoreFrame static member function and use it where possible
https://bugs.webkit.org/show_bug.cgi?id=130744

Reviewed by Tim Horton.

* WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
(WebKit::GeolocationPermissionRequestManager::startRequestForGeolocation):
* WebProcess/InjectedBundle/DOM/InjectedBundleNodeHandle.cpp:
(WebKit::InjectedBundleNodeHandle::documentFrame):
(WebKit::InjectedBundleNodeHandle::htmlFrameElementContentFrame):
(WebKit::InjectedBundleNodeHandle::htmlIFrameElementContentFrame):
* WebProcess/InjectedBundle/InjectedBundle.cpp:
(WebKit::InjectedBundle::overrideBoolPreferenceForTestRunner):
* WebProcess/InjectedBundle/InjectedBundleDOMWindowExtension.cpp:
(WebKit::InjectedBundleDOMWindowExtension::frame):
* WebProcess/InjectedBundle/InjectedBundleHitTestResult.cpp:
(WebKit::InjectedBundleHitTestResult::frame):
(WebKit::InjectedBundleHitTestResult::targetFrame):
* WebProcess/Plugins/PluginView.cpp:
(WebKit::webPage):
(WebKit::PluginView::performFrameLoadURLRequest):
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::focusedElementChanged):
(WebKit::WebChromeClient::focusedFrameChanged):
(WebKit::WebChromeClient::runBeforeUnloadConfirmPanel):
(WebKit::WebChromeClient::runJavaScriptAlert):
(WebKit::WebChromeClient::runJavaScriptConfirm):
(WebKit::WebChromeClient::runJavaScriptPrompt):
(WebKit::WebChromeClient::print):
(WebKit::WebChromeClient::exceededDatabaseQuota):
(WebKit::WebChromeClient::runOpenPanel):
* WebProcess/WebCoreSupport/WebEditorClient.cpp:
(WebKit::WebEditorClient::textFieldDidBeginEditing):
(WebKit::WebEditorClient::textFieldDidEndEditing):
(WebKit::WebEditorClient::textDidChangeInTextField):
(WebKit::WebEditorClient::textDidChangeInTextArea):
(WebKit::WebEditorClient::doTextFieldCommandFromEvent):
(WebKit::WebEditorClient::textWillBeDeletedInTextField):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
(WebKit::WebFrameLoaderClient::dispatchWillSendSubmitEvent):
(WebKit::WebFrameLoaderClient::dispatchWillSubmitForm):
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::fromCoreFrame):
(WebKit::WebFrame::contentsAsString):
(WebKit::WebFrame::parentFrame):
(WebKit::WebFrame::childFrames):
(WebKit::WebFrame::frameForContext):
(WebKit::WebFrame::webArchiveData):
* WebProcess/WebPage/WebFrame.h:

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

6 years ago[Mac] Pause the media element during system sleep.
jer.noble@apple.com [Tue, 25 Mar 2014 22:26:34 +0000 (22:26 +0000)]
[Mac] Pause the media element during system sleep.
https://bugs.webkit.org/show_bug.cgi?id=130718

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/video-system-sleep.html

Relying on the platform media system to pause and restart playback during
system sleep can cause problems on some platforms, especially where hardware
decoders are concerned. Rather than implicitly pausing the media during
system sleep, explicitly pause the media before sleeping and resume (if
appropriate) upon waking.

Add a new class to be used for system sleep notifications:
* platform/SystemSleepListener.cpp: Added.
(WebCore::SystemSleepListener::create):
(WebCore::SystemSleepListener::SystemSleepListener):
* platform/SystemSleepListener.h: Added.
(WebCore::SystemSleepListener::Client::~Client):
(WebCore::SystemSleepListener::~SystemSleepListener):
(WebCore::SystemSleepListener::client):

Add a Mac-specific implementation:
* platform/mac/SystemSleepListenerMac.h: Added.
* platform/mac/SystemSleepListenerMac.mm: Added.
(WebCore::SystemSleepListener::create):
(WebCore::SystemSleepListenerMac::SystemSleepListenerMac):
(WebCore::SystemSleepListenerMac::~SystemSleepListenerMac):

Listen for system sleep notifications in MediaSessionManager:
* platform/audio/MediaSessionManager.cpp:
(WebCore::MediaSessionManager::MediaSessionManager):
(WebCore::MediaSessionManager::systemWillSleep):
(WebCore::MediaSessionManager::systemDidWake):
* platform/audio/MediaSessionManager.h:

Drive-by fix; notify the MediaSession that playback will begin
due to autoplay, but do not begin autoplaying if the session
is already interrupted:
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):

Add new files to project:
* WebCore.vcxproj/WebCore.vcxproj:
* WebCore.xcodeproj/project.pbxproj:
* CMakeLists.txt:
* GNUmakefile.list.am:

LayoutTests:

* media/video-system-sleep-expected.txt: Added.
* media/video-system-sleep.html: Added.

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

6 years agoFix one API test expectation failure on Mountain Lion, and add additional logging...
aestes@apple.com [Tue, 25 Mar 2014 22:20:02 +0000 (22:20 +0000)]
Fix one API test expectation failure on Mountain Lion, and add additional logging to help diagnose another.

* TestWebKitAPI/Tests/WebKit2Cocoa/Download.mm:
(-[DownloadDelegate _download:didReceiveResponse:]):
(-[DownloadDelegate _download:didReceiveData:]):

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

6 years ago[CSS Regions] The background of children of scrollable elements flowed into regions...
stavila@adobe.com [Tue, 25 Mar 2014 22:01:25 +0000 (22:01 +0000)]
[CSS Regions] The background of children of scrollable elements flowed into regions is not properly scrolled
https://bugs.webkit.org/show_bug.cgi?id=130574

Reviewed by David Hyatt.

Source/WebCore:

When computing the clip rect for painting the box decorations, the scrolled content offset
must be computed by going up the containing block tree, up to the region.

Tests: fast/regions/scrollable-region-scrollable-absolute-content-background.html
       fast/regions/scrollable-region-scrollable-content-background.html

* rendering/RenderNamedFlowThread.cpp:
(WebCore::RenderNamedFlowThread::decorationsClipRectForBoxInNamedFlowFragment):

LayoutTests:

Added tests for properly painting background of children of scrollable elements flowed into regions.

* fast/regions/scrollable-region-scrollable-absolute-content-background-expected.html: Added.
* fast/regions/scrollable-region-scrollable-absolute-content-background.html: Added.
* fast/regions/scrollable-region-scrollable-content-background-expected.html: Added.
* fast/regions/scrollable-region-scrollable-content-background.html: Added.

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

6 years ago[WK2] Schemes registered as cache partitioned are not properly registered in new...
jpfau@apple.com [Tue, 25 Mar 2014 21:53:14 +0000 (21:53 +0000)]
[WK2] Schemes registered as cache partitioned are not properly registered in new web processes
https://bugs.webkit.org/show_bug.cgi?id=130739

Reviewed by Anders Carlsson.

* WebProcess/WebProcess.cpp:
(WebKit::WebProcess::initializeWebProcess):

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

6 years ago[iOS] Inspector View Indication Support
joepeck@webkit.org [Tue, 25 Mar 2014 21:52:20 +0000 (21:52 +0000)]
[iOS] Inspector View Indication Support
https://bugs.webkit.org/show_bug.cgi?id=130709

Reviewed by Simon Fraser.

Source/WebCore:

* inspector/InspectorClient.h:
(WebCore::InspectorClient::showInspectorIndication):
(WebCore::InspectorClient::hideInspectorIndication):
* inspector/InspectorController.cpp:
(WebCore::InspectorController::setIndicating):
Rename indicate/hideIndication to show/hide names.

Source/WebKit/ios:

* WebCoreSupport/WebInspectorClientIOS.mm:
(WebInspectorClient::showInspectorIndication):
(WebInspectorClient::hideInspectorIndication):
Renamed methods.

Source/WebKit/mac:

* WebCoreSupport/WebInspectorClient.h:
* WebCoreSupport/WebInspectorClient.mm:
(WebInspectorClient::didSetSearchingForNode): Deleted.
(WebInspectorClient::releaseFrontend): Deleted.
* WebView/WebView.mm:
(-[WebView setShowingInspectorIndication:]):
* WebView/WebViewPrivate.h:
Renamed methods.

Source/WebKit2:

* UIProcess/ios/WKContentView.h:
* UIProcess/ios/WKContentView.mm:
(-[WKInspectorIndicationView initWithFrame:]):
(-[WKContentView isShowingInspectorIndication]):
(-[WKContentView setShowingInspectorIndication:]):
(-[WKContentView _didCommitLayerTree:WebKit::]):
When indicating include a simple tinted UIView over the content.

* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _showInspectorIndication]):
(-[WKWebView _hideInspectorIndication]):
Have the content view show or hide an indication.

* UIProcess/PageClient.h:
* UIProcess/ios/PageClientImplIOS.h:
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::showInspectorIndication):
(WebKit::PageClientImpl::hideInspectorIndication):
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::showInspectorIndication):
(WebKit::WebPageProxy::hideInspectorIndication):
Pass WebProcess indication message up to the WKWebView.

* WebProcess/WebCoreSupport/WebInspectorClient.cpp:
(WebKit::WebInspectorClient::indicate):
(WebKit::WebInspectorClient::hideIndication):
* WebProcess/WebCoreSupport/WebInspectorClient.h:
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::indicate):
(WebKit::WebPage::hideIndication):
Pass WebCore / remote inspector indication message up to UIProcess.

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

6 years agoUnreviewed build fix. Typo on checkin.
bfulgham@apple.com [Tue, 25 Mar 2014 21:34:42 +0000 (21:34 +0000)]
Unreviewed build fix. Typo on checkin.

* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Left an unmatched open bracket.

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

6 years agoEven further unreviewed build fix after r166247. Unprotect the implementation of...
jer.noble@apple.com [Tue, 25 Mar 2014 21:33:45 +0000 (21:33 +0000)]
Even further unreviewed build fix after r166247. Unprotect the implementation of HTMLMediaElement::shouldDisableSleep().

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::parseAttribute):

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

6 years agoFurther unreviewed build fix after r166247. Add DisplaySleepDisabler to the windows...
jer.noble@apple.com [Tue, 25 Mar 2014 21:26:17 +0000 (21:26 +0000)]
Further unreviewed build fix after r166247. Add DisplaySleepDisabler to the windows project file and
move the definition of DisplaySleepDisabler's constructor and destructor into the cpp file.

* WebCore.vcxproj/WebCore.vcxproj:
* platform/DisplaySleepDisabler.cpp:
(WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
(WebCore::DisplaySleepDisabler::~DisplaySleepDisabler):
* platform/DisplaySleepDisabler.h:

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

6 years agoAdd more properties to WKWindowFeatures
andersca@apple.com [Tue, 25 Mar 2014 21:18:20 +0000 (21:18 +0000)]
Add more properties to WKWindowFeatures
https://bugs.webkit.org/show_bug.cgi?id=130738

Reviewed by Tim Horton.

* UIProcess/API/Cocoa/WKWindowFeatures.h:
* UIProcess/API/Cocoa/WKWindowFeatures.mm:
(-[WKWindowFeatures _initWithWindowFeatures:WebCore::]):
(-[WKWindowFeatures menuBarVisibility]):
(-[WKWindowFeatures statusBarVisibility]):
(-[WKWindowFeatures toolbarsVisibility]):
(-[WKWindowFeatures allowsResizing]):

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

6 years agoUnreviewed build fix after r166247. Un-platform-protect the declaration of HTMLMediaE...
jer.noble@apple.com [Tue, 25 Mar 2014 21:07:32 +0000 (21:07 +0000)]
Unreviewed build fix after r166247. Un-platform-protect the declaration of HTMLMediaElement::shouldDisableSleep()
and make WebVideoFullscreenController's _displaySleepDisabler a std::unique_ptr.

* html/HTMLMediaElement.h:
* platform/mac/WebVideoFullscreenController.h:

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

6 years agoFix iOS build.
andersca@apple.com [Tue, 25 Mar 2014 21:03:46 +0000 (21:03 +0000)]
Fix iOS build.

* UIProcess/API/Cocoa/WKWebView.h:
* UIProcess/API/Cocoa/WKWebView.mm:
Make WKIBActions OS X only for now.

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

6 years ago[iOS] Pass additional options to AVFoundation during playback.
bfulgham@apple.com [Tue, 25 Mar 2014 21:00:19 +0000 (21:00 +0000)]
[iOS] Pass additional options to AVFoundation during playback.
https://bugs.webkit.org/show_bug.cgi?id=130624

Reviewed by Eric Carlson.

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::doesHaveAttribute): Return attribute value if the user
passes a pointer to fill in.
* html/HTMLMediaElement.h:
* platform/graphics/MediaPlayer.cpp:
(WebCore::MediaPlayer::doesHaveAttribute):
* platform/graphics/MediaPlayer.h:
(WebCore::MediaPlayerClient::doesHaveAttribute):
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem): Pass additional
option if supplied by user.

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

6 years agoUnreviewed, rolling out r166070.
msaboff@apple.com [Tue, 25 Mar 2014 20:43:27 +0000 (20:43 +0000)]
Unreviewed, rolling out r166070.

Rollout r166070 due to 2% performance loss in page load times

Reverted changeset:

"Change CodeGeneratorJS.pm special cases for "DOMWindow" to be
general purpose"
https://bugs.webkit.org/show_bug.cgi?id=130553
http://trac.webkit.org/changeset/166070

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

6 years agoUnreviewed, rolling out r166126.
msaboff@apple.com [Tue, 25 Mar 2014 20:40:34 +0000 (20:40 +0000)]
Unreviewed, rolling out r166126.

Rollout r166126 in prepartion to roll out prerequisite r166070

Reverted changeset:

"toThis() on a JSWorkerGlobalScope should return a JSProxy and
not undefined"
https://bugs.webkit.org/show_bug.cgi?id=130554
http://trac.webkit.org/changeset/166126

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

6 years ago[iOS] Playing video does not disable display sleep.
jer.noble@apple.com [Tue, 25 Mar 2014 20:25:52 +0000 (20:25 +0000)]
[iOS] Playing video does not disable display sleep.
https://bugs.webkit.org/show_bug.cgi?id=130729

Reviewed by Eric Carlson.

DisplaySleepDisabler was broken by r161589, which replaced the iOS implementation with
an empty one. Make a platform independent version with a Cocoa-platform subclass. Update
the APIs to non-deprecated ones.

* platform/DisplaySleepDisabler.cpp: Added.
(WebCore::DisplaySleepDisabler::create):
* platform/DisplaySleepDisabler.h: Added.
(WebCore::DisplaySleepDisabler::~DisplaySleepDisabler):
(WebCore::DisplaySleepDisabler::DisplaySleepDisabler):
* platform/cocoa/DisplaySleepDisablerCocoa.cpp: Renamed from Source/WebCore/platform/mac/DisplaySleepDisabler.cpp.
(WebCore::DisplaySleepDisabler::create):
(WebCore::DisplaySleepDisablerCocoa::DisplaySleepDisablerCocoa):
(WebCore::DisplaySleepDisablerCocoa::~DisplaySleepDisablerCocoa):
* platform/cocoa/DisplaySleepDisablerCocoa.h: Renamed from Source/WebCore/platform/mac/DisplaySleepDisabler.h.

Update m_sleepDisabler to be a std::unique_ptr, and unprotect the definition of methods which use it.
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::updateSleepDisabling):
(WebCore::HTMLMediaElement::shouldDisableSleep):
* html/HTMLMediaElement.h:

Add the new and renamed files to the project:
* CMakeLists.txt:
* GNUmakefile.list.am:
* WebCore.xcodeproj/project.pbxproj:

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

6 years agoImplement ImageData constructors and WebWorkers exposure
krit@webkit.org [Tue, 25 Mar 2014 20:24:14 +0000 (20:24 +0000)]
Implement ImageData constructors and WebWorkers exposure
https://bugs.webkit.org/show_bug.cgi?id=130668

Reviewed by Dean Jackson.

Source/WebCore:

Add new constructors for ImageData.

http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#pixel-manipulation

Test: fast/canvas/canvas-imageData.html

* html/ImageData.cpp:
(WebCore::ImageData::create):
* html/ImageData.h:
* html/ImageData.idl:

LayoutTests:

Tests for ImageData constructors. Remove a false tests for constructors
from Philip's test suite.

* fast/canvas/canvas-imageData-expected.txt: Added.
* fast/canvas/canvas-imageData.html: Added.
* fast/canvas/script-tests/canvas-imageData.js: Added.
(testTransparentBlack):
* LayoutTests/canvas/philip/tests/2d.imageData.object.ctor.html: Removed.
* LayoutTests/canvas/philip/tests/2d.imageData.object.ctor-expected.txt: Removed.
* LayoutTests/js/dom/global-constructors-attributes-dedicated-worker-expected.txt
* LayoutTests/js/dom/global-constructors-attributes-shared-worker-expected.txt

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

6 years agoInlineIterator position (unsigned int) variable can wrap around
mmaxfield@apple.com [Tue, 25 Mar 2014 20:15:14 +0000 (20:15 +0000)]
InlineIterator position (unsigned int) variable can wrap around
https://bugs.webkit.org/show_bug.cgi?id=130540

Patch by Myles C. Maxfield <mmaxfield@apple.com> on 2014-03-25
Reviewed by Simon Fraser.

Source/WebCore:

We trigger an ASSERT that occurs when we are ignoring spaces (to collapse them
into a single whitespace mark) but then encounter a line break. Because we don't ignore
the first space (but do ignore subsequent spaces), when we hit a newline in an RTL context
we want to ignore that first space as well (so as not to push the text away from the right
edge). We do this by decrementing the InlineIterator pointing to this first space, so all
the spaces get ignored. However, if that space is the first character in a Text node, the
decrement will try to go past the beginning of the node, and trigger an ASSERT.

This design is not great. At some point we should rework it to more elegantly handle
collapsing whitespace in both RTL and LTR writing modes.

This patch adds an ASSERT earlier in this codepath to catch potential problems earlier.
It also pulls our sentinel value out into a separate boolean to make it more clear what is
going on.

Test: fast/text/whitespace-only-text-in-rtl.html

* rendering/InlineIterator.h:
(WebCore::InlineIterator::moveTo): Use the set***() calls
(WebCore::InlineIterator::setOffset): ASSERT early that our math hasn't wrapped
* rendering/RenderBlockLineLayout.cpp:
(WebCore::RenderBlockFlow::appendRunsForObject): Use new boolean value
* rendering/line/BreakingContextInlineHeaders.h:
(WebCore::BreakingContext::handleText): Guard against wraps
(WebCore::checkMidpoints): Use new boolean value
* rendering/line/TrailingObjects.cpp:
(WebCore::TrailingObjects::updateMidpointsForTrailingBoxes): Use new boolean value

LayoutTests:

This test triggers an ASSERT that occurs when we are ignoring spaces (to collapse them
into a single whitespace mark) but then encounter a line break. Because we don't ignore
the first space (but do ignore subsequent spaces), when we hit a newline in an RTL context
we want to ignore that first space as well (so as not to push the text away from the right
edge). We do this by decrementing the InlineIterator pointing to this first space, so all
the spaces get ignored. However, if that space is the first character in a Text node, the
decrement will try to go past the beginning of the node, and trigger an ASSERT.

This design is not great. At some point we should rework it to more elegantly handle
collapsing whitespace in both RTL and LTR writing modes.

* fast/text/whitespace-only-text-in-rtl-expected.txt: Added.
* fast/text/whitespace-only-text-in-rtl.html: Added.

Conflicts:
LayoutTests/ChangeLog
Source/WebCore/ChangeLog

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

6 years agoBegin stubbing out a WKWindowFeatures class
andersca@apple.com [Tue, 25 Mar 2014 20:10:02 +0000 (20:10 +0000)]
Begin stubbing out a WKWindowFeatures class
https://bugs.webkit.org/show_bug.cgi?id=130733

Reviewed by Dan Bernstein.

* UIProcess/API/Cocoa/WKWindowFeatures.h: Added.
* UIProcess/API/Cocoa/WKWindowFeatures.mm: Added.
(-[WKWindowFeatures _initWithWindowFeatures:WebCore::]):
(-[WKWindowFeatures x]):
(-[WKWindowFeatures y]):
(-[WKWindowFeatures width]):
(-[WKWindowFeatures height]):
* UIProcess/API/Cocoa/WKWindowFeaturesInternal.h: Added.
* WebKit2.xcodeproj/project.pbxproj:

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

6 years agoAST incorrectly conflates readable and writable locations
oliver@apple.com [Tue, 25 Mar 2014 20:06:07 +0000 (20:06 +0000)]
AST incorrectly conflates readable and writable locations
https://bugs.webkit.org/show_bug.cgi?id=130734

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

We need to distinguish between "locations" that are valid for reading
and writing, vs those that may only be written.

* bytecompiler/NodesCodegen.cpp:
(JSC::ForInNode::emitBytecode):
(JSC::ForOfNode::emitBytecode):
* parser/Nodes.h:
(JSC::ExpressionNode::isAssignmentLocation):

LayoutTests:

More tests

* js/parser-syntax-check-expected.txt:
* js/script-tests/parser-syntax-check.js:

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

6 years agoAdd some debug logging to an API test that's failing on Mountain Lion.
aestes@apple.com [Tue, 25 Mar 2014 19:48:15 +0000 (19:48 +0000)]
Add some debug logging to an API test that's failing on Mountain Lion.

* TestWebKitAPI/Tests/WebKit2Cocoa/Download.mm:
(-[DownloadDelegate _download:didReceiveResponse:]):
(-[DownloadDelegate _downloadDidFinish:]):

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

6 years agoAdd goBack: and goForward: IBActions and move stopLoading: to a new WKIBActions categ...
andersca@apple.com [Tue, 25 Mar 2014 19:17:54 +0000 (19:17 +0000)]
Add goBack: and goForward: IBActions and move stopLoading: to a new WKIBActions category on WKWebView
https://bugs.webkit.org/show_bug.cgi?id=130732

Reviewed by Tim Horton.

Source/WebKit2:

* UIProcess/API/Cocoa/WKWebView.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView goBack]):
(-[WKWebView goForward]):
(-[WKWebView validateUserInterfaceItem:]):
(-[WKWebView goBack:]):
(-[WKWebView goForward:]):
(-[WKWebView stopLoading:]):

Tools:

* MiniBrowser/mac/WK2BrowserWindowController.m:
(-[WK2BrowserWindowController validateUserInterfaceItem:]):

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

6 years agoASSERTION FAILED in Parser: dst != localReg
oliver@apple.com [Tue, 25 Mar 2014 18:00:30 +0000 (18:00 +0000)]
ASSERTION FAILED in Parser: dst != localReg
https://bugs.webkit.org/show_bug.cgi?id=130710

Reviewed by Filip Pizlo.

Source/JavaScriptCore:

Just make sure we don't try to write to a captured constant,
following the change to track captured variables separately.

* bytecompiler/NodesCodegen.cpp:
(JSC::PostfixNode::emitResolve):
(JSC::PrefixNode::emitResolve):

LayoutTests:

New testcases.

* js/parser-syntax-check-expected.txt:
* js/script-tests/parser-syntax-check.js:

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

6 years ago[GTK] Remove the autotools build
mrobinson@webkit.org [Tue, 25 Mar 2014 17:45:52 +0000 (17:45 +0000)]
[GTK] Remove the autotools build
https://bugs.webkit.org/show_bug.cgi?id=130717

Reviewed by Anders Carlsson.

.:

* .gitignore: Remove references to autotools files.
* GNUmakefile.am: Removed.
* Source/autotools/CheckSystemAndBasicDependencies.m4: Removed.
* Source/autotools/CustomMacros.m4: Removed.
* Source/autotools/FindDependencies.m4: Removed.
* Source/autotools/PrintBuildConfiguration.m4: Removed.
* Source/autotools/ReadCommandLineArguments.m4: Removed.
* Source/autotools/SetupAutoconfHeader.m4: Removed.
* Source/autotools/SetupAutomake.m4: Removed.
* Source/autotools/SetupCompilerFlags.m4: Removed.
* Source/autotools/SetupLibtool.m4: Removed.
* Source/autotools/SetupWebKitFeatures.m4: Removed.
* Source/autotools/Versions.m4: Removed.
* Source/autotools/acinclude.m4: Removed.
* Source/autotools/dolt.m4: Removed.
* Source/autotools/gsettings.m4: Removed.
* Source/cmake/OptionsGTK.cmake:
* autogen.sh: Removed.
* configure.ac: Removed.

Source/JavaScriptCore:

* GNUmakefile.am: Removed.
* config.h: Remove references to the autotools configure file.

Source/Platform:

* GNUmakefile.am: Removed.

Source/ThirdParty:

* gtest/GNUmakefile.am: Removed.
* leveldb/GNUmakefile.am: Removed.

Source/ThirdParty/ANGLE:

* GNUmakefile.am: Removed.

Source/WebCore:

* GNUmakefile.am: Removed.
* bindings/gobject/GNUmakefile.am: Removed.
* config.h: Removed references to autotools configure file.

Source/WebCore/platform/gtk/po:

* GNUmakefile.am: Removed.

Source/WebInspectorUI:

* GNUmakefile.am: Removed.

Source/WebKit/gtk:

* GNUmakefile.am: Removed.

Source/WebKit2:

* GNUmakefile.am: Removed.
* WebKit2Prefix.h: Removed references to the autotools configure file.
* config.h: Ditto.

Source/WTF:

* GNUmakefile.am: Removed.
* config.h: Removed references to the autotools configure file.

Tools:

* DumpRenderTree/config.h: Remove references to the autotools configure file.
* GNUmakefile.am: Removed.
* GtkLauncher/GNUmakefile.am: Removed.
* GtkLauncher/main.c: Remove references to the autotools configure file.
* MiniBrowser/gtk/BrowserDownloadsBar.c: Ditto.
* MiniBrowser/gtk/BrowserSearchBar.c: Ditto.
* MiniBrowser/gtk/BrowserWindow.c: Ditto.
* MiniBrowser/gtk/GNUmakefile.am: Removed.
* MiniBrowser/gtk/main.c: Remove references to the autotools configure file.
* Scripts/build-webkit: No longer handle autotools.
* Scripts/run-gtk-tests: Ditto.
(TestRunner._setup_testing_environment):
* Scripts/run-launcher: Ditto.
* Scripts/webkitdirs.pm: Ditto.
* Scripts/webkitpy/common/config/contributionareas.py: Remove autotools as a contribution area.
* Scripts/webkitpy/common/config/contributors.json: Ditto.
* Scripts/webkitpy/port/gtk.py: No longer handle autotools.
* Scripts/webkitpy/style/checker.py:
* TestWebKitAPI/GNUmakefile.am: Removed.
* TestWebKitAPI/config.h: Remove references to the autotools configure file.
* WebKitTestRunner/GNUmakefile.am: Removed.
* WebKitTestRunner/WebKitTestRunnerPrefix.h: Ditto.
* gtk/GNUmakefile.am: Removed.
* gtk/common.py: Remove checks for the autotools build.
* gtk/symbols.filter: Renamed from Source/autotools/symbols.filter.

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

6 years agoPrevent 'removetrack' events from firing when all inband text tracks are removed.
bfulgham@apple.com [Tue, 25 Mar 2014 16:51:40 +0000 (16:51 +0000)]
Prevent 'removetrack' events from firing when all inband text tracks are removed.
https://bugs.webkit.org/show_bug.cgi?id=130704

Reviewed by Eric Carlson.

Source/WebCore:

Test: media/track/track-remove-track.html

Based on the Blink change (patch by acolwell@chromium.org):
https://codereview.chromium.org/177243018/

* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::prepareForLoad): Reorder steps to match W3C specification.
(WebCore::HTMLMediaElement::noneSupported): Forget tracks as required by specification.
(WebCore::HTMLMediaElement::mediaLoadingFailed): Forget tracks as required by specification.
(WebCore::HTMLMediaElement::removeTextTrack): Only request the 'removetracks' event if
requested by caller.
(WebCore::HTMLMediaElement::removeAllInbandTracks): Renamed to 'forgetResourceSpecificTracks'
(WebCore::HTMLMediaElement::noneSupported): Specify that we want the 'removetracks' event
fired for this use case.
(WebCore::HTMLMediaElement::prepareForLoad): Switch to new 'forgetResourceSpecificTracks' name.
* html/HTMLMediaElement.h:
* html/track/TextTrackList.cpp:
(TextTrackList::remove): Only fire the 'removetrack' event if the caller requests it.
* html/track/TextTrackList.h: Add default argument to fire the 'removetrack' event
when removing a track.
* html/track/TrackListBase.cpp:
(TrackListBase::remove): Only fire the 'removetrack' event if the caller requests it.
* html/track/TrackListBase.h: Add default argument to fire the 'removetrack' event.

LayoutTests:

Based on the Blink change (patch by acolwell@chromium.org):
https://codereview.chromium.org/177243018/

* media/track/track-remove-track-expected.txt: Added.
* media/track/track-remove-track.html: Added.

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

6 years agomedia/W3C/audio/canPlayType/canPlayType_application_octet_stream.html frequently...
ap@apple.com [Tue, 25 Mar 2014 16:44:33 +0000 (16:44 +0000)]
media/W3C/audio/canPlayType/canPlayType_application_octet_stream.html frequently fails on EWS
https://bugs.webkit.org/show_bug.cgi?id=130720

* platform/mac/TestExpectations: Marked as flaky.

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

6 years agoHold a reference to firstSuccessfulSubmitButton in HTMLFormElement::submit
ddkilzer@apple.com [Tue, 25 Mar 2014 16:42:15 +0000 (16:42 +0000)]
Hold a reference to firstSuccessfulSubmitButton in HTMLFormElement::submit
<http://webkit.org/b/130713>
<rdar://problem/15661876>

Reviewed by Darin Adler.

Merged from Blink (patch by Ian Beer):
http://crbug.com/303657
https://src.chromium.org/viewvc/blink?view=rev&revision=158938

Source/WebCore:

Test: fast/forms/form-submission-crash-successful-submit-button.html

* html/HTMLFormElement.cpp:
(WebCore::HTMLFormElement::submit):

LayoutTests:

* fast/forms/form-submission-crash-successful-submit-button-expected.txt: Added.
* fast/forms/form-submission-crash-successful-submit-button.html: Added.

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

6 years agoprepare-ChangeLog throws false positive warnings for modified files.
llango.u-szeged@partner.samsung.com [Tue, 25 Mar 2014 15:53:39 +0000 (15:53 +0000)]
prepare-ChangeLog throws false positive warnings for modified files.
https://bugs.webkit.org/show_bug.cgi?id=130687

Reviewed by Darin Adler.

* Scripts/prepare-ChangeLog:
(originalFile): Ignore git commit paremeter.
We don't need this to get the unmodified file.
(extractLineRangeBeforeChange):
Simplify the if statement. Follow-up after r166189.

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

6 years ago[ARM64] GCC generates wrong code with -O2 flag in WTF::weakCompareAndSwap
rgabor@webkit.org [Tue, 25 Mar 2014 14:13:07 +0000 (14:13 +0000)]
[ARM64] GCC generates wrong code with -O2 flag in WTF::weakCompareAndSwap
https://bugs.webkit.org/show_bug.cgi?id=130500

Reviewed by Filip Pizlo.

Set the first operand to the exact register in the inline assembly with GCC.

* wtf/Atomics.h:
(WTF::weakCompareAndSwap):

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

6 years ago[ARM64] GNU assembler fails in TransformationMatrix::multiply
rgabor@webkit.org [Tue, 25 Mar 2014 13:14:42 +0000 (13:14 +0000)]
[ARM64] GNU assembler fails in TransformationMatrix::multiply
https://bugs.webkit.org/show_bug.cgi?id=130454

Reviewed by Zoltan Herczeg.

Change the NEON intstructions to the proper style.

* platform/graphics/transforms/TransformationMatrix.cpp:
(WebCore::TransformationMatrix::multiply):

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

6 years ago[EFL] Add ARM64 build support
rgabor@webkit.org [Tue, 25 Mar 2014 13:08:29 +0000 (13:08 +0000)]
[EFL] Add ARM64 build support
https://bugs.webkit.org/show_bug.cgi?id=130506

Rubber stamped by Gyuyoung Kim.

.:

* CMakeLists.txt: Set WTF_CPU_ARM64 when aarch64 is defined.

Source/ThirdParty:

* leveldb/port/atomic_pointer.h: Set ARCH_CPU_ARM_FAMILY when __aarch64__ is defined.

Source/WTF:

* wtf/Platform.h: Set WTF_CPU_ARM64 when __aarch64__ is defined.

Tools:

* Scripts/webkitdirs.pm:
(isARM): Detect aarch64 as ARM.

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

6 years ago[CSS Grid Layout] Vertical rectangles not considered as valid grid areas
svillar@igalia.com [Tue, 25 Mar 2014 12:43:47 +0000 (12:43 +0000)]
[CSS Grid Layout] Vertical rectangles not considered as valid grid areas
https://bugs.webkit.org/show_bug.cgi?id=130513

Reviewed by Andreas Kling.

Source/WebCore:

Grid areas sized as vertical rectangles were incorrectly
considered as invalid by the parser. That's because the condition
checking that each new row was adjacent to the previous one was
using the first row of the currently parsed grid area instead of
the last one.

Test: fast/css-grid-layout/grid-template-areas-get-set.html

* css/CSSParser.cpp:
(WebCore::CSSParser::parseGridTemplateAreas):

LayoutTests:

Added tests for grid areas sized as horizontal and vertical
rectangles. The tests were also renamed from grid-template to
grid-template-areas which better describe their nature.

* fast/css-grid-layout/grid-template-areas-get-set-expected.txt: Renamed from LayoutTests/fast/css-grid-layout/grid-template-get-set-expected.txt.
* fast/css-grid-layout/grid-template-areas-get-set.html: Renamed from LayoutTests/fast/css-grid-layout/grid-template-get-set.html.

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

6 years ago[EFL][WK2] Add NETWORK_PROCESS build option
m.pakula@samsung.com [Tue, 25 Mar 2014 12:13:15 +0000 (12:13 +0000)]
[EFL][WK2] Add NETWORK_PROCESS build option
https://bugs.webkit.org/show_bug.cgi?id=130131

Reviewed by Gyuyoung Kim.

.:

Add option to build EFL port with NETWORK_PROCESS set on. By default NETWORK_PROCESS is
set off.

* Source/cmake/OptionsEfl.cmake:

Source/WebKit2:

* PlatformEfl.cmake: Add file needed to build with NETWORK_PROCESS enabled.

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

6 years ago[webkitpy] Improve _parse_bug_description to recognize more descriptions
commit-queue@webkit.org [Tue, 25 Mar 2014 12:13:03 +0000 (12:13 +0000)]
[webkitpy] Improve _parse_bug_description to recognize more descriptions
https://bugs.webkit.org/show_bug.cgi?id=130137

Patch by Eva Balazsfalvi <evab.u-szeged@partner.samsung.com> on 2014-03-25
Reviewed by Csaba Osztrogon√°c.

* Scripts/webkitpy/common/checkout/changelog.py:
(ChangeLogEntry._parse_bug_description):
* Scripts/webkitpy/common/checkout/changelog_unittest.py:
(test_parse_log_entries_from_changelog):
* Scripts/webkitpy/common/checkout/checkout_unittest.py:
(CheckoutTest.test_commit_info_for_revision):

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

6 years ago[EFL][WK2] Add an API to set process model
m.pakula@samsung.com [Tue, 25 Mar 2014 09:53:26 +0000 (09:53 +0000)]
[EFL][WK2] Add an API to set process model
https://bugs.webkit.org/show_bug.cgi?id=130133

Reviewed by Gyuyoung Kim.

Implement an API to set and get process model in ewk_context.
By default process model enum value is set to EWK_PROCESS_MODEL_SHARED_SECONDARY
which keeps current behaviour. Setting EWK_PROCESS_MODEL_MULTIPLE_SECONDARY
will make each web view use separate web process, also enables network process.

* UIProcess/API/efl/ewk_context.cpp:
(toWKProcessModel):
(EwkContext::setProcessModel):
(toEwkProcessModel):
(EwkContext::processModel):
(ewk_context_process_model_set):
(ewk_context_process_model_get):
* UIProcess/API/efl/ewk_context.h:
* UIProcess/API/efl/ewk_context_private.h:
* UIProcess/API/efl/tests/test_ewk2_context.cpp:
(TEST_F):

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

6 years ago[GTK] Volume slider shows below the panel with videos in certain cases
calvaris@igalia.com [Tue, 25 Mar 2014 09:10:32 +0000 (09:10 +0000)]
[GTK] Volume slider shows below the panel with videos in certain cases
https://bugs.webkit.org/show_bug.cgi?id=130608

Reviewed by Jer Noble.

Source/WebCore:

We need to delay the moment we check if the volume slider shows up
or down. If the video was not visible, the offsets were 0 and it
was forced to be shown below the panel.

Test: media/video-initially-hidden-volume-slider-up.html

* Modules/mediacontrols/mediaControlsApple.js:
(Controller.prototype.createControls): Moved volumebox pseudo from
the subclass. The test checks for it and it would fail in Mac.
* Modules/mediacontrols/mediaControlsGtk.js:
(ControllerGtk.prototype.createControls): Moved volumebox pseudo
to the superclass.
(ControllerGtk.prototype.handleMuteButtonMouseOver): Check if
volume slider should show up or down.
(ControllerGtk.prototype.updateReadyState): Removed check for
volume slider direction.

LayoutTests:

* media/video-initially-hidden-volume-slider-up-expected.txt: Added.
* media/video-initially-hidden-volume-slider-up.html: Added.

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

6 years agoAX: hit-testing doesn't always work correctly with WK2
cfleizach@apple.com [Tue, 25 Mar 2014 06:34:30 +0000 (06:34 +0000)]
AX: hit-testing doesn't always work correctly with WK2
https://bugs.webkit.org/show_bug.cgi?id=130706

Reviewed by Simon Fraser.

Accessibility code was trying to do screenToRootView itself, and in
some cases with embedded WK2 views that did not work.

* WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm:
(-[WKAccessibilityWebPageObject accessibilityHitTest:]):

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

6 years ago[Win] Enable WebVTT Regions on Windows.
bfulgham@apple.com [Tue, 25 Mar 2014 05:30:00 +0000 (05:30 +0000)]
[Win] Enable WebVTT Regions on Windows.
https://bugs.webkit.org/show_bug.cgi?id=130680

Reviewed by Eric Carlson.

Source/WebCore:

* DerivedSources.cpp: Add new build components.
* WebCore.vcxproj/WebCore.vcxproj: Ditto.
* WebCore.vcxproj/WebCore.vcxproj.filters: Ditto.

WebKitLibraries:

* win/tools/vsprops/FeatureDefines.props: Turn on WEBVTT_REGIONS
* win/tools/vsprops/FeatureDefinesCairo.props: Ditto.

LayoutTests:

* platform/win/TestExpectations: Turn on WebVTT tests.

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

6 years agoMore scaffolding for a stub routine to have a stub recursively embedded inside it
fpizlo@apple.com [Tue, 25 Mar 2014 03:44:52 +0000 (03:44 +0000)]
More scaffolding for a stub routine to have a stub recursively embedded inside it
https://bugs.webkit.org/show_bug.cgi?id=130770

Reviewed by Oliver Hunt.

* bytecode/CallLinkInfo.cpp:
(JSC::CallLinkInfo::unlink): VM& argument is superfluous.
(JSC::CallLinkInfo::visitWeak): Factor this out, it used to be in CodeBlock::finalizeUnconditionally().
* bytecode/CallLinkInfo.h:
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::finalizeUnconditionally): Factor out some functionality into CallLinkInfo::visitWeak(), and make sure we pass RepatchBuffer& in more places.
(JSC::CodeBlock::unlinkCalls):
(JSC::CodeBlock::unlinkIncomingCalls):
* bytecode/PolymorphicGetByIdList.cpp: Pass RepatchBuffer& through and call JITStubRoutine::visitWeak().
(JSC::GetByIdAccess::visitWeak):
(JSC::PolymorphicGetByIdList::visitWeak):
* bytecode/PolymorphicGetByIdList.h:
* bytecode/PolymorphicPutByIdList.cpp: Pass RepatchBuffer& through and call JITStubRoutine::visitWeak().
(JSC::PutByIdAccess::visitWeak):
(JSC::PolymorphicPutByIdList::visitWeak):
* bytecode/PolymorphicPutByIdList.h:
* bytecode/StructureStubInfo.cpp: Pass RepatchBuffer& through.
(JSC::StructureStubInfo::visitWeakReferences):
* bytecode/StructureStubInfo.h:
* jit/ClosureCallStubRoutine.cpp: isClosureCall is unused.
(JSC::ClosureCallStubRoutine::ClosureCallStubRoutine):
* jit/GCAwareJITStubRoutine.cpp:
(JSC::GCAwareJITStubRoutine::GCAwareJITStubRoutine):
(JSC::createJITStubRoutine):
* jit/GCAwareJITStubRoutine.h: Make it easier to construct one of these.
(JSC::GCAwareJITStubRoutine::isClosureCall): Deleted.
* jit/JITStubRoutine.cpp:
(JSC::JITStubRoutine::visitWeak): This will allow future JITStubRoutine subclasses to have stubs recursively embedded inside them.
* jit/JITStubRoutine.h:
* jit/Repatch.cpp:
(JSC::generateGetByIdStub): Fix a possible GC bug where we weren't making the stub routine GC aware.
(JSC::emitCustomSetterStub): Clean up some code.

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

6 years agoSafari crashes in JavaScriptCore: JSC::JSObject::growOutOfLineStorage
ggaren@apple.com [Tue, 25 Mar 2014 03:27:46 +0000 (03:27 +0000)]
Safari crashes in JavaScriptCore: JSC::JSObject::growOutOfLineStorage
when WebKit is compiled with fcatch-undefined-behavior
https://bugs.webkit.org/show_bug.cgi?id=130652

Reviewed by Mark Hahnenberg.

Use a static member function because the butterfly we pass in might be
NULL, and passing NULL to a member function is undefined behavior.

Stylistically, I think this new way reads a little more clearly, since it
matches createOrGrowArrayRight, and it helps to convey that m_butterfly
might not exist yet.

* runtime/Butterfly.h:
* runtime/ButterflyInlines.h:
(JSC::Butterfly::createOrGrowPropertyStorage): Renamed from growPropertyStorage
because we might create. Split out the create path to avoid using NULL
in a member function expression.

Removed some unused versions of this function.

* runtime/JSObject.cpp:
(JSC::JSObject::growOutOfLineStorage): Updated for interface change.

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

6 years agoStrict mode destructuring assignment crashes the parser.
oliver@apple.com [Tue, 25 Mar 2014 01:54:01 +0000 (01:54 +0000)]
Strict mode destructuring assignment crashes the parser.
https://bugs.webkit.org/show_bug.cgi?id=130538

Reviewed by Michael Saboff.

Source/JavaScriptCore:

The SyntaxChecker mode always return 1 for success, except
for a small subset of functions where we needed exact information.
This ends up just being a poor design decision as it means
the parser can get confused between a function return 1, and
the Resolve constant which was also 1. So we now use a unique
type for every creation method.

* parser/SyntaxChecker.h:
(JSC::SyntaxChecker::createSourceElements):
(JSC::SyntaxChecker::createFunctionBody):
(JSC::SyntaxChecker::createArguments):
(JSC::SyntaxChecker::createSpreadExpression):
(JSC::SyntaxChecker::createArgumentsList):
(JSC::SyntaxChecker::createPropertyList):
(JSC::SyntaxChecker::createElementList):
(JSC::SyntaxChecker::createFormalParameterList):
(JSC::SyntaxChecker::createClause):
(JSC::SyntaxChecker::createClauseList):
(JSC::SyntaxChecker::createFuncDeclStatement):
(JSC::SyntaxChecker::createBlockStatement):
(JSC::SyntaxChecker::createExprStatement):
(JSC::SyntaxChecker::createIfStatement):
(JSC::SyntaxChecker::createForLoop):
(JSC::SyntaxChecker::createForInLoop):
(JSC::SyntaxChecker::createForOfLoop):
(JSC::SyntaxChecker::createEmptyStatement):
(JSC::SyntaxChecker::createVarStatement):
(JSC::SyntaxChecker::createReturnStatement):
(JSC::SyntaxChecker::createBreakStatement):
(JSC::SyntaxChecker::createContinueStatement):
(JSC::SyntaxChecker::createTryStatement):
(JSC::SyntaxChecker::createSwitchStatement):
(JSC::SyntaxChecker::createWhileStatement):
(JSC::SyntaxChecker::createWithStatement):
(JSC::SyntaxChecker::createDoWhileStatement):
(JSC::SyntaxChecker::createLabelStatement):
(JSC::SyntaxChecker::createThrowStatement):
(JSC::SyntaxChecker::createDebugger):
(JSC::SyntaxChecker::createConstStatement):
(JSC::SyntaxChecker::appendConstDecl):
(JSC::SyntaxChecker::combineCommaNodes):
(JSC::SyntaxChecker::operatorStackPop):

LayoutTests:

Add tests

* js/parser-syntax-check-expected.txt:
* js/script-tests/parser-syntax-check.js:

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

6 years agoRemove some unnecessary includes from PlatformCALayerClient.h
simon.fraser@apple.com [Tue, 25 Mar 2014 01:21:04 +0000 (01:21 +0000)]
Remove some unnecessary includes from PlatformCALayerClient.h
https://bugs.webkit.org/show_bug.cgi?id=130703

Reviewed by Andreas Kling.

No need for all these #includes.

* platform/graphics/ca/PlatformCALayerClient.h:

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

6 years ago[core] FEGaussianBlur: use IntSize to simplify member function interface
cavalcantii@gmail.com [Tue, 25 Mar 2014 01:14:24 +0000 (01:14 +0000)]
[core] FEGaussianBlur: use IntSize to simplify member function interface
https://bugs.webkit.org/show_bug.cgi?id=130695

Reviewed by Dean Jackson.

By returning an IntSize to store the calculated kernel size values
it is possible to have less function parameters. This patch also
streamlines a bit the code in calculateUnscaledKernelSize.

No new tests, no change in behavior.

* platform/graphics/filters/FEDropShadow.cpp:
(WebCore::FEDropShadow::determineAbsolutePaintRect):
* platform/graphics/filters/FEGaussianBlur.cpp:
(WebCore::FEGaussianBlur::calculateUnscaledKernelSize):
(WebCore::FEGaussianBlur::calculateKernelSize):
(WebCore::FEGaussianBlur::determineAbsolutePaintRect):
(WebCore::FEGaussianBlur::platformApplySoftware):
* platform/graphics/filters/FEGaussianBlur.h:
(if): Deleted.
* platform/graphics/filters/FilterOperations.cpp:
(WebCore::outsetSizeForBlur):

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

6 years ago[WK2] SpinLock are not initialized by default, ViewUpdateDispatcher is missing an...
benjamin@webkit.org [Tue, 25 Mar 2014 00:54:27 +0000 (00:54 +0000)]
[WK2] SpinLock are not initialized by default, ViewUpdateDispatcher is missing an initializer
https://bugs.webkit.org/show_bug.cgi?id=130705

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-03-24
Reviewed by Simon Fraser.

* WebProcess/WebPage/ViewUpdateDispatcher.cpp:
(WebKit::ViewUpdateDispatcher::ViewUpdateDispatcher):

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

6 years agoWeb Replay: capture and replay keyboard events
bburg@apple.com [Tue, 25 Mar 2014 00:52:46 +0000 (00:52 +0000)]
Web Replay: capture and replay keyboard events
https://bugs.webkit.org/show_bug.cgi?id=130314

Reviewed by Joseph Pecoraro.

.:

* ManualTests/inspector/replay-keyboard-events.html: Added.

Source/WebCore:

Upstream support for capturing and replaying non-IME keyboard input.
This works similarly to mouse events. It introduces optional fields and
macros to encode/decode them.

Test: ManualTests/inspector/replay-keyboard-events.html

* replay/ReplayInputDispatchMethods.cpp:
(WebCore::HandleKeyPress::dispatch):
* replay/SerializationMethods.cpp:
(JSC::EncodingTraits<NondeterministicInputBase>::encodeValue):
(JSC::EncodingTraits<NondeterministicInputBase>::decodeValue): Switch existing
encode/decode calls to use the shortening macros.
(JSC::EncodingTraits<KeypressCommand>::encodeValue): Added.
(JSC::EncodingTraits<KeypressCommand>::decodeValue): Added.
(JSC::PlatformKeyboardEventAppKit::PlatformKeyboardEventAppKit): Subclass
PlatformKeyboardEvent so that we can set AppKit-specific members not
initialized through the main constructors.
(JSC::EncodingTraits<PlatformKeyboardEvent>::encodeValue): Added.
(JSC::EncodingTraits<PlatformKeyboardEvent>::decodeValue): Added.
* replay/SerializationMethods.h:
* replay/UserInputBridge.cpp:
(WebCore::UserInputBridge::UserInputBridge): initialize m_state inside a guard.
(WebCore::UserInputBridge::handleKeyEvent): fill in the implementation.
* replay/WebInputs.json:

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

6 years ago[iOS WebKit2] Dictation support.
enrica@apple.com [Mon, 24 Mar 2014 23:51:58 +0000 (23:51 +0000)]
[iOS WebKit2] Dictation support.
https://bugs.webkit.org/show_bug.cgi?id=130622
<rdar://problem/15337316>

Reviewed by Benjamin Poulain.

Adding support for dictation on iOS. There are two main types of interactions
with the dictation system:
- initial request for context, which consists in retrieving the selected text
and 5 words before the selection and 5 words after, if available.
- insertion of recognized chunks of text, providing the text
to replace.

* UIProcess/AutoCorrectionCallback.h:
(WebKit::DictationContextCallback::create):
(WebKit::DictationContextCallback::~DictationContextCallback):
(WebKit::DictationContextCallback::performCallbackWithReturnValue):
(WebKit::DictationContextCallback::invalidate):
(WebKit::DictationContextCallback::DictationContextCallback):
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView replaceDictatedText:withText:]):
(-[WKContentView requestDictationContext:]):
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::dictationContextCallback):
(WebKit::WebPageProxy::replaceDictatedText):
(WebKit::WebPageProxy::requestDictationContext):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::requestDictationContext):
(WebKit::WebPage::replaceDictatedText):

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

6 years agoOptimizing string construction for type error in JSNavigatorCustom.cpp
thiago.lacerda@openbossa.org [Mon, 24 Mar 2014 23:44:24 +0000 (23:44 +0000)]
Optimizing string construction for type error in JSNavigatorCustom.cpp
https://bugs.webkit.org/show_bug.cgi?id=130683

Reviewed by Eric Carlson.

* bindings/js/JSNavigatorCustom.cpp:
(WebCore::JSNavigator::webkitGetUserMedia):

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

6 years agoYet another iOS build fix, for the 32-bit build this time.
aestes@apple.com [Mon, 24 Mar 2014 23:30:01 +0000 (23:30 +0000)]
Yet another iOS build fix, for the 32-bit build this time.

* Shared/Downloads/ios/DownloadIOS.mm:
(WebKit::setUpDownloadClient):

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

6 years agoLegacy-style scrollbars constantly redraw after scrolling
bdakin@apple.com [Mon, 24 Mar 2014 23:23:22 +0000 (23:23 +0000)]
Legacy-style scrollbars constantly redraw after scrolling
https://bugs.webkit.org/show_bug.cgi?id=130699

Reviewed by Simon Fraser.

The constant re-draw was happening because we were never calling [ScrollbarPainter
setUsePresentationValue:NO]. This is a silly bug where were should have been
looking at PlatformWheelEvent::momentumPhase() instead of
PlatformWheelEvent::phase()

* page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
(WebCore::ScrollingTreeScrollingNodeMac::handleWheelEvent):

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

6 years agoFix the iOS build of TestWebKitAPI.
aestes@apple.com [Mon, 24 Mar 2014 23:21:50 +0000 (23:21 +0000)]
Fix the iOS build of TestWebKitAPI.

* TestWebKitAPI/Configurations/Base.xcconfig:
* TestWebKitAPI/PlatformUtilities.h:

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

6 years agoREGRESSION (r165872): Double-applying device scale to snapshots
timothy_horton@apple.com [Mon, 24 Mar 2014 23:14:22 +0000 (23:14 +0000)]
REGRESSION (r165872): Double-applying device scale to snapshots
https://bugs.webkit.org/show_bug.cgi?id=130697
<rdar://problem/16396629>

Reviewed by Simon Fraser.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::scaledSnapshotWithOptions):
Drive-by, make scaledSnapshotWithOptions respect SnapshotOptionsExcludeDeviceScaleFactor.

(WebKit::WebPage::snapshotAtSize):
Divide the device scale out of the scale factor

* WebProcess/WebPage/WebPage.h:
Rename the scale argument to scaledSnapshotWithOptions to clarify
that it is an additional scale on top of the device scale.

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

6 years agoXSS Auditor doesn't block <script> injected before an existing <script>
dbates@webkit.org [Mon, 24 Mar 2014 23:11:43 +0000 (23:11 +0000)]
XSS Auditor doesn't block <script> injected before an existing <script>
https://bugs.webkit.org/show_bug.cgi?id=130475

Merged from Blink (patch by Tom Sepez):
https://src.chromium.org/viewvc/blink?view=rev&revision=169697

Source/WebCore:

Tests: http/tests/security/xssAuditor/script-tag-expression-follows.html
       http/tests/security/xssAuditor/script-tag-near-start.html

* html/parser/XSSAuditor.cpp:
(WebCore::startsHTMLCommentAt):
(WebCore::startsSingleLineCommentAt):
(WebCore::startsMultiLineCommentAt):
(WebCore::startsOpeningScriptTagAt):
(WebCore::XSSAuditor::decodedSnippetForJavaScript):

LayoutTests:

* http/tests/security/xssAuditor/resources/echo-intertag.pl:
* http/tests/security/xssAuditor/script-tag-expression-follows-expected.txt: Added.
* http/tests/security/xssAuditor/script-tag-expression-follows.html: Added.
* http/tests/security/xssAuditor/script-tag-near-start-expected.txt: Added.
* http/tests/security/xssAuditor/script-tag-near-start.html: Added.

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

6 years agoActivate WebVTT Tests Once Merging is Complete
bfulgham@apple.com [Mon, 24 Mar 2014 23:01:56 +0000 (23:01 +0000)]
Activate WebVTT Tests Once Merging is Complete
https://bugs.webkit.org/show_bug.cgi?id=130420

Reviewed by Eric Carlson.

Source/JavaScriptCore:

* Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)

Source/WebCore:

* Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)

Source/WebKit/mac:

* Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)

Source/WebKit2:

* Configurations/FeatureDefines.xcconfig: Turn on ENABLE(WEBVTT_REGIONS)

LayoutTests:

* TestExpectations: Remove [Skip] for media/track/regions-webvtt
* platform/efl/TestExpectations: Skip media/track/regions-webvtt
* platform/gtk/TestExpectations: Skip media/track/regions-webvtt
* platform/mac/js/dom/global-constructors-attributes.html: Add new VTTRegions cases.
* platform/mac-mountainlion/js/dom/global-constructors-attributes.html: Ditto.
* platform/win/TestExpectations: Skip media/track/regions-webvtt

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

6 years agoRe-fix the build.
andersca@apple.com [Mon, 24 Mar 2014 22:59:47 +0000 (22:59 +0000)]
Re-fix the build.

* WebCore.exp.in:

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

6 years agoUpdate some mediastream LayoutTests results
thiago.lacerda@openbossa.org [Mon, 24 Mar 2014 22:51:45 +0000 (22:51 +0000)]
Update some mediastream LayoutTests results
https://bugs.webkit.org/show_bug.cgi?id=130692

Reviewed by Eric Carlson.

Tests were not passing due to outdated expected files.

* fast/mediastream/MediaStream-MediaElement-srcObject-expected.txt:
* fast/mediastream/MediaStreamTrack-expected.txt:
* fast/mediastream/RTCPeerConnection-ice-expected.txt:

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

6 years agoFix build.
andersca@apple.com [Mon, 24 Mar 2014 22:32:27 +0000 (22:32 +0000)]
Fix build.

* WebCore.exp.in:
Move a CFNetwork only symbol inside the USE(CFNETWORK) section.

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

6 years agoFix the iOS build.
aestes@apple.com [Mon, 24 Mar 2014 22:27:30 +0000 (22:27 +0000)]
Fix the iOS build.

* Shared/Downloads/ios/DownloadIOS.mm:
(WebKit::setUpDownloadClient):
* UIProcess/Cocoa/DownloadClient.mm:

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

6 years agomathml/presentation/tokenElements-background-color.html ImageOnlyFailure after 166170
commit-queue@webkit.org [Mon, 24 Mar 2014 21:54:52 +0000 (21:54 +0000)]
mathml/presentation/tokenElements-background-color.html ImageOnlyFailure after 166170
https://bugs.webkit.org/show_bug.cgi?id=130693

Patch by Martin Hock <mhock@apple.com> on 2014-03-24
Reviewed by Tim Horton.

* platform/mac/TestExpectations:

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

6 years agoBuild fix after r166186.
mrowe@apple.com [Mon, 24 Mar 2014 21:47:48 +0000 (21:47 +0000)]
Build fix after r166186.

* UIProcess/Cocoa/DownloadClient.mm:

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

6 years agoRegression: AX: Don't expose role or notifications for invalid menus
cfleizach@apple.com [Mon, 24 Mar 2014 21:26:25 +0000 (21:26 +0000)]
Regression: AX: Don't expose role or notifications for invalid menus
https://bugs.webkit.org/show_bug.cgi?id=129814

Reviewed by Mario Sanchez Prada.

Source/WebCore:

If a role=menu has no menuitem children, it should not be a menu.
This was a bit tricky to implement since we need to update the role after the children are created,
but it means we have to be a bit more aggressive about when to updateChildren, so that the role
is known to be valid.

Test: platform/mac/accessibility/invalid-menu-role-does-not-send-notification.html

* accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::notificationPostTimerFired):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::updateRoleAfterChildrenCreation):
(WebCore::AccessibilityRenderObject::addChildren):
* accessibility/AccessibilityRenderObject.h:
* accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
(-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):

LayoutTests:

* accessibility/table-with-aria-role.html:
     Modify test so that tests only what we want (that the role is correct).
     No longer use role=menu on the table, since the table won't have menuitems and won't be a valid menu.
* platform/mac/accessibility/invalid-menu-role-does-not-send-notification-expected.txt: Added.
* platform/mac/accessibility/invalid-menu-role-does-not-send-notification.html: Added.
* platform/mac/accessibility/table-with-aria-role-expected.txt:

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

6 years agoFix the iOS build.
aestes@apple.com [Mon, 24 Mar 2014 21:14:56 +0000 (21:14 +0000)]
Fix the iOS build.

* wtf/ThreadingPthreads.cpp:
(WTF::createThreadInternal):
(WTF::setCurrentThreadQOSUtility):

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

6 years agoStop pulling in all the macro assemblers from VM.h
akling@apple.com [Mon, 24 Mar 2014 21:03:46 +0000 (21:03 +0000)]
Stop pulling in all the macro assemblers from VM.h
<https://webkit.org/b/130691>

Remove #include of "GPRInfo.h". This breaks WebCore's dependency
on macro assemblers headers and removes 8 includes from every
.cpp file in the JS bindings.

Reviewed by Geoff Garen.

* runtime/VM.h:

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

6 years ago[WK2] Make updates on ViewUpdateDispatcher less heavy
benjamin@webkit.org [Mon, 24 Mar 2014 20:57:41 +0000 (20:57 +0000)]
[WK2] Make updates on ViewUpdateDispatcher less heavy
https://bugs.webkit.org/show_bug.cgi?id=130626

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-03-24
Reviewed by Darin Adler.

* WebProcess/WebPage/ViewUpdateDispatcher.cpp:
(WebKit::ViewUpdateDispatcher::visibleContentRectUpdate):
(WebKit::ViewUpdateDispatcher::dispatchVisibleContentRectUpdate):
* WebProcess/WebPage/ViewUpdateDispatcher.h:

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

6 years agoLazy load source code referred to from the source map, instead of when
timothy@apple.com [Mon, 24 Mar 2014 20:57:33 +0000 (20:57 +0000)]
Lazy load source code referred to from the source map, instead of when
the source code is revealed in the Resources sidebar.

https://bugs.webkit.org/show_bug.cgi?id=130625

Reviewed by Joseph Pecoraro.

* UserInterface/Models/SourceMapResource.js:
(WebInspector.SourceMapResource): Set up the type info here so it can be used to
dispaly the right icon in the sidebar.
(WebInspector.SourceMapResource.prototype.canRequestContentFromBackend): Use _contentRequested.
(WebInspector.SourceMapResource.prototype.requestContentFromBackend.sourceMapResourceLoaded):
Reset finished and remove the type change dance we had before.
* UserInterface/Views/SourceMapResourceTreeElement.js:
(WebInspector.SourceMapResourceTreeElement.prototype.onattach): Removed. Don't request content here.

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

6 years agoFix prepare-ChangeLog after r166156.
llango.u-szeged@partner.samsung.com [Mon, 24 Mar 2014 20:51:12 +0000 (20:51 +0000)]
Fix prepare-ChangeLog after r166156.
https://bugs.webkit.org/show_bug.cgi?id=130674

Reviewed by Darin Adler.

* Scripts/prepare-ChangeLog:
(generateFunctionLists):
(extractLineRangeBeforeChange):

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

6 years ago[iOS][WK2] Micro-optimize view state updates on the UIProcess side
benjamin@webkit.org [Mon, 24 Mar 2014 20:51:02 +0000 (20:51 +0000)]
[iOS][WK2] Micro-optimize view state updates on the UIProcess side
https://bugs.webkit.org/show_bug.cgi?id=130631

Patch by Benjamin Poulain <bpoulain@apple.com> on 2014-03-24
Reviewed by Darin Adler.

* UIProcess/API/Cocoa/WKWebView.mm:
(contentZoomScale):
[UIScrollView zoomScale] is not fast enough for -[WKWebView _updateVisibleContentRects]. Since we know what the zoom view is,
make a fast version hardcoding that.

(-[WKWebView _updateScrollViewBackground]):
(-[WKWebView _zoomToPoint:WebCore::atScale:]):
(-[WKWebView _scrollToRect:WebCore::origin:WebCore::minimumScrollDistance:]):
(-[WKWebView _zoomToRect:WebCore::withOrigin:WebCore::fitEntireRect:minimumScale:maximumScale:minimumScrollDistance:]):
(-[WKWebView _updateVisibleContentRects]):
* UIProcess/ios/WKContentView.mm:
(fixedPositionRectFromExposedRect):
(-[WKContentView didUpdateVisibleRect:unobscuredRect:scale:inStableState:]):

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

6 years agoRemove WebGL asset entitlement
dino@apple.com [Mon, 24 Mar 2014 20:29:54 +0000 (20:29 +0000)]
Remove WebGL asset entitlement
https://bugs.webkit.org/show_bug.cgi?id=130685

Reviewed by Simon Fraser.

No longer necessary on iOS.

* Configurations/WebContent-iOS.entitlements:

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

6 years ago[iOS] Download support by CFURLDownloadRef under USE(CFNETWORK).
aestes@apple.com [Mon, 24 Mar 2014 19:44:35 +0000 (19:44 +0000)]
[iOS] Download support by CFURLDownloadRef under USE(CFNETWORK).
https://bugs.webkit.org/show_bug.cgi?id=129322

Reviewed by Anders Carlsson.

Source/WebCore:

* platform/network/ResourceHandle.h:
* platform/network/cf/ResourceHandleCFNet.cpp:
(WebCore::ResourceHandle::releaseConnectionForDownload): Changed to
return a RetainPtr that adopts the connection's retain count.

Source/WebKit/mac:

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::convertMainResourceLoadToDownload): Use the
RetainPtr returned by releaseConnectionForDownload() rather than
manually releasing.

Source/WebKit2:

Based on an original patch by Yongjun Zhang  <yongjun_zhang@apple.com>.

* Shared/Cocoa/APIObject.mm:
(API::Object::newObject):
* Shared/Downloads/ios/DownloadIOS.mm:
(WebKit::dispatchOnMainThread):
(WebKit::toDownload):
(WebKit::setUpDownloadClient):
(WebKit::Download::startWithHandle):
* UIProcess/API/APIDownloadClient.h:
(API::DownloadClient::~DownloadClient):
* UIProcess/API/C/WKContext.cpp:
(WKContextSetDownloadClient):
* UIProcess/API/Cocoa/WKProcessPool.mm:
(-[WKProcessPool _downloadDelegate]):
(-[WKProcessPool _setDownloadDelegate:]):
* UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
* UIProcess/API/Cocoa/_WKDownload.h: Added.
* UIProcess/API/Cocoa/_WKDownload.mm: Added.
(WebKit::wrapper):
(WebKit::createAPIDownloadClient):
(-[_WKDownload dealloc]):
(-[_WKDownload API::]):
* UIProcess/API/Cocoa/_WKDownloadDelegate.h: Added.
* UIProcess/API/Cocoa/_WKDownloadInternal.h: Added.
* UIProcess/Cocoa/DownloadClient.h: Added.
* UIProcess/Cocoa/DownloadClient.mm: Added.
* WebKit2.xcodeproj/project.pbxproj:

Tools:

Add an API test suite for _WKDownload.

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKit2Cocoa/Download.mm: Added.
(-[DownloadDelegate initWithSourceURL:]):
(-[DownloadDelegate sourceURL]):
(-[DownloadDelegate _downloadDidStart:]):
(-[DownloadDelegate _download:didReceiveResponse:]):
(-[DownloadDelegate _download:didReceiveData:]):
(-[DownloadDelegate _download:decideDestinationWithSuggestedFilename:allowOverwrite:]):
(-[DownloadDelegate _downloadDidFinish:]):
(TEST):
(runTestWithNavigationDelegate):
(-[DownloadNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
(-[ConvertResponseToDownloadNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):

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

6 years agoAdd support for thread QoS
barraclough@apple.com [Mon, 24 Mar 2014 19:31:08 +0000 (19:31 +0000)]
Add support for thread QoS
https://bugs.webkit.org/show_bug.cgi?id=130688

Speculative EFL build fix.

* wtf/ThreadingPthreads.cpp:
(WTF::setCurrentThreadQOSUtility):

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

6 years agoAdd support for thread QoS
barraclough@apple.com [Mon, 24 Mar 2014 19:25:32 +0000 (19:25 +0000)]
Add support for thread QoS
https://bugs.webkit.org/show_bug.cgi?id=130688

Reviewed by Andreas Kling.

Source/JavaScriptCore:

* heap/BlockAllocator.cpp:
(JSC::BlockAllocator::blockFreeingThreadStartFunc):
    - block freeing is a utility activity.

Source/WTF:

* wtf/FastMalloc.cpp:
(WTF::TCMalloc_PageHeap::runScavengerThread):
    - block freeing is a utility activity.
* wtf/Threading.h:
    - declaration.
* wtf/ThreadingPthreads.cpp:
(WTF::createThreadInternal):
    - default to interactive.
(WTF::setCurrentThreadQOSUtility):
    - implementation.
* wtf/ThreadingWin.cpp:
(WTF::setCurrentThreadQOSUtility):
    - no-op implementation.

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

6 years ago<hr> should expose AXRole/AXSubrole, etc
cfleizach@apple.com [Mon, 24 Mar 2014 18:58:22 +0000 (18:58 +0000)]
<hr> should expose AXRole/AXSubrole, etc
https://bugs.webkit.org/show_bug.cgi?id=109015

Unreviewed. Update tests for ML platform.

* platform/mac-mountainlion/accessibility/lists-expected.txt:
* platform/mac-mountainlion/accessibility/roles-exposed-expected.txt:

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

6 years agoUpdate Hindi fallback font.
enrica@apple.com [Mon, 24 Mar 2014 18:56:30 +0000 (18:56 +0000)]
Update Hindi fallback font.
https://bugs.webkit.org/show_bug.cgi?id=130690
<rdar://problem/16391601>

Reviewed by Sam Weinig.

Using the new available font for Hindi in the fallback list.

* platform/graphics/ios/FontCacheIOS.mm:
(WebCore::FontCache::systemFallbackForCharacters):

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

6 years agoMerge Minor WebVTT Cleanups from Blink
bfulgham@apple.com [Mon, 24 Mar 2014 17:38:28 +0000 (17:38 +0000)]
Merge Minor WebVTT Cleanups from Blink
https://bugs.webkit.org/show_bug.cgi?id=130681

Reviewed by Eric Carlson.

Merged from Blink (patch by philipj@opera.com):
https://chromium.googlesource.com/chromium/blink/+/693eb5e2933dca0eab5bbd604e9f3406fe9fd1ab
http://crbug.com/52593009
https://chromium.googlesource.com/chromium/blink/+/40b3602feab34e9be829fd742b6ad6ded322a09f
http://crbug.com/104243003

* html/track/TextTrack.cpp:
(WebCore::TextTrack::setMode):
* html/track/TextTrack.idl:
* html/track/TextTrackCue.h:
* html/track/VTTCue.cpp:
(WebCore::VTTCue::VTTCue):
* html/track/VTTCue.h:

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

6 years agoUnreviewed, rolling out r166169.
fred.wang@free.fr [Mon, 24 Mar 2014 17:37:54 +0000 (17:37 +0000)]
Unreviewed, rolling out r166169.
https://bugs.webkit.org/show_bug.cgi?id=130682

This patch broke tests on Apple Mavericks (Requested by fredw
on #webkit).

Reverted changeset:

"Operator stretching: expose a math data API"
https://bugs.webkit.org/show_bug.cgi?id=130572
http://trac.webkit.org/changeset/166169

Patch by Commit Queue <commit-queue@webkit.org> on 2014-03-24

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

6 years agoUnreviewed, fix CLOOP build.
fpizlo@apple.com [Mon, 24 Mar 2014 17:29:51 +0000 (17:29 +0000)]
Unreviewed, fix CLOOP build.

* bytecode/CallLinkStatus.cpp:
(JSC::CallLinkStatus::computeFor):
* bytecode/CodeBlock.cpp:
(JSC::CodeBlock::printCallOp):
(JSC::CodeBlock::getCallLinkInfoForBytecodeIndex):
(JSC::CodeBlock::resetStubDuringGCInternal): Deleted.
* bytecode/CodeBlock.h:
(JSC::CodeBlock::callLinkInfosEnd): Deleted.

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