WebKit-https.git
5 months ago[ iOS wk2 Release ] fast/text-autosizing/ios/idempotentmode/viewport-change-relayout...
ryanhaddad@apple.com [Sat, 29 Feb 2020 00:47:42 +0000 (00:47 +0000)]
[ iOS wk2 Release ] fast/text-autosizing/ios/idempotentmode/viewport-change-relayout.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208245

Unreviewed test gardenign.

* platform/ios-wk2/TestExpectations: Remove flaky expectation since the test has been fixed.

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

5 months ago[GPUP] Implement Modern EME API in the GPU Process
jer.noble@apple.com [Sat, 29 Feb 2020 00:32:18 +0000 (00:32 +0000)]
[GPUP] Implement Modern EME API in the GPU Process
https://bugs.webkit.org/show_bug.cgi?id=208090

Reviewed by Alex Christensen.

IPC::SharedBufferDataReference is made more efficient by using the same encode/decode path as is used in
WebCoreArgumentCoders: the SharedBuffer is copied into shared memory, and only a handle is passed across
the XPC boundary. This requires existing users to handle receiving a IPC::SharedBufferDataHandle on the
remote side of the XPC boundary, but this is trivial, and many call sites require a SharedBuffer on the
remote side in the first place. This code could be improved by allowing the SharedMemory object be adopted
by the SharedBuffer object at creation time, potentially leading to zero-copy decoding, but is not done in
this patch.

* NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::bufferingTimerFired):
(WebKit::NetworkResourceLoader::sendBuffer):
* NetworkProcess/ServiceWorker/ServiceWorkerFetchTask.cpp:
(WebKit::ServiceWorkerFetchTask::didReceiveData):
(WebKit::ServiceWorkerFetchTask::didReceiveSharedBuffer):
* NetworkProcess/ServiceWorker/ServiceWorkerFetchTask.h:
* NetworkProcess/ServiceWorker/ServiceWorkerFetchTask.messages.in:
* Platform/IPC/HandleMessage.h:
* Platform/IPC/SharedBufferDataReference.h:
(IPC::SharedBufferDataReference::SharedBufferDataReference):
(IPC::SharedBufferDataReference::buffer):
(IPC::SharedBufferDataReference::buffer const):
(IPC::SharedBufferDataReference::data const):
(IPC::SharedBufferDataReference::size const):
(IPC::SharedBufferDataReference::isEmpty const):
(IPC::SharedBufferDataReference::encode const):
(IPC::SharedBufferDataReference::decode):
* Shared/WebCoreArgumentCoders.cpp:
(IPC::ArgumentCoder<RefPtr<WebCore::SharedBuffer>>::encode):
(IPC::ArgumentCoder<RefPtr<WebCore::SharedBuffer>>::decode):
* Shared/WebCoreArgumentCoders.h:
* UIProcess/Cocoa/WebPageProxyCocoa.mm:
(WebKit::WebPageProxy::platformRegisterAttachment):
* UIProcess/WebPageProxy.cpp:
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* WebProcess/Automation/WebAutomationSessionProxy.cpp:
* WebProcess/Network/WebResourceLoader.cpp:
(WebKit::WebResourceLoader::didReceiveSharedBuffer):
(WebKit::WebResourceLoader::didReceiveData):
* WebProcess/Network/WebResourceLoader.h:
* WebProcess/Network/WebResourceLoader.messages.in:
* WebProcess/Storage/WebServiceWorkerFetchTaskClient.cpp:
(WebKit::WebServiceWorkerFetchTaskClient::didReceiveData):
(WebKit::WebServiceWorkerFetchTaskClient::didReceiveBlobChunk):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::finishedLoadingIcon):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::getSelectionAsWebArchiveData):
(WebKit::WebPage::getWebArchiveOfFrame):
(WebKit::WebPage::drawPagesToPDF):
(WebKit::WebPage::urlSchemeTaskDidReceiveData):
(WebKit::WebPage::updateAttachmentAttributes):
* WebProcess/WebPage/WebPage.h:

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

5 months agoUnreviewed non-unified soures builds fix.
aperez@igalia.com [Sat, 29 Feb 2020 00:18:02 +0000 (00:18 +0000)]
Unreviewed non-unified soures builds fix.

* NetworkProcess/cache/NetworkCacheData.cpp:
(WebKit::NetworkCache::readOrMakeSalt): Add missing namespace to FileSystem::fileExists() call.

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

5 months ago[ macOS ] imported/w3c/web-platform-tests/dom/nodes/Document-characterSet-normalizati...
jacob_uphoff@apple.com [Sat, 29 Feb 2020 00:03:49 +0000 (00:03 +0000)]
[ macOS ] imported/w3c/web-platform-tests/dom/nodes/Document-characterSet-normalization.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=208394

Unreviewed test gardening.

* platform/mac-wk2/TestExpectations:

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

5 months agoClean up code with how we choose Gigacage sizes and whether or not to use Wasm fast...
sbarati@apple.com [Fri, 28 Feb 2020 23:59:26 +0000 (23:59 +0000)]
Clean up code with how we choose Gigacage sizes and whether or not to use Wasm fast memory
https://bugs.webkit.org/show_bug.cgi?id=208392

Reviewed by Yusuke Suzuki.

Source/bmalloc:

* bmalloc/Gigacage.h:

Source/JavaScriptCore:

* runtime/OptionsList.h:

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

5 months ago[ Mac wk2 ] http/tests/misc/object-embedding-svg-delayed-size-negotiation-2.htm is...
lawrence.j@apple.com [Fri, 28 Feb 2020 23:39:09 +0000 (23:39 +0000)]
[ Mac wk2 ] http/tests/misc/object-embedding-svg-delayed-size-negotiation-2.htm is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208396

Unreviewed test gardening.

* platform/mac-wk2/TestExpectations:

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

5 months ago[GPUP] Implement Modern EME API in the GPU Process
jer.noble@apple.com [Fri, 28 Feb 2020 23:20:03 +0000 (23:20 +0000)]
[GPUP] Implement Modern EME API in the GPU Process
https://bugs.webkit.org/show_bug.cgi?id=208090

Reviewed by Eric Carlson.

Source/WebCore:

To enable caching of certain CDM properties, allow them to be fetched rather than queries. As such,
CDMPrivate::supportsInitDataType -> supportedInitDataTypes, supportsRobustness -> supportedRobustnesses.

To enable CDM types to be passed across XPC, add explicit sizes to the enumerations, and add encode and
decode templates to the data types.

To enable async messaging form the GPU process's MediaPlayer, send the MediaPlayer the information it
needs when both legacy- and modern-EME APIs are both enabled, rather than allow the MediaPlayerPrivate
to query the MediaPlayer.

Move most of the algorithimic implementation from CDM into CDMPrivate, allowing it to be run from within
the GPU process. Similmarly, make most of the synchronous methods in CDMInstance instead take a callback
parameter, allowing them to be implemented in a remote process.

* Headers.cmake:
* Modules/encryptedmedia/CDM.cpp:
(WebCore::CDM::getSupportedConfiguration):
(WebCore::CDM::supportsInitDataType const):
* Modules/encryptedmedia/CDM.h:
* Modules/encryptedmedia/MediaKeySession.cpp:
(WebCore::MediaKeySession::update):
* Modules/encryptedmedia/MediaKeySystemAccess.cpp:
(WebCore::MediaKeySystemAccess::createMediaKeys):
* Modules/encryptedmedia/MediaKeys.cpp:
(WebCore::MediaKeys::setServerCertificate):
* Modules/encryptedmedia/MediaKeys.h:
* Modules/encryptedmedia/MediaKeys.idl:
* Sources.txt:
* WebCore.xcodeproj/project.pbxproj:
* html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::updateShouldContinueAfterNeedKey):
(WebCore::HTMLMediaElement::mediaPlayerKeyNeeded):
(WebCore::HTMLMediaElement::mediaEngineWasUpdated):
(WebCore::HTMLMediaElement::addEventListener):
(WebCore::HTMLMediaElement::removeEventListener):
* html/HTMLMediaElement.h:
* platform/encryptedmedia/CDMEncryptionScheme.h:
* platform/encryptedmedia/CDMFactory.cpp:
(WebCore::CDMFactory::resetFactories):
* platform/encryptedmedia/CDMFactory.h:
* platform/encryptedmedia/CDMInstance.h:
* platform/encryptedmedia/CDMInstanceSession.h:
* platform/encryptedmedia/CDMKeyStatus.h:
* platform/encryptedmedia/CDMKeySystemConfiguration.h:
(WebCore::CDMKeySystemConfiguration::encode const):
(WebCore::CDMKeySystemConfiguration::decode):
* platform/encryptedmedia/CDMMediaCapability.h:
(WebCore::CDMMediaCapability::encode const):
(WebCore::CDMMediaCapability::decode):
* platform/encryptedmedia/CDMMessageType.h:
* platform/encryptedmedia/CDMPrivate.cpp:
(WebCore::CDMPrivate::getSupportedConfiguration):
(WebCore::CDMPrivate::doSupportedConfigurationStep):
(WebCore::CDMPrivate::isPersistentType):
(WebCore::CDMPrivate::getSupportedCapabilitiesForAudioVideoType):
(WebCore::CDMPrivate::getConsentStatus):
* platform/encryptedmedia/CDMPrivate.h:
* platform/encryptedmedia/CDMRequirement.h:
* platform/encryptedmedia/CDMRestrictions.h:
(WebCore::CDMRestrictions::encode const):
(WebCore::CDMRestrictions::decode):
* platform/encryptedmedia/CDMSessionType.h:
* platform/encryptedmedia/clearkey/CDMClearKey.cpp:
(WebCore::CDMPrivateClearKey::supportedInitDataTypes const):
(WebCore::CDMPrivateClearKey::supportsSessionTypeWithConfiguration const):
(WebCore::CDMPrivateClearKey::supportedRobustnesses const):
(WebCore::CDMInstanceClearKey::initializeWithConfiguration):
(WebCore::CDMInstanceClearKey::setServerCertificate):
(WebCore::CDMInstanceClearKey::setStorageDirectory):
(WebCore::CDMInstanceSessionClearKey::updateLicense):
* platform/encryptedmedia/clearkey/CDMClearKey.h:
* platform/graphics/MediaPlayer.cpp:
(WebCore::MediaPlayer::setShouldContinueAfterKeyNeeded):
(WebCore::MediaPlayer::keyNeeded):
* platform/graphics/MediaPlayer.h:
(WebCore::MediaPlayerClient::mediaPlayerKeyNeeded):
* platform/graphics/MediaPlayerPrivate.h:
(WebCore::MediaPlayerPrivateInterface::setShouldContinueAfterKeyNeeded):
* platform/graphics/avfoundation/CDMFairPlayStreaming.cpp:
(WebCore::CDMPrivateFairPlayStreaming::supportedInitDataTypes const):
(WebCore::CDMPrivateFairPlayStreaming::supportsSessionTypeWithConfiguration const):
(WebCore::CDMPrivateFairPlayStreaming::supportedRobustnesses const):
(WebCore::CDMPrivateFairPlayStreaming::supportsInitData const):
* platform/graphics/avfoundation/CDMFairPlayStreaming.h:
* platform/graphics/avfoundation/cf/MediaPlayerPrivateAVFoundationCF.cpp:
(WebCore::AVFWrapper::shouldWaitForLoadingOfResource):
* platform/graphics/avfoundation/objc/CDMInstanceFairPlayStreamingAVFObjC.h:
* platform/graphics/avfoundation/objc/CDMInstanceFairPlayStreamingAVFObjC.mm:
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::initializeWithConfiguration):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::setServerCertificate):
(WebCore::CDMInstanceFairPlayStreamingAVFObjC::setStorageDirectory):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::updateLicense):
(WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::sessionIdentifierChanged):
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::shouldWaitForLoadingOfResource):
* testing/MockCDMFactory.cpp:
(WebCore::MockCDMFactory::setSupportedRobustness):
(WebCore::MockCDM::supportedInitDataTypes const):
(WebCore::MockCDM::supportedRobustnesses const):
(WebCore::MockCDM::supportsSessionTypeWithConfiguration const):
(WebCore::MockCDM::supportsInitData const):
(WebCore::MockCDMInstance::initializeWithConfiguration):
(WebCore::MockCDMInstance::setServerCertificate):
(WebCore::MockCDMInstance::setStorageDirectory):
(WebCore::MockCDMInstanceSession::updateLicense):
* testing/MockCDMFactory.h:
(WebCore::MockCDMFactory::supportedRobustness const):

Source/WebKit:

Adopt changes to MediaPlayerProxy.

* GPUProcess/media/RemoteMediaPlayerProxy.cpp:
(WebKit::RemoteMediaPlayerProxy::mediaPlayerKeyNeeded):
* GPUProcess/media/RemoteMediaPlayerProxy.h:
* WebProcess/GPU/media/WebMediaStrategy.cpp:
(WebKit::WebMediaStrategy::registerCDMFactories):
* WebProcess/GPU/media/WebMediaStrategy.h:

Source/WebKitLegacy/mac:

Adopt changes to PlatformStrategies.

* GPUProcess/media/RemoteMediaPlayerProxy.cpp:
(WebKit::RemoteMediaPlayerProxy::mediaPlayerKeyNeeded):
* GPUProcess/media/RemoteMediaPlayerProxy.h:
* WebCoreSupport/WebPlatformStrategies.mm:

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

5 months agomacCatalyst: 'Open' context menu item doesn't work
timothy_horton@apple.com [Fri, 28 Feb 2020 22:24:32 +0000 (22:24 +0000)]
macCatalyst: 'Open' context menu item doesn't work
https://bugs.webkit.org/show_bug.cgi?id=208388
<rdar://problem/59820273>

Reviewed by Wenson Hsieh.

* UIProcess/ios/WKContentViewInteraction.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView cleanupInteraction]):
(-[WKContentView _webTouchEventsRecognized:]):
(-[WKContentView _doubleTapRecognizedForDoubleClick:]):
(-[WKContentView _singleTapRecognized:]):
(-[WKContentView _attemptClickAtLocation:modifierFlags:]):
(-[WKContentView _mouseGestureRecognizerChanged:]):
In r178980, a mechanism was introduced to ensure that synthetic clicks are
only dispatched to the page that the user originally touched.

macCatalyst's WKMouseGestureRecognizer unintentionally entirely bypassed
this mechanism, never setting _layerTreeTransactionIdAtLastTouchStart,
because the touch event gesture recognizer is disabled. This was generally
fine because in this case, we don't need to send synthetic clicks,
instead sending proper mouse events.

However, the "Open" context menu item works by sending a synthetic click
at the original interaction location. Since we did not set
_layerTreeTransactionIdAtLastTouchStart, the Web Content process will
ignore the click, and perform no action.

Fix this by also setting _layerTreeTransactionIdAtLastTouchStart
on mouseDown.

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

5 months ago[ Mojave wk2 Debug ] fast/css-custom-paint/delay-repaint.html is flaky failing.
lawrence.j@apple.com [Fri, 28 Feb 2020 21:42:06 +0000 (21:42 +0000)]
[ Mojave wk2 Debug ] fast/css-custom-paint/delay-repaint.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208390

Unreviewed test gardening.

* platform/mac-wk2/TestExpectations:

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

5 months agoClear FontDatabase when low-memory-warning happens
ysuzuki@apple.com [Fri, 28 Feb 2020 21:39:06 +0000 (21:39 +0000)]
Clear FontDatabase when low-memory-warning happens
https://bugs.webkit.org/show_bug.cgi?id=208389

Reviewed by Chris Dumez.

FontDatabase can monotonically increase. We should clear it when low-memory-warning happens.

* platform/graphics/cocoa/FontCacheCoreText.cpp:
(WebCore::FontCache::platformPurgeInactiveFontData):

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

5 months ago[Curl] Add TLS debugging feature to log encryption keys
commit-queue@webkit.org [Fri, 28 Feb 2020 21:35:09 +0000 (21:35 +0000)]
[Curl] Add TLS debugging feature to log encryption keys
https://bugs.webkit.org/show_bug.cgi?id=208192

Patch by Takashi Komori <Takashi.Komori@sony.com> on 2020-02-28
Reviewed by Fujii Hironori.

This patch enables recording encryption keys on curl port.
When you set key log file path to environment variable SSLKEYLOGFILE on curl port, network process writes encryption keys into the path.
The key log file follows the NSS key log format and this feature is as same as Chrome and Firefox have.

See also: https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Key_Log_Format

Test: No tests for this debugging feature. We have to check manually if the log file is generate.

.:

* Source/cmake/OptionsPlayStation.cmake:
* Source/cmake/OptionsWin.cmake:

Source/WebCore:

* platform/network/curl/CurlContext.cpp:
(WebCore::CurlContext::CurlContext):
* platform/network/curl/CurlContext.h:
(WebCore::CurlContext::shouldLogTLSKey const):
(WebCore::CurlContext::tlsKeyLogFilePath const):
* platform/network/curl/CurlSSLVerifier.cpp:
(WebCore::CurlSSLVerifier::CurlSSLVerifier):
(WebCore::CurlSSLVerifier::infoCallback):
(WebCore::CurlSSLVerifier::logTLSKey):
* platform/network/curl/CurlSSLVerifier.h:

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

5 months agoMediaResourceLoader leaks resource responses
cdumez@apple.com [Fri, 28 Feb 2020 21:23:53 +0000 (21:23 +0000)]
MediaResourceLoader leaks resource responses
https://bugs.webkit.org/show_bug.cgi?id=208267

Reviewed by Eric Carlson.

MediaResourceLoader leaks resource responses when browsing in Safari, even though these responses are
only used for testing. AVAssetCustomURLBridgeForNSURLSession holds on to the WebCoreNSURLSession, which
keeps the MediaResourceLoader alive, even if there is no media on the current page. In turn, the
MediaResourceLoader always keeps in memory the last 5 HTTP responses.

To address the issue, we now only record these responses when running the tests.

* loader/MediaResourceLoader.cpp:
(WebCore::MediaResourceLoader::recordResponsesForTesting):
(WebCore::MediaResourceLoader::addResponseForTesting):
* loader/MediaResourceLoader.h:
* testing/Internals.cpp:
(WebCore::Internals::resetToConsistentState):

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

5 months agoEWS fails to retry build in case of kill-old-processes exception
aakash_jain@apple.com [Fri, 28 Feb 2020 21:07:27 +0000 (21:07 +0000)]
EWS fails to retry build in case of kill-old-processes exception
https://bugs.webkit.org/show_bug.cgi?id=208003

Reviewed by Jonathan Bedard.

* BuildSlaveSupport/ews-build/steps.py:
(KillOldProcesses.evaluateCommand):
(KillOldProcesses.getResultSummary):

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

5 months ago[ews] commit-queue should update the ChangeLog with Reviewer name
aakash_jain@apple.com [Fri, 28 Feb 2020 20:23:10 +0000 (20:23 +0000)]
[ews] commit-queue should update the ChangeLog with Reviewer name
https://bugs.webkit.org/show_bug.cgi?id=206535

Reviewed by Jonathan Bedard.

* BuildSlaveSupport/ews-build/steps.py:
(ApplyPatch.start): Update the patch with the patch reviewer name if available.

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

5 months agoDeflake animations/font-variations tests
ap@apple.com [Fri, 28 Feb 2020 20:21:29 +0000 (20:21 +0000)]
Deflake animations/font-variations tests
https://bugs.webkit.org/show_bug.cgi?id=208383

Reviewed by Ryosuke Niwa.

Use document.fonts.ready to work around https://bugs.webkit.org/show_bug.cgi?id=208382,
and to simplify the tests.

* animations/font-variations/font-stretch.html:
* animations/font-variations/font-style.html:
* animations/font-variations/font-variation-settings-order.html:
* animations/font-variations/font-variation-settings-unlike.html:
* animations/font-variations/font-variation-settings.html:
* animations/font-variations/font-weight.html:

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

5 months ago[ iOS wk2 Release ] fast/text-autosizing/ios/idempotentmode/viewport-change-relayout...
mmaxfield@apple.com [Fri, 28 Feb 2020 20:11:27 +0000 (20:11 +0000)]
[ iOS wk2 Release ] fast/text-autosizing/ios/idempotentmode/viewport-change-relayout.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208245
<rdar://problem/59856625>

The test was still actually passing, it was just displaying differently.
Change the test to be more robust.

Unreviewed test gardening.

* fast/text-autosizing/ios/idempotentmode/viewport-change-relayout-expected.html: Removed.
* fast/text-autosizing/ios/idempotentmode/viewport-change-relayout-expected.txt: Added.
* fast/text-autosizing/ios/idempotentmode/viewport-change-relayout.html:

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

5 months ago[iOS] Remove access to the "com.apple.lsd.open" mach service from the WebContent...
bfulgham@apple.com [Fri, 28 Feb 2020 19:57:50 +0000 (19:57 +0000)]
[iOS] Remove access to the "com.apple.lsd.open" mach service from the WebContent process
https://bugs.webkit.org/show_bug.cgi?id=207708
<rdar://problem/56995506>

Reviewed by Per Arne Vollan.

Now that we dynamically create the sandbox extension to the 'com.apple.lsd.open' mach service,
we can remove the global allow rule from the sandbox.

Reviewed by Per Arne Vollan.

* Resources/SandboxProfiles/ios/com.apple.WebKit.GPU.sb:
* Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:

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

5 months agoFix issue in cmake build for checking ccache
keith_miller@apple.com [Fri, 28 Feb 2020 19:55:17 +0000 (19:55 +0000)]
Fix issue in cmake build for checking ccache
https://bugs.webkit.org/show_bug.cgi?id=208377

Reviewed by Carlos Alberto Lopez Perez.

If either of the "readlink" or "which" commands fail when looking for the ccache prefix
the output variables will be empty and an invalid expression will be provided to CMake.
e.g. we will get something like:
if ("0" "EQUAL" "0" "AND" "1" "EQUAL" "0" "AND" "STREQUAL" "/usr/local/bin/ccache")

The fix is to wrap the output variables in the quotes when unboxing them in the if.

* Source/cmake/WebKitCCache.cmake:

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

5 months agoConvert frame address in logging statements to pageID+frameID
krollin@apple.com [Fri, 28 Feb 2020 19:43:33 +0000 (19:43 +0000)]
Convert frame address in logging statements to pageID+frameID
https://bugs.webkit.org/show_bug.cgi?id=208325
<rdar://problem/59850768>

Reviewed by Alex Christensen.

Some old logging prints the address of the associated frame object.
Annotating logging statements this way makes it difficult to match up
that logging with other logging that uses pageID+frameID. Update the
logging to consistently use the latter format.

Source/WebCore:

No new tests -- no new or changed functionality.

* loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::setRequest):
(WebCore::DocumentLoader::setMainDocumentError):
(WebCore::DocumentLoader::mainReceivedError):
(WebCore::DocumentLoader::stopLoading):
(WebCore::DocumentLoader::notifyFinished):
(WebCore::DocumentLoader::willSendRequest):
(WebCore::DocumentLoader::tryLoadingSubstituteData):
(WebCore::DocumentLoader::disallowDataRequest const):
(WebCore::DocumentLoader::continueAfterContentPolicy):
(WebCore::DocumentLoader::startLoadingMainResource):
(WebCore::DocumentLoader::loadMainResource):
(WebCore::DocumentLoader::cancelMainResourceLoad):
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::pageID const):
(WebCore::FrameLoader::frameID const):
(WebCore::FrameLoader::retryAfterFailedCacheOnlyMainResourceLoad):
* loader/FrameLoader.h:
* loader/ResourceLoader.cpp:
* loader/SubresourceLoader.cpp:
* loader/cache/CachedResource.cpp:
(WebCore::CachedResource::load):
* loader/cache/CachedResourceLoader.cpp:
(WebCore::CachedResourceLoader::requestResource):
* page/Frame.cpp:
(WebCore::Frame::pageID const):
(WebCore::Frame::frameID const):
* page/Frame.h:
* page/FrameView.cpp:

Source/WebKit:

* WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::loadResource):

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

5 months agorun-javascriptcore-tests: Make upload format valid
jbedard@apple.com [Fri, 28 Feb 2020 19:31:30 +0000 (19:31 +0000)]
run-javascriptcore-tests: Make upload format valid
https://bugs.webkit.org/show_bug.cgi?id=208341

Rubber-stamped by Aakash Jain.

* Scripts/run-javascriptcore-tests:
(uploadResults): Remove. FIXME.
* Scripts/webkitdirs.pm:
(splitVersionString): Handle case where the subminor version number has a - in it.
* Scripts/webkitperl/webkitdirs_unittest/splitVersion.pl: Add unit tests.

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

5 months ago[ Mac wk1 ] imported/w3c/web-platform-tests/requestidlecallback/callback-timeout...
lawrence.j@apple.com [Fri, 28 Feb 2020 19:29:29 +0000 (19:29 +0000)]
[ Mac wk1 ] imported/w3c/web-platform-tests/requestidlecallback/callback-timeout-when-busy.html is flakey failing.
https://bugs.webkit.org/show_bug.cgi?id=208384

Unreviewed test gardening.

* platform/mac-wk1/TestExpectations:

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

5 months agoStop using -[CALayer setValue:forKey:] to store back pointers to PlatformCALayer*
simon.fraser@apple.com [Fri, 28 Feb 2020 19:23:19 +0000 (19:23 +0000)]
Stop using -[CALayer setValue:forKey:] to store back pointers to PlatformCALayer*
https://bugs.webkit.org/show_bug.cgi?id=208358

Reviewed by Tim Horton.

We used -[CAlayer setValue:forKey:@"WKPlatformCALayer"] to store associate PlatformCALayer*
with CALayers. However, this has some performance cost, and won't work for a near-future world
where the scrolling thread needs to get at PlatformCALayers.

Replace with a static HashMap<> of CALayer* to PlatformCALayer*. Also rename platformCALayer()
to platformCALayerForLayer() so it's easier to find.

Source/WebCore:

* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::setContentsToPlatformLayer):
* platform/graphics/ca/PlatformCALayer.h:
* platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
(WebCore::layerToPlatformLayerMap):
(WebCore::PlatformCALayer::platformCALayerForLayer):
(WebCore::PlatformCALayerCocoa::create):
(WebCore::PlatformCALayerCocoa::commonInit):
(WebCore::PlatformCALayerCocoa::~PlatformCALayerCocoa):
(WebCore::PlatformCALayerCocoa::superlayer const):
(WebCore::PlatformCALayer::platformCALayer): Deleted.
* platform/graphics/ca/win/PlatformCALayerWin.cpp:
(PlatformCALayer::platformCALayerForLayer):
(layoutSublayersProc):
(PlatformCALayerWin::superlayer const):
(PlatformCALayer::platformCALayer): Deleted.
* platform/graphics/ca/win/PlatformCALayerWinInternal.cpp:
(PlatformCALayerWinInternal::getSublayers const):
(PlatformCALayerWinInternal::sublayerAtIndex const):
* platform/graphics/cocoa/WebGLLayer.mm:
(-[WebGLLayer display]):
* platform/graphics/mac/WebLayer.mm:
(-[WebLayer drawInContext:]):
(-[WebSimpleLayer setNeedsDisplay]):
(-[WebSimpleLayer setNeedsDisplayInRect:]):
(-[WebSimpleLayer display]):
(-[WebSimpleLayer drawInContext:]):

Source/WebKitLegacy/win:

* FullscreenVideoController.cpp:
(FullscreenVideoController::LayerClient::platformCALayerLayoutSublayersOfLayer):
(FullscreenVideoController::enterFullscreen):

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

5 months agoNo port uses USE_NATIVE_FULLSCREEN_VIDEO, remove it
eric.carlson@apple.com [Fri, 28 Feb 2020 19:18:26 +0000 (19:18 +0000)]
No port uses USE_NATIVE_FULLSCREEN_VIDEO, remove it
https://bugs.webkit.org/show_bug.cgi?id=208378
<rdar://problem/59892497>

Reviewed by Jer Noble.

Source/WebCore:

No new tests, unused code removed.

* dom/FullscreenManager.cpp:
(WebCore::FullscreenManager::willEnterFullscreen):
* platform/graphics/MediaPlayer.cpp:
(WebCore::MediaPlayer::enterFullscreen): Deleted.
(WebCore::MediaPlayer::exitFullscreen): Deleted.
(WebCore::MediaPlayer::canEnterFullscreen const): Deleted.
* platform/graphics/MediaPlayer.h:
* platform/graphics/MediaPlayerPrivate.h:
(WebCore::MediaPlayerPrivateInterface::enterFullscreen): Deleted.
(WebCore::MediaPlayerPrivateInterface::exitFullscreen): Deleted.
(WebCore::MediaPlayerPrivateInterface::canEnterFullscreen const): Deleted.

Source/WebKit:

* WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:
(WebKit::MediaPlayerPrivateRemote::setClosedCaptionsVisible):
(WebKit::MediaPlayerPrivateRemote::enterFullscreen): Deleted.
(WebKit::MediaPlayerPrivateRemote::exitFullscreen): Deleted.
(WebKit::MediaPlayerPrivateRemote::canEnterFullscreen const): Deleted.
* WebProcess/GPU/media/MediaPlayerPrivateRemote.h:

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

5 months ago[iOS] Unblock read access to aes_0 device
bfulgham@apple.com [Fri, 28 Feb 2020 19:12:23 +0000 (19:12 +0000)]
[iOS] Unblock read access to aes_0 device
https://bugs.webkit.org/show_bug.cgi?id=208344
<rdar://problem/59746108>

Reviewed by Alexey Proskuryakov.

Logging needs access to /dev/aes_0 to generate random identifiers. We should unblock this service.

* Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:

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

5 months ago[MacOS/iOS] Enable audio/video capture in GPUProcess by default
youenn@apple.com [Fri, 28 Feb 2020 18:49:47 +0000 (18:49 +0000)]
[MacOS/iOS] Enable audio/video capture in GPUProcess by default
https://bugs.webkit.org/show_bug.cgi?id=208130

Reviewed by Eric Carlson.

Source/WebKit:

Covered by existing tests.

* Shared/WebPreferences.yaml:
* Shared/WebPreferencesDefaultValues.h:
* WebProcess/cocoa/UserMediaCaptureManager.cpp:
(WebKit::UserMediaCaptureManager::cloneVideoSource):
Make sure to select the process of the source to clone it.

Tools:

* WebKitTestRunner/TestOptions.h:
Use GPU process to capture by default.
We will remove this option once done verifying that every test works smoothly.

LayoutTests:

Disable video capture in GPUProcess as cloning mechanism does not work well with the idea of a single video or audio source in a process.
A follow-up patch should fix this.

* fast/mediastream/MediaStream-clone.html:
* fast/mediastream/MediaStreamTrack-clone.html:
* fast/mediastream/mediastreamtrack-video-clone.html:
* webrtc/multi-video.html:

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

5 months agoRegression r257612: Windows build broken
eric.carlson@apple.com [Fri, 28 Feb 2020 18:14:06 +0000 (18:14 +0000)]
Regression r257612: Windows build broken
https://bugs.webkit.org/show_bug.cgi?id=208372
<rdar://problem/59885001>

Unreviewed Windows build fix.

* platform/graphics/InbandGenericCue.cpp:
(WebCore::InbandGenericCue::toJSONString const):

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

5 months agoupdateCSSTransitionsForElementAndProperty should clone RenderStyles
dino@apple.com [Fri, 28 Feb 2020 17:33:48 +0000 (17:33 +0000)]
updateCSSTransitionsForElementAndProperty should clone RenderStyles
https://bugs.webkit.org/show_bug.cgi?id=208356
rdar://59869560

Reviewed by Antti Koivisto.

Make ownership of the local variable clear by cloning the RenderStyles
used in updateCSSTransitionsForElementAndProperty rather than referencing
different versions.

* animation/AnimationTimeline.cpp:
(WebCore::AnimationTimeline::updateCSSTransitionsForElementAndProperty):

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

5 months agoRetain cycle between CSSFontSelector -> CSSFontFaceSet -> CSSFontFace -> CSSFontSelector
cdumez@apple.com [Fri, 28 Feb 2020 16:47:08 +0000 (16:47 +0000)]
Retain cycle between CSSFontSelector -> CSSFontFaceSet -> CSSFontFace -> CSSFontSelector
https://bugs.webkit.org/show_bug.cgi?id=196437
<rdar://problem/46598332>

Reviewed by Alex Christensen.

Break the reference cycle using a WeakPtr. The leak was reproducible by browsing CNN.com
and then navigating to about:blank (those objects would stay around, even after memory
pressure signal).

* css/CSSFontFace.cpp:
(WebCore::CSSFontFace::CSSFontFace):
(WebCore::CSSFontFace::fontLoadEventOccurred):
* css/CSSFontFace.h:

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

5 months ago[SOUP] Unreviewed. Fix unused parameter warning
berto@igalia.com [Fri, 28 Feb 2020 15:48:42 +0000 (15:48 +0000)]
[SOUP] Unreviewed. Fix unused parameter warning

* platform/network/soup/NetworkStorageSessionSoup.cpp:
(WebCore::NetworkStorageSession::getRawCookies const):

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

5 months agoShrink-to-fit Display::LineBox/Display::Run vectors.
ysuzuki@apple.com [Fri, 28 Feb 2020 15:21:29 +0000 (15:21 +0000)]
Shrink-to-fit Display::LineBox/Display::Run vectors.
https://bugs.webkit.org/show_bug.cgi?id=208343

Reviewed by Antti Koivisto.

From the collected data in PLT5, 95% of Runs / LineBoxes are <= 4, while we are having 10 and 5 inlineCapacity.
We adjust this inlineCapacity to 4 based on this number. It also covers almost all of Speedometer2.0 content (in it, 99.9% is 1).
We also call `shrinkToFit` to make it the exact size after baking Display::InlineContent. It should be no-op in 95% cases.

* layout/displaytree/DisplayInlineContent.h:
* layout/inlineformatting/InlineFormattingState.h:
(WebCore::Layout::InlineFormattingState::shrinkDisplayInlineContent):
* layout/integration/LayoutIntegrationLineLayout.cpp:
(WebCore::LayoutIntegration::LineLayout::layout):

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

5 months ago[ews] commit queue should skip building and testing for rollout patches
aakash_jain@apple.com [Fri, 28 Feb 2020 14:11:59 +0000 (14:11 +0000)]
[ews] commit queue should skip building and testing for rollout patches
https://bugs.webkit.org/show_bug.cgi?id=208329

Reviewed by Jonathan Bedard.

* BuildSlaveSupport/ews-build/steps.py:
(BugzillaMixin._is_patch_obsolete): Set rollout property appropriately.
(CompileWebKit.doStepIf): Skip tests for rollout patches on commit-queue.
(RunWebKit1Tests.doStepIf): Ditto.
* BuildSlaveSupport/ews-build/steps_unittest.py:
(TestCompileWebKit.test_skip_for_rollout_patches_on_commit_queue): Added unit-test.
(TestRunWebKit1Tests.test_skip_for_rollout_patches_on_commit_queue): Ditto.

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

5 months ago[GStreamer] Unreviewed. Fix build warning.
berto@igalia.com [Fri, 28 Feb 2020 13:32:36 +0000 (13:32 +0000)]
[GStreamer] Unreviewed. Fix build warning.

queueSize is of type size_t so it should use the proper format
specifier.

* platform/graphics/gstreamer/WebKitWebSourceGStreamer.cpp:
(restartLoaderIfNeeded):
(stopLoaderIfNeeded):

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

5 months ago[GTK] Gardening, update TestExpectations
dpino@igalia.com [Fri, 28 Feb 2020 13:01:54 +0000 (13:01 +0000)]
[GTK] Gardening, update TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=208371

Unreviewed gardening.

* platform/gtk/TestExpectations:

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

5 months agoConversion between MediaSample and RemoteVideoSample should preserve the rotation...
youenn@apple.com [Fri, 28 Feb 2020 11:28:35 +0000 (11:28 +0000)]
Conversion between MediaSample and RemoteVideoSample should preserve the rotation information
https://bugs.webkit.org/show_bug.cgi?id=208240

Reviewed by Eric Carlson.

Source/WebCore:

Update RemoteVideoSample to have surface getter be const.
Add a new routine to convert a RemoteVideoSample in a MediaSample, with proper rotation and mirrored information.
Covered by manual testing.

* platform/graphics/RemoteVideoSample.cpp:
(WebCore::RemoteVideoSample::surface const):
* platform/graphics/RemoteVideoSample.h:
(WebCore::RemoteVideoSample::mirrored const):
* platform/graphics/cv/ImageTransferSessionVT.h:
* platform/graphics/cv/ImageTransferSessionVT.mm:
(WebCore::ImageTransferSessionVT::createMediaSample):

Source/WebKit:

Use new routine that preserves rotation.

* GPUProcess/webrtc/RemoteMediaRecorder.cpp:
(WebKit::RemoteMediaRecorder::videoSampleAvailable):
* GPUProcess/webrtc/RemoteSampleBufferDisplayLayer.cpp:
(WebKit::RemoteSampleBufferDisplayLayer::enqueueSample):
* WebProcess/cocoa/UserMediaCaptureManager.cpp:
(WebKit::UserMediaCaptureManager::Source::remoteVideoSampleAvailable):

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

5 months agoUnreviewed GTK gardening. Rebaseline tests after fixes for new style regressions
carlosgc@webkit.org [Fri, 28 Feb 2020 10:55:58 +0000 (10:55 +0000)]
Unreviewed GTK gardening. Rebaseline tests after fixes for new style regressions

* platform/gtk/TestExpectations:
* platform/gtk/css3/flexbox/button-expected.png:
* platform/gtk/css3/flexbox/button-expected.txt:
* platform/gtk/editing/selection/3690703-2-expected.png:
* platform/gtk/editing/selection/3690703-2-expected.txt:
* platform/gtk/editing/selection/3690703-expected.png:
* platform/gtk/editing/selection/3690703-expected.txt:
* platform/gtk/editing/selection/3690719-expected.png:
* platform/gtk/editing/selection/3690719-expected.txt:
* platform/gtk/editing/selection/4397952-expected.png:
* platform/gtk/editing/selection/4397952-expected.txt:
* platform/gtk/editing/selection/5240265-expected.png:
* platform/gtk/editing/selection/5240265-expected.txt:
* platform/gtk/editing/selection/selection-button-text-expected.png:
* platform/gtk/editing/selection/selection-button-text-expected.txt:
* platform/gtk/fast/block/float/float-avoidance-expected.png:
* platform/gtk/fast/block/float/float-avoidance-expected.txt:
* platform/gtk/fast/css/continuationCrash-expected.png:
* platform/gtk/fast/css/continuationCrash-expected.txt:
* platform/gtk/fast/css/margin-top-bottom-dynamic-expected.png:
* platform/gtk/fast/css/margin-top-bottom-dynamic-expected.txt:
* platform/gtk/fast/css/non-standard-checkbox-size-expected.png:
* platform/gtk/fast/css/non-standard-checkbox-size-expected.txt:
* platform/gtk/fast/css/rtl-ordering-expected.png:
* platform/gtk/fast/css/rtl-ordering-expected.txt:
* platform/gtk/fast/dom/HTMLTextAreaElement/reset-textarea-expected.png:
* platform/gtk/fast/dom/HTMLTextAreaElement/reset-textarea-expected.txt:
* platform/gtk/fast/forms/001-expected.png:
* platform/gtk/fast/forms/001-expected.txt:
* platform/gtk/fast/forms/basic-buttons-expected.png:
* platform/gtk/fast/forms/basic-buttons-expected.txt:
* platform/gtk/fast/forms/basic-selects-expected.png:
* platform/gtk/fast/forms/basic-selects-expected.txt:
* platform/gtk/fast/forms/blankbuttons-expected.png:
* platform/gtk/fast/forms/blankbuttons-expected.txt:
* platform/gtk/fast/forms/box-shadow-override-expected.png:
* platform/gtk/fast/forms/box-shadow-override-expected.txt:
* platform/gtk/fast/forms/button-positioned-expected.png:
* platform/gtk/fast/forms/button-positioned-expected.txt:
* platform/gtk/fast/forms/button-sizes-expected.png:
* platform/gtk/fast/forms/button-sizes-expected.txt:
* platform/gtk/fast/forms/button-style-color-expected.png:
* platform/gtk/fast/forms/button-style-color-expected.txt:
* platform/gtk/fast/forms/button-table-styles-expected.png:
* platform/gtk/fast/forms/button-table-styles-expected.txt:
* platform/gtk/fast/forms/button-text-transform-expected.png:
* platform/gtk/fast/forms/button-text-transform-expected.txt:
* platform/gtk/fast/forms/control-restrict-line-height-expected.png:
* platform/gtk/fast/forms/control-restrict-line-height-expected.txt:
* platform/gtk/fast/forms/file/file-input-direction-expected.png:
* platform/gtk/fast/forms/file/file-input-direction-expected.txt:
* platform/gtk/fast/forms/file/file-input-disabled-expected.png:
* platform/gtk/fast/forms/file/file-input-disabled-expected.txt:
* platform/gtk/fast/forms/form-element-geometry-expected.png:
* platform/gtk/fast/forms/form-element-geometry-expected.txt:
* platform/gtk/fast/forms/formmove3-expected.png:
* platform/gtk/fast/forms/formmove3-expected.txt:
* platform/gtk/fast/forms/input-appearance-height-expected.png:
* platform/gtk/fast/forms/input-appearance-height-expected.txt:
* platform/gtk/fast/forms/input-button-sizes-expected.png:
* platform/gtk/fast/forms/input-button-sizes-expected.txt:
* platform/gtk/fast/forms/input-value-expected.png:
* platform/gtk/fast/forms/input-value-expected.txt:
* platform/gtk/fast/forms/menulist-restrict-line-height-expected.png:
* platform/gtk/fast/forms/menulist-restrict-line-height-expected.txt:
* platform/gtk/fast/forms/targeted-frame-submission-expected.png:
* platform/gtk/fast/forms/targeted-frame-submission-expected.txt:
* platform/gtk/fast/html/details-replace-summary-child-expected.png:
* platform/gtk/fast/html/details-replace-summary-child-expected.txt:
* platform/gtk/fast/html/details-replace-text-expected.png:
* platform/gtk/fast/html/details-replace-text-expected.txt:
* platform/gtk/fast/overflow/scroll-nested-positioned-layer-in-overflow-expected.png:
* platform/gtk/fast/overflow/scroll-nested-positioned-layer-in-overflow-expected.txt:
* platform/gtk/fast/overflow/scrollRevealButton-expected.png:
* platform/gtk/fast/overflow/scrollRevealButton-expected.txt:
* platform/gtk/fast/replaced/replaced-breaking-expected.png:
* platform/gtk/fast/replaced/replaced-breaking-expected.txt:
* platform/gtk/fast/replaced/width100percent-button-expected.png:
* platform/gtk/fast/replaced/width100percent-button-expected.txt:
* platform/gtk/fast/replaced/width100percent-checkbox-expected.png:
* platform/gtk/fast/replaced/width100percent-checkbox-expected.txt:
* platform/gtk/fast/replaced/width100percent-radio-expected.png:
* platform/gtk/fast/replaced/width100percent-radio-expected.txt:
* platform/gtk/fast/text/international/hindi-spacing-expected.png:
* platform/gtk/fast/text/international/hindi-spacing-expected.txt:
* platform/gtk/fast/text/textIteratorNilRenderer-expected.png:
* platform/gtk/fast/text/textIteratorNilRenderer-expected.txt:
* platform/gtk/svg/custom/foreign-object-skew-expected.png:
* platform/gtk/svg/custom/foreign-object-skew-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug1188-expected.png:
* platform/gtk/tables/mozilla/bugs/bug1188-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug1318-expected.png:
* platform/gtk/tables/mozilla/bugs/bug1318-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug138725-expected.png:
* platform/gtk/tables/mozilla/bugs/bug138725-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug18359-expected.png:
* platform/gtk/tables/mozilla/bugs/bug18359-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug2479-2-expected.png:
* platform/gtk/tables/mozilla/bugs/bug2479-2-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug2479-3-expected.png:
* platform/gtk/tables/mozilla/bugs/bug2479-3-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug2479-4-expected.png:
* platform/gtk/tables/mozilla/bugs/bug2479-4-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug26178-expected.png:
* platform/gtk/tables/mozilla/bugs/bug26178-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug28928-expected.png:
* platform/gtk/tables/mozilla/bugs/bug28928-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug33855-expected.png:
* platform/gtk/tables/mozilla/bugs/bug33855-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug39209-expected.png:
* platform/gtk/tables/mozilla/bugs/bug39209-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug4429-expected.png:
* platform/gtk/tables/mozilla/bugs/bug4429-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug46368-1-expected.png:
* platform/gtk/tables/mozilla/bugs/bug46368-1-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug46368-2-expected.png:
* platform/gtk/tables/mozilla/bugs/bug46368-2-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug51037-expected.png:
* platform/gtk/tables/mozilla/bugs/bug51037-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug51727-expected.png:
* platform/gtk/tables/mozilla/bugs/bug51727-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug52505-expected.png:
* platform/gtk/tables/mozilla/bugs/bug52505-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug52506-expected.png:
* platform/gtk/tables/mozilla/bugs/bug52506-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug60749-expected.png:
* platform/gtk/tables/mozilla/bugs/bug60749-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug7342-expected.png:
* platform/gtk/tables/mozilla/bugs/bug7342-expected.txt:
* platform/gtk/tables/mozilla/bugs/bug92647-2-expected.png:
* platform/gtk/tables/mozilla/bugs/bug92647-2-expected.txt:
* platform/gtk/tables/mozilla/collapsing_borders/bug41262-4-expected.png:
* platform/gtk/tables/mozilla/collapsing_borders/bug41262-4-expected.txt:
* platform/gtk/tables/mozilla/dom/tableDom-expected.png:
* platform/gtk/tables/mozilla/dom/tableDom-expected.txt:
* platform/gtk/tables/mozilla/other/move_row-expected.png:
* platform/gtk/tables/mozilla/other/move_row-expected.txt:
* platform/gtk/tables/mozilla_expected_failures/bugs/bug1725-expected.png:
* platform/gtk/tables/mozilla_expected_failures/bugs/bug1725-expected.txt:
* platform/gtk/tables/mozilla_expected_failures/bugs/bug2479-5-expected.png:
* platform/gtk/tables/mozilla_expected_failures/bugs/bug2479-5-expected.txt:
* platform/gtk/tables/mozilla_expected_failures/bugs/bug58402-2-expected.png:
* platform/gtk/tables/mozilla_expected_failures/bugs/bug58402-2-expected.txt:

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

5 months agoREGRESSION(r257299): [GTK] Test imported/w3c/web-platform-tests/css/css-sizing/button...
carlosgc@webkit.org [Fri, 28 Feb 2020 09:57:32 +0000 (09:57 +0000)]
REGRESSION(r257299): [GTK] Test imported/w3c/web-platform-tests/css/css-sizing/button-min-width.html is failing since r257299
https://bugs.webkit.org/show_bug.cgi?id=208296

Reviewed by Adrian Perez de Castro.

We are no longer honoring the style min width/height of buttons.

* platform/Theme.cpp:
(WebCore::Theme::minimumControlSize const): Add zoomedSize parameter.
* platform/Theme.h:
* platform/adwaita/ThemeAdwaita.cpp:
(WebCore::ThemeAdwaita::minimumControlSize const): Use the style min size unless it's intrinsic or auto.
* platform/adwaita/ThemeAdwaita.h:
* platform/mac/ThemeMac.h:
* platform/mac/ThemeMac.mm:
(WebCore::ThemeMac::minimumControlSize const): Add zoomedSize parameter.
* rendering/RenderTheme.cpp:
(WebCore::RenderTheme::adjustStyle): Pass style min size to Theme::minimumControlSize().

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

5 months agoREGRESSION(r257299): [GTK] Check and radio buttons don't keep the aspect ratio
carlosgc@webkit.org [Fri, 28 Feb 2020 09:37:57 +0000 (09:37 +0000)]
REGRESSION(r257299): [GTK] Check and radio buttons don't keep the aspect ratio
https://bugs.webkit.org/show_bug.cgi?id=208302

Reviewed by Adrian Perez de Castro.

When different width and height is used, we should use the lower value and render the button centered.

* platform/adwaita/ThemeAdwaita.cpp:
(WebCore::ThemeAdwaita::paintCheckbox):
(WebCore::ThemeAdwaita::paintRadio):

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

5 months agoREGRESSION(r257299): [GTK] Test fast/replaced/table-percent-height.html is failing...
carlosgc@webkit.org [Fri, 28 Feb 2020 09:36:19 +0000 (09:36 +0000)]
REGRESSION(r257299): [GTK] Test fast/replaced/table-percent-height.html is failing since r257299
https://bugs.webkit.org/show_bug.cgi?id=208295

Reviewed by Adrian Perez de Castro.

We are now hardcoding the size of check and radio buttons, except when width and height are both specified.

* platform/adwaita/ThemeAdwaita.cpp:
(WebCore::ThemeAdwaita::controlSize const): Only set width and height of check and radio buttons when they are
intrinsic or auto.

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

5 months agoREGRESSION(r257299): [GTK] Test fast/forms/menulist-restrict-line-height.html is...
carlosgc@webkit.org [Fri, 28 Feb 2020 09:33:18 +0000 (09:33 +0000)]
REGRESSION(r257299): [GTK] Test fast/forms/menulist-restrict-line-height.html is failing since r257299
https://bugs.webkit.org/show_bug.cgi?id=208241

Reviewed by Adrian Perez de Castro.

We should not honor line-height for styled combo buttons.

* rendering/RenderThemeAdwaita.cpp:
(WebCore::RenderThemeAdwaita::adjustMenuListStyle const):
(WebCore::RenderThemeAdwaita::adjustMenuListButtonStyle const):
* rendering/RenderThemeAdwaita.h:

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

5 months agoREGRESSION(r257299): [GTK] box shadow is no longer ignored for search field decorations
carlosgc@webkit.org [Fri, 28 Feb 2020 09:31:53 +0000 (09:31 +0000)]
REGRESSION(r257299): [GTK] box shadow is no longer ignored for search field decorations
https://bugs.webkit.org/show_bug.cgi?id=208239

Reviewed by Adrian Perez de Castro.

Since we no longer use RenderTheme to paint the search field decorations we need to ensure a box shadow isn't
used for them in the CSS.

* css/themeAdwaita.css:
(input[type="search"]::-webkit-search-results-button,): Add -webkit-box-shadow: none !important;
(input[type="search"]::-webkit-search-cancel-button): Ditto.
(body[dir="rtl"] input[type="search"]::-webkit-search-cancel-button): Ditto.

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

5 months agoREGRESSION(r257299): Test fast/css/button-height.html is failing since r257299
carlosgc@webkit.org [Fri, 28 Feb 2020 09:30:31 +0000 (09:30 +0000)]
REGRESSION(r257299): Test fast/css/button-height.html is failing since r257299
https://bugs.webkit.org/show_bug.cgi?id=208237

Reviewed by Adrian Perez de Castro.

The new theming code doesn't use the same border size for button and input[type="button"].

* platform/adwaita/ThemeAdwaita.cpp:
(WebCore::ThemeAdwaita::controlBorder const): Use the same border for all buttons.
* platform/adwaita/ThemeAdwaita.h:

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

5 months agoUnreviewed. Fix hover effects broken for GTK port after r257592
carlosgc@webkit.org [Fri, 28 Feb 2020 09:26:57 +0000 (09:26 +0000)]
Unreviewed. Fix hover effects broken for GTK port after r257592

Add missing braces to if that now has two lines in the body. This was causing all mouse events to be considered
read only when building with TOUCH_EVENTS enabled.

* page/EventHandler.cpp:
(WebCore::EventHandler::handleMouseMoveEvent):

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

5 months agoUnreviewed GTK gardening. Remove platform/gtk/fast/forms/number/number-size-spinbutto...
carlosgc@webkit.org [Fri, 28 Feb 2020 08:50:57 +0000 (08:50 +0000)]
Unreviewed GTK gardening. Remove platform/gtk/fast/forms/number/number-size-spinbutton-nocover.html

This tested the behavior of spin buttons with the old GTK theming code.

* platform/gtk/fast/forms/number/number-size-spinbutton-nocover-expected.png: Removed.
* platform/gtk/fast/forms/number/number-size-spinbutton-nocover-expected.txt: Removed.
* platform/gtk/fast/forms/number/number-size-spinbutton-nocover.html: Removed.

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

5 months agoTest imported/blink/fast/forms/datalist/slider-appearance-with-ticks-crash.html fails
carlosgc@webkit.org [Fri, 28 Feb 2020 08:48:02 +0000 (08:48 +0000)]
Test imported/blink/fast/forms/datalist/slider-appearance-with-ticks-crash.html fails
https://bugs.webkit.org/show_bug.cgi?id=190613

Reviewed by Wenson Hsieh.

Source/WebCore:

Check the input is a range control before trying to paint slider ticks.

* rendering/RenderTheme.cpp:
(WebCore::RenderTheme::paintSliderTicks):

LayoutTests:

Remove test expectations.

* TestExpectations:
* platform/gtk/TestExpectations:

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

5 months agoREGRESSION(r257411): Web Inspector: Can't add a breakpoint by pressing the plus button
nvasilyev@apple.com [Fri, 28 Feb 2020 08:44:59 +0000 (08:44 +0000)]
REGRESSION(r257411): Web Inspector: Can't add a breakpoint by pressing the plus button
https://bugs.webkit.org/show_bug.cgi?id=208359
<rdar://problem/59870712>

Reviewed by Brian Burg.

In r257411 I added event.stop() (which is a shortcut for event.preventDefault() and
event.stopImmediatePropagation()) to mousedown handler. Calling event.stopImmediatePropagation()
prevented other mousedown event handlers from running.

This patch no longer calls event.stopImmediatePropagation().

* UserInterface/Views/ButtonNavigationItem.js:
(WI.ButtonNavigationItem.prototype._handleMouseDown):

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

5 months agoUpdate my watch list preferences and contributor's entry.
dbates@webkit.org [Fri, 28 Feb 2020 08:33:14 +0000 (08:33 +0000)]
Update my watch list preferences and contributor's entry.

* Scripts/webkitpy/common/config/contributors.json:
* Scripts/webkitpy/common/config/watchlist:

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

5 months agoWeb Inspector: allow use of dark mode theme independently from system-wide theme
drousso@apple.com [Fri, 28 Feb 2020 07:56:49 +0000 (07:56 +0000)]
Web Inspector: allow use of dark mode theme independently from system-wide theme
https://bugs.webkit.org/show_bug.cgi?id=186308
<rdar://problem/40785895>

Reviewed by Timothy Hatcher.

Source/WebCore:

* inspector/InspectorFrontendHost.idl:
* inspector/InspectorFrontendHost.h:
* inspector/InspectorFrontendHost.cpp:
(WebCore::InspectorFrontendHost::setForcedAppearance): Added.
Expose a way to call `Page::setUseDarkAppearanceOverride` from the Web Inspector frontend.

Source/WebInspectorUI:

* UserInterface/Base/Setting.js:
* UserInterface/Views/SettingsTabContentView.js:
(WI.SettingsTabContentView.prototype._createGeneralSettingsView):
Create a setting for controlling/preserving the theme of the frontend UI.

* UserInterface/Base/Main.js:
(WI.loaded):
(WI.contentLoaded):
Apply the created setting when Web Inspector is opened or if its value changes.

* UserInterface/Views/SettingEditor.js:
(WI.SettingEditor.prototype._createEditorElement):
Allow horizontal dividers in `<select>` setting editors.

* Localizations/en.lproj/localizedStrings.js:

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

5 months agoFix WebCore export macros for declspec
don.olmstead@sony.com [Fri, 28 Feb 2020 06:25:51 +0000 (06:25 +0000)]
Fix WebCore export macros for declspec
https://bugs.webkit.org/show_bug.cgi?id=208363

Reviewed by Konstantin Tokarev.

Source/WebCore:

Modified the PlatformExportMacros to match the other export macros. Originally
Windows ports were treated differently and they had to set their own export macros.
This isn't ideal because how WebCore is built is really dependent on the CMake
definition of the library type.

* CMakeLists.txt:
* WebCorePrefix.h:
* platform/PlatformExportMacros.h:
* testing/js/WebCoreTestSupportPrefix.h:

Source/WebKit:

Add compilation definitions for static linking of PAL and WebCore in WebKit.

* PlatformFTW.cmake:
* PlatformWin.cmake:
* config.h:

Source/WebKitLegacy:

Add compilation definitions for static linking of PAL and WebCore in WebKitLegacy.

* PlatformFTW.cmake:
* PlatformWin.cmake:

Source/WebKitLegacy/win:

Remove setting of WEBCORE_EXPORT from the header files.

* WebKitPrefix.h:

Tools:

Remove setting of WEBCORE_EXPORT and WEBCORE_TESTSUPPORT_EXPORT from the header
files. Removed precompiled headers that were empty.

* DumpRenderTree/DumpRenderTreePrefix.h:
* DumpRenderTree/win/DefaultPolicyDelegate.cpp: Added a missing config.h.
* MiniBrowser/win/stdafx.h:
* TestWebKitAPI/win/TestWebKitAPIPrefix.cpp: Removed.
* TestWebKitAPI/win/TestWebKitAPIPrefix.h: Removed.
* WebKitTestRunner/InjectedBundle/win/TestRunnerInjectedBundlePrefix.cpp: Removed.
* WebKitTestRunner/InjectedBundle/win/TestRunnerInjectedBundlePrefix.h: Removed.
* WebKitTestRunner/PlatformFTW.cmake:
* WebKitTestRunner/PlatformWin.cmake:
* WebKitTestRunner/WebKitTestRunnerPrefix.h:

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

5 months agoUIProcess crash after using _prepareForMoveToWindow, then deallocating the WKWebView...
timothy_horton@apple.com [Fri, 28 Feb 2020 06:21:20 +0000 (06:21 +0000)]
UIProcess crash after using _prepareForMoveToWindow, then deallocating the WKWebView before moving to the window
https://bugs.webkit.org/show_bug.cgi?id=208365

Reviewed by Alex Christensen.

Source/WebKit:

New test: WKWebView.PrepareForMoveToWindowCrashAfterNotMovingToWindow

* UIProcess/Cocoa/WebViewImpl.mm:
(-[WKWindowVisibilityObserver dealloc]):
(-[WKWindowVisibilityObserver setWindowToObserve:]):
(WebKit::WebViewImpl::viewWillMoveToWindow):
Two small changes to make WKWindowVisibilityObserver safer to use, which
fix the aforementioned bug:

- Instead of exposing startObserving/stopObserving and making clients
be careful about pairing them, and remembering which window to stopObserving,
just add "setWindowToObserve", and keep track (weakly) of the current
NSWindow being observed. This avoids double-adding observers.

- Always stopObserving when WKWindowVisibilityObserver is deallocated.
In the "normal" case, WKWebView will always be removed from the view
hierarchy before it is deallocated (and thus before the
WKWindowVisibilityObserver is deallocated), because otherwise its superview
holds a reference to it. But in the _prepareForMoveToWindow case, we do
not have this guarantee, and can end up deallocating the WKWebView without
getting a willMoveToWindow:nil. Make sure to clean up the observers in
that case, if the window is still around, otherwise when NSWindow sends
notifications, it will try to message a deallocated WKWebView.

Tools:

* TestWebKitAPI/Tests/WebKitCocoa/PrepareForMoveToWindow.mm:
(TEST):
Add a test! It was a 100% repro crash before this change.

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

5 months agoMemoryRelease logging uses a unique_ptr with unclear lifetime
dino@apple.com [Fri, 28 Feb 2020 05:53:20 +0000 (05:53 +0000)]
MemoryRelease logging uses a unique_ptr with unclear lifetime
https://bugs.webkit.org/show_bug.cgi?id=208361

Reviewed by Alex Christensen.

The logging here was getting a unique_ptr inside the loop, which
causes newer versions of clang to complain with an error:
object backing the pointer will be destroyed at the end of the full-expression [-Werror,-Wdangling-gsl]

Using a temporary local variable fixes the problem.

* page/MemoryRelease.cpp:
(WebCore::logMemoryStatisticsAtTimeOfDeath):

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

5 months agoHit test with clipPath referencing parent element causes infinite recursion
commit-queue@webkit.org [Fri, 28 Feb 2020 04:15:37 +0000 (04:15 +0000)]
Hit test with clipPath referencing parent element causes infinite recursion
https://bugs.webkit.org/show_bug.cgi?id=208279

Patch by Doug Kelly <dougk@apple.com> on 2020-02-27
Reviewed by Ryosuke Niwa.

Source/WebCore:

Add an early return for SVG hit tests which have a child element referencing a  parent clipPath.
This change breaks the cycle, although it unfortunately runs on every hit test, for each node which
is a child of the clipPath element.

Test: svg/hittest/svg-clip-path-child-element.html

* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::hitTestClipContent):

LayoutTests:

* svg/hittest/svg-clip-path-child-element-expected.txt: Added.
* svg/hittest/svg-clip-path-child-element.html: Added.

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

5 months ago[iOS] Remove logging for sysctl access to properties used by NSURLSession
bfulgham@apple.com [Fri, 28 Feb 2020 03:50:13 +0000 (03:50 +0000)]
[iOS] Remove logging for sysctl access to properties used by NSURLSession
https://bugs.webkit.org/show_bug.cgi?id=208346
<rdar://problem/59862967>

Reviewed by Alexey Proskuryakov.

Telemetry and logging indicate that two sysctl calls are needed by [NSURLSession sessionWithConfiguration].
We no longer need to log these well understood uses.

* Resources/SandboxProfiles/ios/com.apple.WebKit.Networking.sb:

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

5 months agoTestWebKitAPI and WebKitTestRunner should have bundle identifiers
katherine_cheney@apple.com [Fri, 28 Feb 2020 03:43:19 +0000 (03:43 +0000)]
TestWebKitAPI and WebKitTestRunner should have bundle identifiers
https://bugs.webkit.org/show_bug.cgi?id=208260
<rdar://problem/59820107>

Reviewed by Tim Horton.

Followed instructions for adding an Info.plist for Single-File Tools
found on https://developer.apple.com/library/archive/documentation/Security/Conceptual/CodeSigningGuide/Procedures/Procedures.html

The default WebsiteDataStore file path will change with this test to
reflect the new bundleID so we must change expectations for any api
tests which rely on knowing the path.

* TestWebKitAPI/Configurations/TestWebKitAPI.xcconfig:
* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKitCocoa/IDBDeleteRecovery.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/IDBIndexUpgradeToV2.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/IDBObjectStoreInfoUpgradeToV2.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/IndexedDBStructuredCloneBackwardCompatibility.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/IndexedDBTempFileSize.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/LoadFileURL.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/LocalStorageClear.mm:
(TEST):
(defaultWebsiteCacheDirectory):
* TestWebKitAPI/Tests/WebKitCocoa/LocalStorageNullEntries.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/ResourceLoadStatistics.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/ServiceWorkerBasic.mm:
* TestWebKitAPI/Tests/WebKitCocoa/StoreBlobThenDelete.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/WKHTTPCookieStore.mm:
(TEST):
* TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:
(runWebsiteDataStoreCustomPaths):
(TEST):
* TestWebKitAPI/Tests/mac/SetAndUpdateCacheModel.mm:
(TestWebKitAPI::resetTestState):
Now that we set a bundleID, we have to reset the cache model between
tests, otherwise it gets stored between tests.

(TestWebKitAPI::TEST):
* WebKitTestRunner/Configurations/WebKitTestRunner.xcconfig:
* WebKitTestRunner/WebKitTestRunner.xcodeproj/project.pbxproj:

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

5 months agoTextManipulationController should not generate a new item for content in manipulated...
rniwa@webkit.org [Fri, 28 Feb 2020 03:37:22 +0000 (03:37 +0000)]
TextManipulationController should not generate a new item for content in manipulated paragraphs
https://bugs.webkit.org/show_bug.cgi?id=208286

Reviewed by Wenson Hsieh.

Source/WebCore:

This patch makes TextManipulationController to ignore any content change in previously manipulated paragraphs.

Added an early exist to observeParagraphs when the observed content has an element that has already been manipulated
as an ancestor. Note that the only case in which this logic matters is when it's called by scheduleObservartionUpdate,
which calls this function on each paragraph separately, unlike startObservingParagraphs which calls it on
the entire document, we can simply exit early instead of ignoring just the current paragraph.

Renamed TextManipulationController's m_recentlyInsertedElements to m_manipulatedElements and made it persist
forever so that we can track any element that has already been manipulated. Als renamed m_mutatedElements
to m_elementsWithNewRenderer for clarity.

Test: TestWebKitAPI.TextManipulation.InsertingContentIntoAlreadyManipulatedContentDoesNotCreateTextManipulationItem

* editing/TextManipulationController.cpp:
(WebCore::TextManipulationController::isInManipulatedElement): Added. Has a fast path for when
m_manipulatedElements's capacity is 0, which happens when observeParagraphs is called by startObservingParagraphs.
(WebCore::TextManipulationController::observeParagraphs): Added an early exit when there is a content that has
already been manipulated.
(WebCore::TextManipulationController::didCreateRendererForElement): Added the same check to fail early.
(WebCore::TextManipulationController::scheduleObservartionUpdate):
(WebCore::TextManipulationController::replace): Removed the code to clear m_recentlyInsertedElements.
* editing/TextManipulationController.h:

Tools:

Added a regression test.

* TestWebKitAPI/Tests/WebKitCocoa/TextManipulation.mm:
(TextManipulation.InsertingContentIntoAlreadyManipulatedContentDoesNotCreateTextManipulationItem):

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

5 months agoSupport in-band generic cues when loading media in the GPU Process
eric.carlson@apple.com [Fri, 28 Feb 2020 03:05:58 +0000 (03:05 +0000)]
Support in-band generic cues when loading media in the GPU Process
https://bugs.webkit.org/show_bug.cgi?id=208080
<rdar://problem/59687943>

Reviewed by Youenn Fablet.

Source/WebCore:

No new tests, existing tests enabled for GPU process.

* Headers.cmake:
* WebCore.xcodeproj/project.pbxproj:
* html/track/InbandGenericTextTrack.cpp:
(WebCore::GenericTextTrackCueMap::add):
(WebCore::GenericTextTrackCueMap::findIndexOfPair):
(WebCore::GenericTextTrackCueMap::find):
(WebCore::GenericTextTrackCueMap::remove):
(WebCore::InbandGenericTextTrack::updateCueFromCueData):
(WebCore::InbandGenericTextTrack::addGenericCue):
(WebCore::InbandGenericTextTrack::updateGenericCue):
(WebCore::InbandGenericTextTrack::removeGenericCue):
* html/track/InbandGenericTextTrack.h:
* html/track/InbandTextTrack.h:
* html/track/TextTrackCueGeneric.h:
* platform/graphics/InbandGenericCue.h: Added.
(WebCore::GenericCueData::decode):
(WebCore::GenericCueData::encode const):
(WebCore::InbandGenericCue::create):
(WebCore::InbandGenericCue::startTime const):
(WebCore::InbandGenericCue::setStartTime):
(WebCore::InbandGenericCue::endTime const):
(WebCore::InbandGenericCue::setEndTime):
(WebCore::InbandGenericCue::id const):
(WebCore::InbandGenericCue::setId):
(WebCore::InbandGenericCue::content const):
(WebCore::InbandGenericCue::setContent):
(WebCore::InbandGenericCue::line const):
(WebCore::InbandGenericCue::setLine):
(WebCore::InbandGenericCue::position const):
(WebCore::InbandGenericCue::setPosition):
(WebCore::InbandGenericCue::size const):
(WebCore::InbandGenericCue::setSize):
(WebCore::InbandGenericCue::align const):
(WebCore::InbandGenericCue::setAlign):
(WebCore::InbandGenericCue::fontName const):
(WebCore::InbandGenericCue::setFontName):
(WebCore::InbandGenericCue::baseFontSize const):
(WebCore::InbandGenericCue::setBaseFontSize):
(WebCore::InbandGenericCue::relativeFontSize const):
(WebCore::InbandGenericCue::setRelativeFontSize):
(WebCore::InbandGenericCue::foregroundColor const):
(WebCore::InbandGenericCue::setForegroundColor):
(WebCore::InbandGenericCue::backgroundColor const):
(WebCore::InbandGenericCue::setBackgroundColor):
(WebCore::InbandGenericCue::highlightColor const):
(WebCore::InbandGenericCue::setHighlightColor):
(WebCore::InbandGenericCue::status):
(WebCore::InbandGenericCue::setStatus):
(WebCore::InbandGenericCue::cueData const):
(WebCore::InbandGenericCue::InbandGenericCue):
(WebCore::InbandGenericCue::toJSONString const):
(WebCore::InbandGenericCue::doesExtendCueData const):
(WTF::LogArgument<WebCore::InbandGenericCue>::toString):
* platform/graphics/InbandTextTrackPrivateClient.h:
(WebCore::GenericCueData::create): Deleted.
(WebCore::GenericCueData::startTime const): Deleted.
(WebCore::GenericCueData::setStartTime): Deleted.
(WebCore::GenericCueData::endTime const): Deleted.
(WebCore::GenericCueData::setEndTime): Deleted.
(WebCore::GenericCueData::id const): Deleted.
(WebCore::GenericCueData::setId): Deleted.
(WebCore::GenericCueData::content const): Deleted.
(WebCore::GenericCueData::setContent): Deleted.
(WebCore::GenericCueData::line const): Deleted.
(WebCore::GenericCueData::setLine): Deleted.
(WebCore::GenericCueData::position const): Deleted.
(WebCore::GenericCueData::setPosition): Deleted.
(WebCore::GenericCueData::size const): Deleted.
(WebCore::GenericCueData::setSize): Deleted.
(): Deleted.
(WebCore::GenericCueData::align const): Deleted.
(WebCore::GenericCueData::setAlign): Deleted.
(WebCore::GenericCueData::fontName const): Deleted.
(WebCore::GenericCueData::setFontName): Deleted.
(WebCore::GenericCueData::baseFontSize const): Deleted.
(WebCore::GenericCueData::setBaseFontSize): Deleted.
(WebCore::GenericCueData::relativeFontSize const): Deleted.
(WebCore::GenericCueData::setRelativeFontSize): Deleted.
(WebCore::GenericCueData::foregroundColor const): Deleted.
(WebCore::GenericCueData::setForegroundColor): Deleted.
(WebCore::GenericCueData::backgroundColor const): Deleted.
(WebCore::GenericCueData::setBackgroundColor): Deleted.
(WebCore::GenericCueData::highlightColor const): Deleted.
(WebCore::GenericCueData::setHighlightColor): Deleted.
(WebCore::GenericCueData::status): Deleted.
(WebCore::GenericCueData::setStatus): Deleted.
(WebCore::GenericCueData::toJSONString const): Deleted.
(WebCore::GenericCueData::doesExtendCueData const): Deleted.
(WTF::LogArgument<WebCore::GenericCueData>::toString): Deleted.
* platform/graphics/avfoundation/InbandTextTrackPrivateAVF.cpp:
(WebCore::InbandTextTrackPrivateAVF::processCueAttributes):
(WebCore::InbandTextTrackPrivateAVF::processAttributedStrings):
(WebCore::InbandTextTrackPrivateAVF::removeCompletedCues):
* platform/graphics/avfoundation/InbandTextTrackPrivateAVF.h:
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:

Source/WebKit:

* GPUProcess/media/RemoteTextTrackProxy.cpp:
(WebKit::RemoteTextTrackProxy::addGenericCue):
(WebKit::RemoteTextTrackProxy::updateGenericCue):
(WebKit::RemoteTextTrackProxy::removeGenericCue):
* GPUProcess/media/RemoteTextTrackProxy.h:
* Scripts/webkit/messages.py:
* WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:
(WebKit::MediaPlayerPrivateRemote::MediaPlayerPrivateRemote::load):
(WebKit::MediaPlayerPrivateRemote::addGenericCue):
(WebKit::MediaPlayerPrivateRemote::updateGenericCue):
(WebKit::MediaPlayerPrivateRemote::removeGenericCue):
* WebProcess/GPU/media/MediaPlayerPrivateRemote.h:
* WebProcess/GPU/media/MediaPlayerPrivateRemote.messages.in:
* WebProcess/GPU/media/TextTrackPrivateRemote.cpp:
(WebKit::TextTrackPrivateRemote::addGenericCue):
(WebKit::TextTrackPrivateRemote::updateGenericCue):
(WebKit::TextTrackPrivateRemote::removeGenericCue):
* WebProcess/GPU/media/TextTrackPrivateRemote.h:

LayoutTests:

* gpu-process/TestExpectations:

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

5 months ago[iOS] Issue mach sandbox extensions to the WebContent process for a set of specific...
pvollan@apple.com [Fri, 28 Feb 2020 02:44:40 +0000 (02:44 +0000)]
[iOS] Issue mach sandbox extensions to the WebContent process for a set of specific services
https://bugs.webkit.org/show_bug.cgi?id=208146

Reviewed by Brent Fulgham.

Source/WebKit:

We are still seeing some accesses from the WebContent process to a small set of services. Since we do not currently have
backtraces for these accesses, make a speculative patch, where we issue these extension for all apps except Safari.

Test: fast/sandbox/ios/sandbox-mach-lookup-mail.html

* Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::platformInitializeWebProcess):
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::platformInitializeWebProcess):

LayoutTests:

* fast/sandbox/ios/sandbox-mach-lookup-mail-expected.txt:
* fast/sandbox/ios/sandbox-mach-lookup-mail.html:

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

5 months ago[iOS] The GPU process never runs as a foreground process
pvollan@apple.com [Fri, 28 Feb 2020 02:41:58 +0000 (02:41 +0000)]
[iOS] The GPU process never runs as a foreground process
https://bugs.webkit.org/show_bug.cgi?id=208250

Reviewed by Chris Dumez.

Currently, the GPU process always runs in the background, and never goes into the foreground mode, which is required for media
playback on iOS. This is addressed by creating a layer in the GPU process, whose context ID is used to create a visibility
propagation view in the UI process. This is done in the same way as it is done for the WebContent process. This makes it
possible for the system to determine the visibility of the GPU process. In addition, create foreground process assertions
when media is being played.

No new tests, covered by existing tests.

* GPUProcess/GPUProcess.cpp:
(WebKit::GPUProcess::initializeGPUProcess):
* GPUProcess/GPUProcess.h:
* GPUProcess/ios/GPUProcessIOS.mm:
* UIProcess/Cocoa/WebPageProxyCocoa.mm:
(WebKit::WebPageProxy::didCreateContextInGPUProcessForVisibilityPropagation):
* UIProcess/GPU/GPUProcessProxy.cpp:
(WebKit::GPUProcessProxy::GPUProcessProxy):
(WebKit::GPUProcessProxy::openGPUProcessConnection):
(WebKit::GPUProcessProxy::didCreateContextForVisibilityPropagation):
(WebKit::GPUProcessProxy::contextIDForVisibilityPropagation const):
* UIProcess/GPU/GPUProcessProxy.h:
* UIProcess/GPU/GPUProcessProxy.messages.in:
* UIProcess/PageClient.h:
(WebKit::PageClient::didCreateContextInGPUProcessForVisibilityPropagation):
(WebKit::PageClient::gpuProcessCrashed):
* UIProcess/WebPageProxy.cpp:
* UIProcess/WebPageProxy.h:
* UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::gpuProcessCrashed):
(WebKit::WebProcessPool::setWebProcessIsPlayingAudibleMedia):
(WebKit::WebProcessPool::clearWebProcessIsPlayingAudibleMedia):
* UIProcess/WebProcessPool.h:
* UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::gpuProcessCrashed):
(WebKit::WebProcessProxy::didCreateContextInGPUProcessForVisibilityPropagation):
* UIProcess/WebProcessProxy.h:
* UIProcess/ios/PageClientImplIOS.h:
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::didCreateContextInGPUProcessForVisibilityPropagation):
(WebKit::PageClientImpl::gpuProcessCrashed):
* UIProcess/ios/WKContentView.h:
* UIProcess/ios/WKContentView.mm:
(-[WKContentView _commonInitializationWithProcessPool:configuration:]):
(-[WKContentView _setupVisibilityPropagationViewForGPUProcess]):
(-[WKContentView _removeVisibilityPropagationViewForGPUProcess]):
(-[WKContentView _gpuProcessCrashed]):
(-[WKContentView _gpuProcessDidCreateContextForVisibilityPropagation]):

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

5 months agoFix debug arm64 Wasm tests
sbarati@apple.com [Fri, 28 Feb 2020 02:27:14 +0000 (02:27 +0000)]
Fix debug arm64 Wasm tests
https://bugs.webkit.org/show_bug.cgi?id=208362

Reviewed by Yusuke Suzuki.

* wasm/WasmAirIRGenerator.cpp:
(JSC::Wasm::AirIRGenerator::emitChecksForModOrDiv):

We were assuming that "-1" is a valid imm on arm64, but it's not, we need
to use big imm.

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

5 months agoREGRESSION (r257391-257396): [ iOS ] imported/w3c/web-platform-tests/html/browsers...
nham@apple.com [Fri, 28 Feb 2020 01:46:28 +0000 (01:46 +0000)]
REGRESSION (r257391-257396): [ iOS ] imported/w3c/web-platform-tests/html/browsers/browsing-the-web/history-traversal/scroll-restoration-order.html is failing
https://bugs.webkit.org/show_bug.cgi?id=208323

Unreviewed test gardening.

scroll-restoration-order.html has always failed on iOS. Before r257394, we didn't properly
restore the scroll position before the hashchange event. After r257394, we now properly
restore the scroll position, but do it too early (it's restored before popstate, rather than
between popstate and hashchange). If anything, the new state seems less broken than before,
so this just updates the expected results to reflect the current status of our tests.

* platform/ios-wk2/imported/w3c/web-platform-tests/html/browsers/browsing-the-web/history-traversal/scroll-restoration-order-expected.txt:

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

5 months ago[GTK] Layout test gardening
lmoura@igalia.com [Fri, 28 Feb 2020 01:42:12 +0000 (01:42 +0000)]
[GTK] Layout test gardening
https://bugs.webkit.org/show_bug.cgi?id=208360

Unreviewed test gardening.

Removed some deprecated baselines after new form styles.

* platform/gtk/TestExpectations:
* platform/gtk/accessibility/disabled-controls-not-focusable-expected.txt: Removed.
* platform/gtk/fast/forms/input-number-click-expected.txt: Removed.
* platform/gtk/imported/w3c/web-platform-tests/html/semantics/selectors/pseudo-classes/inrange-outofrange-expected.txt: Removed.

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

5 months agoImplement ImageBuffer shareable backends
commit-queue@webkit.org [Fri, 28 Feb 2020 01:35:21 +0000 (01:35 +0000)]
Implement ImageBuffer shareable backends
https://bugs.webkit.org/show_bug.cgi?id=207233

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-02-27
Reviewed by Simon Fraser.

Source/WebCore:

* Headers.cmake:
* WebCore.xcodeproj/project.pbxproj:
* platform/graphics/PlatformImageBufferBackend.h: Added.
Define the base ImageBufferBackend for each platform.
ImageBufferShareableBitmapBackend in WebKit needs to have access to basic
ImageBufferBackend functionalities specific to the platform.

* platform/graphics/cg/ImageBufferIOSurfaceBackend.cpp:
(WebCore::ImageBufferIOSurfaceBackend::create):
* platform/graphics/cg/ImageBufferIOSurfaceBackend.h:
Use WTF::makeUnique and make the constructor public.

Source/WebKit:

RemoteImageBufferProxy will create a shareable backend in the GPUProcess.
Then it will give access to this backend to RemoteImageBuffer in the
WebProcess by sending an ImageBufferBackendHandle.

* Sources.txt:
* SourcesCocoa.txt:
* WebKit.xcodeproj/project.pbxproj:
* WebProcess/GPU/graphics/ImageBufferBackendHandle.h: Added.
This is variant of shareable handles to the ImageBufferBackend data.

* WebProcess/GPU/graphics/ImageBufferShareableBitmapBackend.cpp: Added.
(WebKit::ImageBufferShareableBitmapBackend::create):
The first create method will be called to create the backend of
RemoteImageBufferProxy GPUProcess. The second create method will be called
to create the backend of RemoteImageBuffer in the WebProcess.

(WebKit::ImageBufferShareableBitmapBackend::ImageBufferShareableBitmapBackend):
(WebKit::ImageBufferShareableBitmapBackend::createImageBufferBackendHandle const):
Creates an ImageBufferBackendHandle which will be sent from the GPUProcess
to the WebProcess.

(WebKit::ImageBufferShareableBitmapBackend::copyNativeImage const):
(WebKit::ImageBufferShareableBitmapBackend::copyImage const):
(WebKit::ImageBufferShareableBitmapBackend::toBGRAData const):
(WebKit::ImageBufferShareableBitmapBackend::getImageData const):
(WebKit::ImageBufferShareableBitmapBackend::putImageData):
* WebProcess/GPU/graphics/ImageBufferShareableBitmapBackend.h: Added.

* WebProcess/GPU/graphics/PlatformImageBufferShareableBackend.h: Added.
Defines the platform shareable ImageBufferBackend types.

* WebProcess/GPU/graphics/cocoa/ImageBufferShareableIOSurfaceBackend.cpp: Added.
(WebKit::ImageBufferShareableIOSurfaceBackend::create):
(WebKit::ImageBufferShareableIOSurfaceBackend::createImageBufferBackendHandle const):
* WebProcess/GPU/graphics/cocoa/ImageBufferShareableIOSurfaceBackend.h: Added.
Because ImageBufferBackendHandle has to be defined in WebKit, sharing
the IOSurface backend has to be implemented in WebKit.

* WebProcess/GPU/media/RemoteAudioDestinationProxy.cpp:
* WebProcess/GPU/webrtc/MediaRecorderPrivate.cpp:
* WebProcess/Network/WebSocketChannel.cpp:
* WebProcess/WebPage/gtk/AcceleratedSurfaceX11.h:
Unified sources gardening.

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

5 months agoPoly proto should work with property delete transitions
justin_michaud@apple.com [Fri, 28 Feb 2020 01:34:05 +0000 (01:34 +0000)]
Poly proto should work with property delete transitions
https://bugs.webkit.org/show_bug.cgi?id=208261

Reviewed by Saam Barati.

JSTests:

* stress/delete-property-poly-proto.js: Added.
(A.prototype.set x):
(A):
(B):

Source/JavaScriptCore:

This patch fixes a bug where the combination of inline caching
and poly proto cause us to cache a setter call along a prototype chain that
is no longer the correct setter to call. This is exposed as a result of
https://bugs.webkit.org/show_bug.cgi?id=206430 since DefineOwnProperty used
to transition to uncacheable dictionary.

The case looks like this:
A - setter for x redefines x
|
B
|
C

We set (new C).x

Right now, we first call A's setter, then we try to figure out what the state of things
were before it was called in order to cache it. We just assume that A's setter still exists, and we cache it
without ever checking, In this patch, we ensure that the property exists and the attributes match in order to prevent crashing.

In the code, A = target, C = base.

Get is correct because it collects caching information before any calls.

The bug https://bugs.webkit.org/show_bug.cgi?id=208337 tracks the remaining semantic bugs around this code.

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

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

5 months ago[ iOS Debug wk2 ] imported/w3c/web-platform-tests/css/mediaqueries/test_media_queries...
lawrence.j@apple.com [Fri, 28 Feb 2020 01:01:46 +0000 (01:01 +0000)]
[ iOS Debug wk2 ] imported/w3c/web-platform-tests/css/mediaqueries/test_media_queries.html is flaky timing out.
https://bugs.webkit.org/show_bug.cgi?id=208355

Unreviewed test gardening.

* platform/ios-wk2/TestExpectations:

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

5 months ago[ iOS wk2 ] LayoutTest/fast/animation/request-animation-frame-time-unit.html is flaky.
lawrence.j@apple.com [Fri, 28 Feb 2020 00:13:58 +0000 (00:13 +0000)]
[ iOS wk2 ] LayoutTest/fast/animation/request-animation-frame-time-unit.html is flaky.
https://bugs.webkit.org/show_bug.cgi?id=171957

Unreviewed test gardening.

* platform/ios-wk2/TestExpectations:

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

5 months ago[WinCairo] Fix RemoteInspector reconnect issue
basuke.suzuki@sony.com [Fri, 28 Feb 2020 00:06:12 +0000 (00:06 +0000)]
[WinCairo] Fix RemoteInspector reconnect issue
https://bugs.webkit.org/show_bug.cgi?id=208256

Reviewed by Devin Rousso.

Source/JavaScriptCore:

Call target's disconnection sequence asynchronously to avoid deadlock.

* inspector/remote/RemoteConnectionToTarget.cpp:
(Inspector::RemoteConnectionToTarget::close):
* inspector/remote/socket/RemoteInspectorSocketEndpoint.cpp:
(Inspector::RemoteInspectorSocketEndpoint::workerThread):

Source/WTF:

Added wakeupCallback to RunLoop. In case of RunLook::iterate, we need to wake up worker thread
when RunLoop is waking up.

* wtf/RunLoop.h:
* wtf/generic/RunLoopGeneric.cpp:
(WTF::RunLoop::setWakeUpCallback):
(WTF::RunLoop::wakeUp):
* wtf/win/RunLoopWin.cpp:
(WTF::RunLoop::setWakeUpCallback):
(WTF::RunLoop::wakeUp):

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

5 months agorun-javascriptcore-tests: Make upload format valid
jbedard@apple.com [Fri, 28 Feb 2020 00:05:19 +0000 (00:05 +0000)]
run-javascriptcore-tests: Make upload format valid
https://bugs.webkit.org/show_bug.cgi?id=208341

Reviewed by Aakash Jain.

* Scripts/run-javascriptcore-tests:
(uploadResults): Print json blob for upload after failure for debugging.

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

5 months ago[ macOS wk2 ] webgpu/whlsl/return-local-variable.html is flaky failing
jacob_uphoff@apple.com [Thu, 27 Feb 2020 23:59:58 +0000 (23:59 +0000)]
[ macOS wk2 ] webgpu/whlsl/return-local-variable.html is flaky failing
https://bugs.webkit.org/show_bug.cgi?id=207700

Unreviewed test gardening

* platform/mac-wk2/TestExpectations: Correcting test expectations.

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

5 months ago[Win] Fix AppleWin build
pvollan@apple.com [Thu, 27 Feb 2020 23:45:15 +0000 (23:45 +0000)]
[Win] Fix AppleWin build
https://bugs.webkit.org/show_bug.cgi?id=208330

Reviewed by Don Olmstead.

Set framework headers directory for AppleWin build.

* Source/cmake/target/TargetJavaScriptCore.cmake:
* Source/cmake/target/TargetWTF.cmake:

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

5 months agoREGRESSION (r256910?) [ Mac wk1 ] fast/canvas/webgl/canvas-webgl-page-cache.html...
lawrence.j@apple.com [Thu, 27 Feb 2020 23:42:28 +0000 (23:42 +0000)]
REGRESSION (r256910?) [ Mac wk1 ] fast/canvas/webgl/canvas-webgl-page-cache.html is flaky crashing.
https://bugs.webkit.org/show_bug.cgi?id=208345

Unreviewed test gardening.

* platform/mac-wk1/TestExpectations:

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

5 months agoUnreviewed, rolling out r257575.
ryanhaddad@apple.com [Thu, 27 Feb 2020 23:39:25 +0000 (23:39 +0000)]
Unreviewed, rolling out r257575.

Broke the watchOS build.

Reverted changeset:

"[iOS] Issue mach sandbox extensions to the WebContent process
for a set of specific services"
https://bugs.webkit.org/show_bug.cgi?id=208146
https://trac.webkit.org/changeset/257575

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

5 months agoChange HitTestRequestType to an OptionSet
dbates@webkit.org [Thu, 27 Feb 2020 23:27:00 +0000 (23:27 +0000)]
Change HitTestRequestType to an OptionSet
https://bugs.webkit.org/show_bug.cgi?id=208334

Reviewed by Wenson Hsieh.

Source/WebCore:

The majority of this change is replacing usage of HitTestRequestType with an OptionSet<HitTestRequest::RequestType>.
Though I was tempted and did in some circumstances modernize code around HitTestRequestType call sites.
I've annotated important changes below.

* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::press):
* accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::visiblePositionForPoint const): Updated code as needed.
Added FIXME comment: the code should be written without a loop and instead use HitTestRequest::AllowVisibleChildFrameContentOnly
to achieve the goal.
(WebCore::AccessibilityRenderObject::accessibilityHitTest const):
* dom/TreeScope.cpp:
(WebCore::TreeScope::elementsFromPoint):
* html/HTMLPlugInElement.cpp:
(WebCore::HTMLPlugInElement::isReplacementObscured): Update code as needed. Use IntRect::center()
convenience function instead of computing the center point manually.
* html/MediaElementSession.cpp:
(WebCore::isElementMainContentForPurposesOfAutoplay): Update code as needed. Move check for whether
the main frame has a document earlier in the function to avoid unncessary work. In practice, this
check will never fail because the main frame always has a document. Though to be precise the main
frame may not have a document during frame initialization. However, it does not make sense for this
code to ever be called then.
* page/AutoscrollController.cpp:
(WebCore::AutoscrollController::updateAutoscrollRenderer):
* page/ContextMenuController.cpp:
(WebCore::ContextMenuController::maybeCreateContextMenu):
* page/DragController.cpp:
(WebCore::DragController::canProcessDrag):
(WebCore::DragController::startDrag):
* page/EventHandler.cpp:
(WebCore::EventHandler::eventMayStartDrag const):
(WebCore::EventHandler::updateSelectionForMouseDrag):
(WebCore::EventHandler::hitTestResultAtPoint const):
(WebCore::EventHandler::updateCursor):
(WebCore::EventHandler::handleMousePressEvent):
(WebCore::EventHandler::handleMouseDoubleClickEvent):
(WebCore::EventHandler::handleMouseMoveEvent):
(WebCore::EventHandler::handleMouseReleaseEvent):
(WebCore::EventHandler::handleMouseForceEvent):
(WebCore::EventHandler::updateDragAndDrop):
(WebCore::EventHandler::isInsideScrollbar const):
(WebCore::EventHandler::sendContextMenuEvent):
(WebCore::EventHandler::sendContextMenuEventForKey):
(WebCore::EventHandler::hoverTimerFired):
(WebCore::EventHandler::dragSourceEndedAt):
(WebCore::EventHandler::handleDrag):
(WebCore::hitTestResultInFrame):
(WebCore::EventHandler::handleTouchEvent):
(WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
* page/EventHandler.h:
* page/FocusController.cpp:
(WebCore::updateFocusCandidateIfNeeded):
* page/Frame.cpp:
(WebCore::Frame::visiblePositionForPoint const):
(WebCore::Frame::documentAtPoint):
* page/PointerCaptureController.cpp:
(WebCore::PointerCaptureController::cancelPointer): Added FIXME about correctness issue.
The local variable named target will always be nullptr even after calling hitTestResultAtPoint().
* page/ios/EventHandlerIOS.mm:
(WebCore::EventHandler::tryToBeginDragAtPoint):
* page/ios/FrameIOS.mm:
(WebCore::Frame::renderRectForPoint const):
(WebCore::Frame::betterApproximateNode):
(WebCore::Frame::hitTestResultAtViewportLocation):
(WebCore::Frame::qualifyingNodeAtViewportLocation):
* rendering/HitTestRequest.h:
(WebCore::HitTestRequest::HitTestRequest):
(WebCore::HitTestRequest::readOnly const):
(WebCore::HitTestRequest::active const):
(WebCore::HitTestRequest::move const):
(WebCore::HitTestRequest::release const):
(WebCore::HitTestRequest::ignoreClipping const):
(WebCore::HitTestRequest::svgClipContent const):
(WebCore::HitTestRequest::touchEvent const):
(WebCore::HitTestRequest::disallowsUserAgentShadowContent const):
(WebCore::HitTestRequest::allowsFrameScrollbars const):
(WebCore::HitTestRequest::allowsChildFrameContent const):
(WebCore::HitTestRequest::allowsVisibleChildFrameContent const):
(WebCore::HitTestRequest::isChildFrameHitTest const):
(WebCore::HitTestRequest::resultIsElementList const):
(WebCore::HitTestRequest::includesAllElementsUnderPoint const):
(WebCore::HitTestRequest::type const):
* rendering/svg/RenderSVGResourceClipper.cpp:
(WebCore::RenderSVGResourceClipper::hitTestClipContent):
* testing/Internals.cpp:
(WebCore::Internals::nodesFromRect const):
* testing/Internals.mm:
(WebCore::Internals::rangeForDictionaryLookupAtLocation):

Source/WebKit:

* WebProcess/InjectedBundle/InjectedBundleNavigationAction.cpp:
(WebKit::InjectedBundleNavigationAction::InjectedBundleNavigationAction):
* WebProcess/WebPage/Cocoa/WebPageCocoa.mm:
(WebKit::WebPage::performDictionaryLookupAtLocation):
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::hitTest const):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::handleContextMenuEvent):
(WebKit::WebPage::characterIndexForPointAsync):
(WebKit::WebPage::determinePrimarySnapshottedPlugIn):
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::rectForElementAtInteractionLocation const):
(WebKit::WebPage::handleStylusSingleTapAtPoint):
(WebKit::rangeForPointInRootViewCoordinates):
(WebKit::WebPage::setFocusedFrameBeforeSelectingTextAtLocation):
(WebKit::selectionPositionInformation):
(WebKit::textInteractionPositionInformation):
(WebKit::WebPage::positionInformation):
* WebProcess/WebPage/mac/WebPageMac.mm:
(WebKit::WebPage::shouldDelayWindowOrderingEvent):
(WebKit::WebPage::acceptsFirstMouse):
(WebKit::WebPage::performImmediateActionHitTestAtLocation):

Source/WebKitLegacy/ios:

* WebCoreSupport/WebFrameIOS.mm:
(-[WebFrame elementRectAtPoint:]):

Source/WebKitLegacy/mac:

* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::actionDictionary const):
* WebView/WebFrame.mm:
(-[WebFrame elementAtPoint:]):
* WebView/WebHTMLView.mm:
(-[WebHTMLView elementAtPoint:allowShadowContent:]):
* WebView/WebImmediateActionController.mm:
(-[WebImmediateActionController performHitTestAtPoint:]):

Source/WebKitLegacy/win:

* WebActionPropertyBag.cpp:
(WebActionPropertyBag::Read):
* WebView.cpp:
(WebView::handleContextMenuEvent):
(WebView::gestureNotify):
(WebView::elementAtPoint):

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

5 months ago[GTK] Gardening, update TestExpectations
dpino@igalia.com [Thu, 27 Feb 2020 23:12:46 +0000 (23:12 +0000)]
[GTK] Gardening, update TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=208328

Unreviewed gardening.

* platform/gtk/TestExpectations:

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

5 months agoUpdate test262 (2020.02.26)
ross.kirsling@sony.com [Thu, 27 Feb 2020 23:04:08 +0000 (23:04 +0000)]
Update test262 (2020.02.26)
https://bugs.webkit.org/show_bug.cgi?id=208280

Reviewed by Yusuke Suzuki.

* test262/config.yaml:
* test262/expectations.yaml:
* test262/harness/async-gc.js:
* test262/latest-changes-summary.txt:
* test262/test/:
* test262/test262-Revision.txt:

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

5 months agoAXIsolatedObject support for table rows and ARIA tree/grid rows.
andresg_22@apple.com [Thu, 27 Feb 2020 22:59:24 +0000 (22:59 +0000)]
AXIsolatedObject support for table rows and ARIA tree/grid rows.
https://bugs.webkit.org/show_bug.cgi?id=208335

Reviewed by Chris Fleizach.

Covered by existing tests.

- Exposes the AccessibilityTableRow and AccessibilityARIAGridRow
interfaces through AXCoreObject.
- Eliminates the need of downcasting in the platform wrapper code, so
that it now works for both AXObjects and AXIsolatedObjects.
- Implements the above mentioned interfaces in AXIsolatedObject.

* accessibility/AccessibilityARIAGridRow.cpp:
(WebCore::AccessibilityARIAGridRow::disclosedRows):
* accessibility/AccessibilityARIAGridRow.h:
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::disclosedRows):
(WebCore::AccessibilityObject::ariaTreeItemDisclosedRows): Became disclosedRows.
* accessibility/AccessibilityObject.h:
* accessibility/AccessibilityObjectInterface.h:
* accessibility/AccessibilityTableRow.h:
(WebCore::AccessibilityTableRow::setRowIndex):
(WebCore::AccessibilityTableRow::rowIndex const): Deleted.
* accessibility/isolatedtree/AXIsolatedObject.cpp:
(WebCore::AXIsolatedObject::initializeAttributeData):
* accessibility/isolatedtree/AXIsolatedObject.h:
* accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):

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

5 months ago[CMake] Add WebKit::PAL target
don.olmstead@sony.com [Thu, 27 Feb 2020 22:37:01 +0000 (22:37 +0000)]
[CMake] Add WebKit::PAL target
https://bugs.webkit.org/show_bug.cgi?id=198493

Reviewed by Michael Catanzaro.

.:

Define WebKit::PAL target for Apple internal Windows builds.

* Source/cmake/target/PAL.cmake: Added.

Source/WebCore:

Use WebKit::PAL target.

* CMakeLists.txt:

Source/WebCore/PAL:

Define WebKit::PAL target.

* pal/CMakeLists.txt:
* pal/PlatformFTW.cmake:
* pal/PlatformWinCairo.cmake:

Source/WebKitLegacy:

Add include of PAL target for Apple internal Windows builds.

* CMakeLists.txt:

Tools:

Add workaround for Windows where PAL_FRAMEWORK_HEADERS_DIR is not propagating.

* DumpRenderTree/PlatformWin.cmake:

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

5 months ago[ Mac wk2 ] webgpu/whlsl/textures-sample.html is flaky failing.
lawrence.j@apple.com [Thu, 27 Feb 2020 22:21:01 +0000 (22:21 +0000)]
[ Mac wk2 ] webgpu/whlsl/textures-sample.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208340

Unreviewed test gardening.

* platform/mac-wk2/TestExpectations:

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

5 months agoFix flaky enter/exit PIP test
nham@apple.com [Thu, 27 Feb 2020 22:08:29 +0000 (22:08 +0000)]
Fix flaky enter/exit PIP test
https://bugs.webkit.org/show_bug.cgi?id=208272

Unreviewed test gardening.

This test sometimes fails because it presses the PIP control before the video starts
playing. Fix this by waiting for the playing event before pressing the control.

* media/modern-media-controls/pip-support/pip-support-click.html:
* platform/mac-wk2/TestExpectations:

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

5 months agoAdding myself to contributors.json
nham@apple.com [Thu, 27 Feb 2020 21:53:16 +0000 (21:53 +0000)]
Adding myself to contributors.json

Unreviewed

* Scripts/webkitpy/common/config/contributors.json:

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

5 months agoUnreviewed unified source builds fix.
ryanhaddad@apple.com [Thu, 27 Feb 2020 21:50:43 +0000 (21:50 +0000)]
Unreviewed unified source builds fix.
https://bugs.webkit.org/show_bug.cgi?id=207198

Include header files for types referenced in RemoteRenderingBackend.h.

Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2020-02-27

* GPUProcess/graphics/RemoteRenderingBackendProxy.h:
* WebProcess/GPU/graphics/RemoteRenderingBackend.h:

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

5 months ago[ iOS wk2 Release ] fast/text-autosizing/ios/idempotentmode/viewport-change-relayout...
ryanhaddad@apple.com [Thu, 27 Feb 2020 21:43:24 +0000 (21:43 +0000)]
[ iOS wk2 Release ] fast/text-autosizing/ios/idempotentmode/viewport-change-relayout.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208245

Unreviewed test gardening.

* platform/ios-wk2/TestExpectations: Mark test as flaky.

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

5 months agoMediaResourceLoader objects are leaking on reddit.com
peng.liu6@apple.com [Thu, 27 Feb 2020 20:12:35 +0000 (20:12 +0000)]
MediaResourceLoader objects are leaking on reddit.com
https://bugs.webkit.org/show_bug.cgi?id=208273

Reviewed by Jer Noble.

We retain the WebCoreNSURLSession delegate. There will be a retain cycle
if that delegate retains the session. This patch fixes the retain cycle problem
by referencing the delegate with a weak pointer.

Manually tested.

* platform/network/cocoa/WebCoreNSURLSession.h:
* platform/network/cocoa/WebCoreNSURLSession.mm:
(-[WebCoreNSURLSession delegate]):

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

5 months agoREGRESSION: (257072) [ Mac wk2 Release ] fast/harness/uiscriptcontroller/concurrent...
antti@apple.com [Thu, 27 Feb 2020 19:49:58 +0000 (19:49 +0000)]
REGRESSION: (257072) [ Mac wk2 Release ] fast/harness/uiscriptcontroller/concurrent-ui-side-scripts.html is flaky failing.
https://bugs.webkit.org/show_bug.cgi?id=208264
<rdar://problem/59821552>

Reviewed by Simon Fraser.

* fast/harness/uiscriptcontroller/concurrent-ui-side-scripts-expected.txt:
* fast/harness/uiscriptcontroller/concurrent-ui-side-scripts.html:

There is no guarantee that two independent async UI scripts finish in particular order. Order the output instead.

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

5 months agoAdd ENABLE(SCROLLING_THREAD) and use it to turn off some code we don't need for iOS
simon.fraser@apple.com [Thu, 27 Feb 2020 19:30:45 +0000 (19:30 +0000)]
Add ENABLE(SCROLLING_THREAD) and use it to turn off some code we don't need for iOS
https://bugs.webkit.org/show_bug.cgi?id=208282

Reviewed by Tim Horton.
Source/WebCore:

Protect ThreadedScrollingTree and ScrollingCoordinatorMac with ENABLE(SCROLLING_THREAD).

* page/scrolling/ThreadedScrollingTree.cpp:
* page/scrolling/ThreadedScrollingTree.h:
* page/scrolling/mac/ScrollingCoordinatorMac.h:
* page/scrolling/mac/ScrollingCoordinatorMac.mm:
* page/scrolling/mac/ScrollingTreeMac.cpp:
* page/scrolling/mac/ScrollingTreeMac.h:

Source/WebKit:

Protect scrolling-thread related code in EventDispatcher with ENABLE(SCROLLING_THREAD),
and don't register pages with EventDispatcher unless ENABLE(SCROLLING_THREAD) is true.

* WebProcess/WebPage/EventDispatcher.cpp:
(WebKit::EventDispatcher::wheelEvent):
* WebProcess/WebPage/EventDispatcher.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::WebPage::close):

Source/WTF:

Define ENABLE_SCROLLING_THREAD PLATFORM(MAC) and USE(NICOSIA).

* wtf/PlatformEnable.h:
* wtf/PlatformEnableCocoa.h:

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

5 months agoAdd GPU Process support for accessLog et al.
commit-queue@webkit.org [Thu, 27 Feb 2020 19:14:31 +0000 (19:14 +0000)]
Add GPU Process support for accessLog et al.
https://bugs.webkit.org/show_bug.cgi?id=207007

Patch by Tim Monroe <timmon@apple.com> on 2020-02-27
Reviewed by Jon Lee.

No tests included here.

* GPUProcess/media/RemoteMediaPlayerManagerProxy.cpp:
(WebKit::RemoteMediaPlayerManagerProxy::updateVideoFullscreenInlineImage):
(WebKit::RemoteMediaPlayerManagerProxy::setVideoFullscreenFrame):
(WebKit::RemoteMediaPlayerManagerProxy::setVideoFullscreenGravity):
(WebKit::RemoteMediaPlayerManagerProxy::setVideoFullscreenMode):
(WebKit::RemoteMediaPlayerManagerProxy::setVolume):
(WebKit::RemoteMediaPlayerManagerProxy::setBufferingPolicy):
(WebKit::RemoteMediaPlayerManagerProxy::videoFullscreenStandbyChanged):
(WebKit::RemoteMediaPlayerManagerProxy::accessLog):
(WebKit::RemoteMediaPlayerManagerProxy::errorLog):
* GPUProcess/media/RemoteMediaPlayerManagerProxy.h:
* GPUProcess/media/RemoteMediaPlayerManagerProxy.messages.in:
* GPUProcess/media/RemoteMediaPlayerProxy.cpp:
(WebKit::RemoteMediaPlayerProxy::updateVideoFullscreenInlineImage):
(WebKit::RemoteMediaPlayerProxy::setVideoFullscreenMode):
(WebKit::RemoteMediaPlayerProxy::setBufferingPolicy):
(WebKit::RemoteMediaPlayerProxy::videoFullscreenStandbyChanged):
(WebKit::RemoteMediaPlayerProxy::accessLog):
(WebKit::RemoteMediaPlayerProxy::errorLog):
* GPUProcess/media/RemoteMediaPlayerProxy.h:
* GPUProcess/media/RemoteMediaPlayerProxy.messages.in:
* WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:
(WebKit::MediaPlayerPrivateRemote::updateVideoFullscreenInlineImage):
(WebKit::MediaPlayerPrivateRemote::setVideoFullscreenMode):
(WebKit::MediaPlayerPrivateRemote::videoFullscreenStandbyChanged):
(WebKit::MediaPlayerPrivateRemote::accessLog const):
(WebKit::MediaPlayerPrivateRemote::errorLog const):
(WebKit::MediaPlayerPrivateRemote::setBufferingPolicy):

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

5 months ago[ iOS wk2 ] crypto/subtle/rsa-indexeddb-non-exportable-private.html is flaky timing...
lawrence.j@apple.com [Thu, 27 Feb 2020 19:03:08 +0000 (19:03 +0000)]
[ iOS wk2 ] crypto/subtle/rsa-indexeddb-non-exportable-private.html is flaky timing out.
https://bugs.webkit.org/show_bug.cgi?id=207660

Unreviewed test gardening.

* platform/ios-wk2/TestExpectations:

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

5 months ago[iOS] Issue mach sandbox extensions to the WebContent process for a set of specific...
pvollan@apple.com [Thu, 27 Feb 2020 18:48:36 +0000 (18:48 +0000)]
[iOS] Issue mach sandbox extensions to the WebContent process for a set of specific services
https://bugs.webkit.org/show_bug.cgi?id=208146

Reviewed by Brent Fulgham.

Source/WebKit:

We are still seeing some accesses from the WebContent process to a small set of services. Since we do not currently have
backtraces for these accesses, make a speculative patch, where we issue these extension for all apps except Safari.

Test: fast/sandbox/ios/sandbox-mach-lookup-mail.html

* Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
* Shared/WebProcessCreationParameters.cpp:
(WebKit::WebProcessCreationParameters::encode const):
(WebKit::WebProcessCreationParameters::decode):
* Shared/WebProcessCreationParameters.h:
* UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::platformInitializeWebProcess):
* WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::platformInitializeWebProcess):

LayoutTests:

* fast/sandbox/ios/sandbox-mach-lookup-mail-expected.txt:
* fast/sandbox/ios/sandbox-mach-lookup-mail.html:

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

5 months ago[CSS Backgrounds] Skip WPT tests always crashing in Debug.
clopez@igalia.com [Thu, 27 Feb 2020 18:15:38 +0000 (18:15 +0000)]
[CSS Backgrounds] Skip WPT tests always crashing in Debug.

Unreviewed gardening. See https://webkit.org/b/206579#c1

* TestExpectations:

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

5 months agoAdd referrerpolicy attribute support for images
commit-queue@webkit.org [Thu, 27 Feb 2020 18:08:19 +0000 (18:08 +0000)]
Add referrerpolicy attribute support for images
https://bugs.webkit.org/show_bug.cgi?id=207901

Patch by Rob Buis <rbuis@igalia.com> on 2020-02-27
Reviewed by Darin Adler.

LayoutTests/imported/w3c:

Update improved test results.

* web-platform-tests/html/dom/idlharness.https-expected.txt:
* web-platform-tests/html/dom/interfaces-expected.txt:
* web-platform-tests/html/dom/reflection-embedded-expected.txt:
* web-platform-tests/html/semantics/embedded-content/the-img-element/original-referrer-policy-applied.sub-expected.txt:

Source/WebCore:

This patch adds 'referrerpolicy' attribute support for img elements.
If set, the value is restricted to the ReferrerPolicy enum, and
if valid it is used for the script fetch.
If not set or invalid, the current behavior is kept.

Tests: http/tests/referrer-policy-img/no-referrer-when-downgrade/cross-origin-http-http.html
       http/tests/referrer-policy-img/no-referrer-when-downgrade/cross-origin-http.https.html
       http/tests/referrer-policy-img/no-referrer-when-downgrade/same-origin.html
       http/tests/referrer-policy-img/no-referrer/cross-origin-http-http.html
       http/tests/referrer-policy-img/no-referrer/cross-origin-http.https.html
       http/tests/referrer-policy-img/no-referrer/same-origin.html
       http/tests/referrer-policy-img/origin-when-cross-origin/cross-origin-http-http.html
       http/tests/referrer-policy-img/origin-when-cross-origin/cross-origin-http.https.html
       http/tests/referrer-policy-img/origin-when-cross-origin/same-origin.html
       http/tests/referrer-policy-img/origin/cross-origin-http-http.html
       http/tests/referrer-policy-img/origin/cross-origin-http.https.html
       http/tests/referrer-policy-img/origin/same-origin.html
       http/tests/referrer-policy-img/same-origin/cross-origin-http-http.html
       http/tests/referrer-policy-img/same-origin/cross-origin-http.https.html
       http/tests/referrer-policy-img/same-origin/same-origin.html
       http/tests/referrer-policy-img/strict-origin-when-cross-origin/cross-origin-http-http.html
       http/tests/referrer-policy-img/strict-origin-when-cross-origin/cross-origin-http.https.html
       http/tests/referrer-policy-img/strict-origin-when-cross-origin/same-origin.html
       http/tests/referrer-policy-img/strict-origin/cross-origin-http-http.html
       http/tests/referrer-policy-img/strict-origin/cross-origin-http.https.html
       http/tests/referrer-policy-img/strict-origin/same-origin.html
       http/tests/referrer-policy-img/unsafe-url/cross-origin-http-http.html
       http/tests/referrer-policy-img/unsafe-url/cross-origin-http.https.html
       http/tests/referrer-policy-img/unsafe-url/same-origin.html

* html/HTMLImageElement.cpp:
(WebCore::HTMLImageElement::setReferrerPolicyForBindings):
(WebCore::HTMLImageElement::referrerPolicyForBindings const):
(WebCore::HTMLImageElement::referrerPolicy const):
* html/HTMLImageElement.h:
* html/HTMLImageElement.idl:
* loader/ImageLoader.cpp:
(WebCore::ImageLoader::updateFromElement):

LayoutTests:

Add tests for images with various referrerpolicy attribute values.

* http/tests/referrer-policy-img/no-referrer-when-downgrade/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/no-referrer-when-downgrade/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/no-referrer-when-downgrade/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/no-referrer-when-downgrade/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/no-referrer-when-downgrade/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/no-referrer-when-downgrade/same-origin.html: Added.
* http/tests/referrer-policy-img/no-referrer/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/no-referrer/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/no-referrer/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/no-referrer/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/no-referrer/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/no-referrer/same-origin.html: Added.
* http/tests/referrer-policy-img/origin-when-cross-origin/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/origin-when-cross-origin/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/origin-when-cross-origin/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/origin-when-cross-origin/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/origin-when-cross-origin/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/origin-when-cross-origin/same-origin.html: Added.
* http/tests/referrer-policy-img/origin/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/origin/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/origin/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/origin/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/origin/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/origin/same-origin.html: Added.
* http/tests/referrer-policy-img/same-origin/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/same-origin/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/same-origin/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/same-origin/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/same-origin/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/same-origin/same-origin.html: Added.
* http/tests/referrer-policy-img/strict-origin-when-cross-origin/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/strict-origin-when-cross-origin/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/strict-origin-when-cross-origin/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/strict-origin-when-cross-origin/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/strict-origin-when-cross-origin/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/strict-origin-when-cross-origin/same-origin.html: Added.
* http/tests/referrer-policy-img/strict-origin/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/strict-origin/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/strict-origin/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/strict-origin/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/strict-origin/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/strict-origin/same-origin.html: Added.
* http/tests/referrer-policy-img/unsafe-url/cross-origin-http-http-expected.txt: Added.
* http/tests/referrer-policy-img/unsafe-url/cross-origin-http-http.html: Added.
* http/tests/referrer-policy-img/unsafe-url/cross-origin-http.https-expected.txt: Added.
* http/tests/referrer-policy-img/unsafe-url/cross-origin-http.https.html: Added.
* http/tests/referrer-policy-img/unsafe-url/same-origin-expected.txt: Added.
* http/tests/referrer-policy-img/unsafe-url/same-origin.html: Added.
* http/tests/referrer-policy-script/unsafe-url/cross-origin-http-http.html:
* http/tests/referrer-policy/resources/image.php: Added.
* platform/gtk/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
* platform/ios-wk2/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
* platform/ios-wk2/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt:
* platform/ios/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt:
* platform/mac-wk1/TestExpectations:
* platform/mac-wk1/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
* platform/mac-wk2/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
* platform/win/TestExpectations:
* platform/wpe/imported/w3c/web-platform-tests/html/dom/idlharness.https-expected.txt:
* platform/wpe/imported/w3c/web-platform-tests/html/dom/interfaces-expected.txt:
* platform/wpe/imported/w3c/web-platform-tests/html/dom/reflection-embedded-expected.txt:

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

5 months agoAdd SPI to query WKFrameInfos in a WKWebView
achristensen@apple.com [Thu, 27 Feb 2020 18:07:05 +0000 (18:07 +0000)]
Add SPI to query WKFrameInfos in a WKWebView
https://bugs.webkit.org/show_bug.cgi?id=208212

Reviewed by Brady Eidson.

Source/WebKit:

This adds WKWebView._allFrames and SPI on WKFrameInfo to look at parent and child frames.
This will help with rdar://problem/59783184 and other similar tasks.
In order to do this, I needed to make API::FrameInfo::create take a WebKit::FrameInfoData,
which I pass from the WebProcess.  Where we used to pass only a SecurityOriginData,
we now pass a FrameInfoData which contains a SecurityOriginData and more information.
I needed to deprecate WKFrameCreateFrameInfo which had its last use removed in rdar://problem/59768710
because there was not enough information in its parameters to create a WKFrameInfo with this new data.
I also replaced the test-only SPI WKFrameInfoGetFrameHandleRef with WKFrameInfoCreateFrameHandleRef
so we don't need to keep a strong reference to the handle and other new members in API::FrameInfo.

New functionality covered by API tests and I removed the last tests' use of now-deprecated WKFrameCreateFrameInfo.

* Shared/FrameInfoData.cpp:
(WebKit::FrameInfoData::encode const):
(WebKit::FrameInfoData::decode):
* Shared/FrameInfoData.h:
* UIProcess/API/APIFrameInfo.cpp:
(API::FrameInfo::FrameInfo):
(API::FrameInfo::handle const):
(API::FrameInfo::parentFrameHandle const):
(API::FrameInfo::childFrameHandles const):
(): Deleted.
* UIProcess/API/APIFrameInfo.h:
* UIProcess/API/APINavigationClient.h:
(API::NavigationClient::didFailProvisionalLoadInSubframeWithError):
* UIProcess/API/APIUIClient.h:
(API::UIClient::runJavaScriptAlert):
(API::UIClient::runJavaScriptConfirm):
(API::UIClient::runJavaScriptPrompt):
(API::UIClient::runBeforeUnloadConfirmPanel):
(API::UIClient::runOpenPanel):
(API::UIClient::decidePolicyForGeolocationPermissionRequest):
(API::UIClient::runWebAuthenticationPanel):
* UIProcess/API/C/WKFrame.cpp:
(WKFrameCreateFrameInfo):
* UIProcess/API/C/WKFrame.h:
* UIProcess/API/C/WKFrameInfoRef.cpp:
(WKFrameInfoCreateFrameHandleRef):
(WKFrameInfoGetFrameHandleRef): Deleted.
* UIProcess/API/C/WKFrameInfoRef.h:
* UIProcess/API/C/WKPage.cpp:
(WKPageSetPageUIClient):
(WKPageSetPageNavigationClient):
* UIProcess/API/Cocoa/WKFrameInfo.mm:
(-[WKFrameInfo securityOrigin]):
(-[WKFrameInfo _handle]):
(-[WKFrameInfo _parentFrameHandle]):
(-[WKFrameInfo _childFrameHandles]):
* UIProcess/API/Cocoa/WKFrameInfoPrivate.h:
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _allFrames:]):
* UIProcess/API/Cocoa/WKWebViewPrivate.h:
* UIProcess/Cocoa/NavigationState.h:
* UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::NavigationClient::didFailProvisionalLoadInSubframeWithError):
* UIProcess/Cocoa/SOAuthorization/SOAuthorizationCoordinator.mm:
(WebKit::SOAuthorizationCoordinator::tryAuthorize):
* UIProcess/Cocoa/SOAuthorization/SOAuthorizationSession.mm:
(WebKit::SOAuthorizationSession::continueStartAfterDecidePolicy):
* UIProcess/Cocoa/UIDelegate.h:
* UIProcess/Cocoa/UIDelegate.mm:
(WebKit::UIDelegate::UIClient::runJavaScriptAlert):
(WebKit::UIDelegate::UIClient::runJavaScriptConfirm):
(WebKit::UIDelegate::UIClient::runJavaScriptPrompt):
(WebKit::UIDelegate::UIClient::decidePolicyForGeolocationPermissionRequest):
(WebKit::UIDelegate::UIClient::runBeforeUnloadConfirmPanel):
(WebKit::UIDelegate::UIClient::runOpenPanel):
(WebKit::UIDelegate::UIClient::runWebAuthenticationPanel):
* UIProcess/PageClient.h:
* UIProcess/ProvisionalPageProxy.cpp:
(WebKit::ProvisionalPageProxy::didFailProvisionalLoadForFrame):
(WebKit::ProvisionalPageProxy::decidePolicyForNavigationActionAsync):
(WebKit::ProvisionalPageProxy::decidePolicyForResponse):
(WebKit::ProvisionalPageProxy::decidePolicyForNavigationActionSync):
* UIProcess/ProvisionalPageProxy.h:
* UIProcess/WebAuthentication/AuthenticatorManager.cpp:
(WebKit::AuthenticatorManager::runPanel):
* UIProcess/WebAuthentication/WebAuthenticationRequestData.h:
* UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.cpp:
(WebKit::WebAuthenticatorCoordinatorProxy::makeCredential):
(WebKit::WebAuthenticatorCoordinatorProxy::getAssertion):
* UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.h:
* UIProcess/WebAuthentication/WebAuthenticatorCoordinatorProxy.messages.in:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::getAllFrames):
(WebKit::WebPageProxy::didFailProvisionalLoadForFrame):
(WebKit::WebPageProxy::didFailProvisionalLoadForFrameShared):
(WebKit::WebPageProxy::decidePolicyForNavigationActionAsync):
(WebKit::WebPageProxy::decidePolicyForNavigationActionAsyncShared):
(WebKit::WebPageProxy::decidePolicyForNavigationAction):
(WebKit::WebPageProxy::decidePolicyForNavigationActionSync):
(WebKit::WebPageProxy::decidePolicyForNavigationActionSyncShared):
(WebKit::WebPageProxy::decidePolicyForNewWindowAction):
(WebKit::WebPageProxy::decidePolicyForResponse):
(WebKit::WebPageProxy::decidePolicyForResponseShared):
(WebKit::WebPageProxy::runJavaScriptAlert):
(WebKit::WebPageProxy::runJavaScriptConfirm):
(WebKit::WebPageProxy::runJavaScriptPrompt):
(WebKit::WebPageProxy::runBeforeUnloadConfirmPanel):
(WebKit::WebPageProxy::runOpenPanel):
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/ios/PageClientImplIOS.h:
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::decidePolicyForGeolocationPermissionRequest):
* WebProcess/Geolocation/GeolocationPermissionRequestManager.cpp:
(WebKit::GeolocationPermissionRequestManager::startRequestForGeolocation):
* WebProcess/WebAuthentication/WebAuthenticatorCoordinator.cpp:
(WebKit::WebAuthenticatorCoordinator::makeCredential):
(WebKit::WebAuthenticatorCoordinator::getAssertion):
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::runBeforeUnloadConfirmPanel):
(WebKit::WebChromeClient::runJavaScriptAlert):
(WebKit::WebChromeClient::runJavaScriptConfirm):
(WebKit::WebChromeClient::runJavaScriptPrompt):
(WebKit::WebChromeClient::runOpenPanel):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDidFailProvisionalLoad):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNewWindowAction):
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
* WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::childFrameIDs const):
(WebKit::WebFrame::info const):
* WebProcess/WebPage/WebFrame.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::getAllFrames):
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebPage/WebPage.messages.in:

Tools:

* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKit/FrameHandle.cpp: Removed.
* WebKitTestRunner/TestController.cpp:
(WTR::TestController::saltForOrigin):

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

5 months agoCleanup HitTestResult.{h, cpp}
dbates@webkit.org [Thu, 27 Feb 2020 17:34:38 +0000 (17:34 +0000)]
Cleanup HitTestResult.{h, cpp}
https://bugs.webkit.org/show_bug.cgi?id=208269
<rdar://problem/59824186>

Reviewed by Alex Christensen.

Use modern C++ features to remove duplicate code.

* rendering/HitTestLocation.cpp:
(WebCore::HitTestLocation::HitTestLocation):
* rendering/HitTestLocation.h:
* rendering/HitTestResult.cpp: Remove unnecessary #includes.
* rendering/HitTestResult.h: Remove unnecessary #includes.
(WebCore::HitTestResult::setIsOverWidget):

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

5 months agoUnreviewed build fix for non-unified builds after r257507.
zalan@apple.com [Thu, 27 Feb 2020 16:52:46 +0000 (16:52 +0000)]
Unreviewed build fix for non-unified builds after r257507.

* layout/blockformatting/BlockFormattingContext.h:
* layout/blockformatting/BlockMarginCollapse.cpp:
(WebCore::Layout::BlockFormattingContext::MarginCollapse::computedPositiveAndNegativeMargin const):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::updateMarginAfterForPreviousSibling):
(WebCore::Layout::computedPositiveAndNegativeMargin): Deleted.

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

5 months agoUnreviewed, rolling out r257530.
jacob_uphoff@apple.com [Thu, 27 Feb 2020 16:31:26 +0000 (16:31 +0000)]
Unreviewed, rolling out r257530.

This commit seems to have broke the build internally for
watchOS

Reverted changeset:

"Add SPI to query WKFrameInfos in a WKWebView"
https://bugs.webkit.org/show_bug.cgi?id=208212
https://trac.webkit.org/changeset/257530

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

5 months agoLoad async scripts with low priority
antti@apple.com [Thu, 27 Feb 2020 16:02:09 +0000 (16:02 +0000)]
Load async scripts with low priority
https://bugs.webkit.org/show_bug.cgi?id=208298

Reviewed by Anders Carlsson.

They are assumed to be non-critical and don't delay DOMContentLoaded.

This matches other browsers. See https://addyosmani.com/blog/script-priorities/ for Chrome behavior.

* bindings/js/CachedScriptFetcher.cpp:
(WebCore::CachedScriptFetcher::requestModuleScript const):
(WebCore::CachedScriptFetcher::requestScriptWithCache const)

Pass around the priority.

* bindings/js/CachedScriptFetcher.h:
* dom/LoadableClassicScript.cpp:
(WebCore::LoadableClassicScript::create):
(WebCore::LoadableClassicScript::load):

Deprioritize async script load.

* dom/LoadableClassicScript.h:
* dom/ScriptElement.cpp:
(WebCore::ScriptElement::requestClassicScript):

Pass around the information that this is an async script.

* dom/ScriptElementCachedScriptFetcher.cpp:
(WebCore::ScriptElementCachedScriptFetcher::requestModuleScript const):
* html/parser/HTMLPreloadScanner.cpp:
(WebCore::TokenPreloadScanner::StartTagScanner::createPreloadRequest):
(WebCore::TokenPreloadScanner::StartTagScanner::processAttribute):

Parse async attribute in preload scanner.

* html/parser/HTMLResourcePreloader.cpp:
(WebCore::PreloadRequest::resourceRequest):

Deprioritize async script preload.

* html/parser/HTMLResourcePreloader.h:
(WebCore::PreloadRequest::setScriptIsAsync):

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

5 months ago[CMake] Use WEBKIT_EXECUTABLE in MiniBrowser
don.olmstead@sony.com [Thu, 27 Feb 2020 14:36:58 +0000 (14:36 +0000)]
[CMake] Use WEBKIT_EXECUTABLE in MiniBrowser
https://bugs.webkit.org/show_bug.cgi?id=206894

Reviewed by Adrian Perez de Castro.

.:

Add a MiniBrowser derived sources directory.

* Source/cmake/WebKitFS.cmake:

Tools:

Modify CMake ports to use WEBKIT_EXECUTABLE when creating their respective
MiniBrowsers.

* MiniBrowser/gtk/CMakeLists.txt:
* MiniBrowser/win/CMakeLists.txt:
* MiniBrowser/wpe/CMakeLists.txt:

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

5 months ago[LFC][Integration] Build and enable for the WPE and GTK ports
aperez@igalia.com [Thu, 27 Feb 2020 14:07:22 +0000 (14:07 +0000)]
[LFC][Integration] Build and enable for the WPE and GTK ports
https://bugs.webkit.org/show_bug.cgi?id=208289

Reviewed by Carlos Garcia Campos.

Enable LFC for the WPE and GTK ports.

* Source/cmake/OptionsGTK.cmake: LFC enabled as experimental feature.
* Source/cmake/OptionsWPE.cmake: Ditto.

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

5 months agoWeb Inspector: localize the placeholder "Header" and "value" when editing a local...
drousso@apple.com [Thu, 27 Feb 2020 08:25:18 +0000 (08:25 +0000)]
Web Inspector: localize the placeholder "Header" and "value" when editing a local override
https://bugs.webkit.org/show_bug.cgi?id=208276
<rdar://problem/59763619>

Reviewed by Brian Burg.

* Localizations/en.lproj/localizedStrings.js:
* UserInterface/Views/LocalResourceOverridePopover.js:
(WI.LocalResourceOverridePopover.prototype.show):

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

5 months agoWeb platform tests for Web Share API fail incorrectly
commit-queue@webkit.org [Thu, 27 Feb 2020 05:22:46 +0000 (05:22 +0000)]
Web platform tests for Web Share API fail incorrectly
https://bugs.webkit.org/show_bug.cgi?id=208083

Patch by Nikos Mouchtaris <nmouchtaris@apple.com> on 2020-02-26
Reviewed by Alex Christensen.

LayoutTests/imported/w3c:

Fixed expected for updated wpts.

* web-platform-tests/web-share/share-without-user-gesture.https-expected.txt:
* web-platform-tests/web-share/canShare-files.https-expected.txt:
* web-platform-tests/web-share/canShare.https-expected.txt:
* web-platform-tests/web-share/idlharness.https.window-expected.txt:

LayoutTests:

Removed duplicate tests for corresponding wpts, fixed expected
for new wpts. Modified TestExpectations to now run all web-share
wpts except for those testing secure context behavior, which is not
supported by the current wpt infrastructure.

* TestExpectations:
* fast/web-share/canShare-expected.txt: Removed.
* fast/web-share/canShare-files-expected.txt: Removed.
* fast/web-share/canShare-files.html: Removed.
* fast/web-share/canShare.html: Removed.
* fast/web-share/share-empty-expected.txt: Removed.
* fast/web-share/share-empty.html: Removed.
* fast/web-share/share-url-invalid-expected.txt: Removed.
* fast/web-share/share-without-user-gesture-expected.txt: Removed.
* fast/web-share/share-without-user-gesture.html: Removed.

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

5 months agoAnnotate mediaType with an availability macro.
beidson@apple.com [Thu, 27 Feb 2020 05:17:40 +0000 (05:17 +0000)]
Annotate mediaType with an availability macro.
https://bugs.webkit.org/show_bug.cgi?id=208284

Reviewed by Alex Christensen.

* UIProcess/API/Cocoa/WKWebView.h:

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

5 months ago[bmalloc][PlayStation] Set Scavenger's thread name.
basuke.suzuki@sony.com [Thu, 27 Feb 2020 04:56:58 +0000 (04:56 +0000)]
[bmalloc][PlayStation] Set Scavenger's thread name.
https://bugs.webkit.org/show_bug.cgi?id=208268

Reviewed by Alex Christensen.

We also need to have our thread with proper name.

* bmalloc/Scavenger.cpp:
(bmalloc::Scavenger::setThreadName):

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

5 months agoRemove unused WebsiteDataStore::setSourceApplicationBundleIdentifier
achristensen@apple.com [Thu, 27 Feb 2020 04:43:32 +0000 (04:43 +0000)]
Remove unused WebsiteDataStore::setSourceApplicationBundleIdentifier
https://bugs.webkit.org/show_bug.cgi?id=206456

Reviewed by Brady Eidson.

Source/WebKit:

The replacement on WebsiteDataStoreConfiguration has been adopted.

* UIProcess/API/Cocoa/WKWebsiteDataStore.mm:
(-[WKWebsiteDataStore _sourceApplicationBundleIdentifier]):
(-[WKWebsiteDataStore _setSourceApplicationBundleIdentifier:]):
* UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::setSourceApplicationBundleIdentifier): Deleted.
* UIProcess/WebsiteData/WebsiteDataStore.h:
(WebKit::WebsiteDataStore::sourceApplicationBundleIdentifier const):

Tools:

* TestWebKitAPI/Tests/WebKitCocoa/WebsiteDataStoreCustomPaths.mm:
(TEST):

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