Timeline
Feb 16, 2019:
- 11:16 AM Changeset in webkit [241650] by
-
- 2 edits3 adds in releases/WebKitGTK/webkit-2.22/Tools
[GTK] Update-webkitgtk-libs for Webkit GTK 2.22 can not be generated anymore
https://bugs.webkit.org/show_bug.cgi?id=194744
Patch by Pablo Saavedra <Pablo Saavedra> on 2019-02-16
Reviewed by Philippe Normand.
- gstreamer/patches/gst-plugins-good-0007-matroskademux-Allow-Matroska-headers-to-be-read-more.patch: Added.
- gstreamer/patches/gst-plugins-good-0008-matroskademux-Refactor-track-parsing-out-from-adding.patch: Added.
- gstreamer/patches/gst-plugins-good-0009-matroskademux-Parse-successive-Tracks-elements.patch: Added.
- 10:50 AM Changeset in webkit [241649] by
-
- 17 edits in trunk/Source/JavaScriptCore
[JSC] JSWrapperObject should not be destructible
https://bugs.webkit.org/show_bug.cgi?id=194743
Reviewed by Saam Barati.
JSWrapperObject should be just a wrapper object for JSValue, thus, it should not be a JSDestructibleObject.
Currently it is destructible object because DateInstance uses it. This patch changes Base of DateInstance from
JSWrapperObject to JSDestructibleObject, and makes JSWrapperObject non-destructible.
- runtime/BigIntObject.cpp:
(JSC::BigIntObject::BigIntObject):
- runtime/BooleanConstructor.cpp:
(JSC::BooleanConstructor::finishCreation):
- runtime/BooleanObject.cpp:
(JSC::BooleanObject::BooleanObject):
- runtime/BooleanObject.h:
- runtime/DateInstance.cpp:
(JSC::DateInstance::DateInstance):
(JSC::DateInstance::finishCreation):
- runtime/DateInstance.h:
- runtime/DatePrototype.cpp:
(JSC::dateProtoFuncGetTime):
(JSC::dateProtoFuncSetTime):
(JSC::setNewValueFromTimeArgs):
(JSC::setNewValueFromDateArgs):
(JSC::dateProtoFuncSetYear):
- runtime/JSCPoison.h:
- runtime/JSWrapperObject.h:
(JSC::JSWrapperObject::JSWrapperObject):
- runtime/NumberObject.cpp:
(JSC::NumberObject::NumberObject):
- runtime/NumberObject.h:
- runtime/StringConstructor.cpp:
(JSC::StringConstructor::finishCreation):
- runtime/StringObject.cpp:
(JSC::StringObject::StringObject):
- runtime/StringObject.h:
(JSC::StringObject::internalValue const):
- runtime/SymbolObject.cpp:
(JSC::SymbolObject::SymbolObject):
- runtime/SymbolObject.h:
- 8:28 AM Changeset in webkit [241648] by
-
- 4 edits in trunk
[LFC] RenderImage's default intrinsic size is 0.
https://bugs.webkit.org/show_bug.cgi?id=194745
Reviewed by Antti Koivisto.
Source/WebCore:
While the images are being loaded, their intrinsic size is set to 0 (RenderImage c'tor). Note that this code is temporary.
- layout/layouttree/LayoutTreeBuilder.cpp:
(WebCore::Layout::TreeBuilder::createSubTree):
Tools:
- LayoutReloaded/misc/LFC-passing-tests.txt:
- 4:56 AM Changeset in webkit [241647] by
-
- 5 edits2 adds in trunk
[LFC][BFC] Add support for block replaced intrinsic width.
https://bugs.webkit.org/show_bug.cgi?id=194705
Reviewed by Simon Fraser.
Source/WebCore:
Replaced boxes should report their intrinsic width as preferred widths.
Test: fast/block/block-only/replaced-intrinsic-width-simple.html
- layout/blockformatting/BlockFormattingContextGeometry.cpp:
(WebCore::Layout::BlockFormattingContext::Geometry::intrinsicWidthConstraints):
Tools:
- LayoutReloaded/misc/LFC-passing-tests.txt:
LayoutTests:
- fast/block/block-only/replaced-intrinsic-width-simple-expected.html: Added.
- fast/block/block-only/replaced-intrinsic-width-simple.html: Added.
- 4:54 AM Changeset in webkit [241646] by
-
- 5 edits2 adds in trunk
[LFC] Apply min/max width constraints to preferred width computation
https://bugs.webkit.org/show_bug.cgi?id=194739
Reviewed by Simon Fraser.
Source/WebCore:
Ensure that both min-height and max-height are taken into account while computing the preferred width.
Test: fast/block/block-only/min-max-and-preferred-width-simple.html
- layout/blockformatting/BlockFormattingContextGeometry.cpp:
(WebCore::Layout::BlockFormattingContext::Geometry::intrinsicWidthConstraints):
Tools:
- LayoutReloaded/misc/LFC-passing-tests.txt:
LayoutTests:
- fast/block/block-only/min-max-and-preferred-width-simple-expected.html: Added.
- fast/block/block-only/min-max-and-preferred-width-simple.html: Added.
- 12:58 AM Changeset in webkit [241645] by
-
- 13 edits in trunk/Source/JavaScriptCore
[JSC] Shrink UnlinkedFunctionExecutable
https://bugs.webkit.org/show_bug.cgi?id=194733
Reviewed by Mark Lam.
UnlinkedFunctionExecutable has sourceURLDirective and sourceMappingURLDirective. These
directives can be found in the comment of non typical function's source code (Program,
Eval code, and Global function from function constructor etc.), and tricky thing is that
SourceProvider's directives are updated by Parser. The reason why we have these fields in
UnlinkedFunctionExecutable is that we need to update the SourceProvider's directives even
if we skip parsing by using CodeCache. These fields are effective only if (1)
UnlinkedFunctionExecutable is for non typical function things, and (2) it has sourceURLDirective
or sourceMappingURLDirective. This is rare enough to purge them to a separated
UnlinkedFunctionExecutable::RareData to make UnlinkedFunctionExecutable small.
sizeof(UnlinkedFunctionExecutable) is very important since it is super frequently allocated
cell. Furthermore, the current JSC allocates two MarkedBlocks for UnlinkedFunctionExecutable
in JSGlobalObject initialization, but the usage of the second MarkedBlock is quite low (8%).
If we can reduce the size of UnlinkedFunctionExecutable, we can make them one MarkedBlock.
Since UnlinkedFunctionExecutable is allocated from IsoSubspace, we do not need to fit it to
one of size class.
This patch adds RareData to UnlinkedFunctionExecutable and move some rare datas into RareData.
And kill one MarkedBlock allocation in JSC initialization phase.
- bytecode/UnlinkedFunctionExecutable.cpp:
(JSC::UnlinkedFunctionExecutable::UnlinkedFunctionExecutable):
(JSC::UnlinkedFunctionExecutable::ensureRareDataSlow):
- bytecode/UnlinkedFunctionExecutable.h:
- debugger/DebuggerLocation.cpp:
(JSC::DebuggerLocation::DebuggerLocation):
- inspector/ScriptDebugServer.cpp:
(Inspector::ScriptDebugServer::dispatchDidParseSource):
- parser/Lexer.h:
(JSC::Lexer::sourceURLDirective const):
(JSC::Lexer::sourceMappingURLDirective const):
(JSC::Lexer::sourceURL const): Deleted.
(JSC::Lexer::sourceMappingURL const): Deleted.
- parser/Parser.h:
(JSC::Parser<LexerType>::parse):
- parser/SourceProvider.h:
(JSC::SourceProvider::sourceURLDirective const):
(JSC::SourceProvider::sourceMappingURLDirective const):
(JSC::SourceProvider::setSourceURLDirective):
(JSC::SourceProvider::setSourceMappingURLDirective):
(JSC::SourceProvider::sourceURL const): Deleted. We rename it from sourceURL to sourceURLDirective
since it is the correct name.
(JSC::SourceProvider::sourceMappingURL const): Deleted. We rename it from sourceMappingURL to
sourceMappingURLDirective since it is the correct name.
- runtime/CachedTypes.cpp:
(JSC::CachedSourceProviderShape::encode):
(JSC::CachedFunctionExecutableRareData::encode):
(JSC::CachedFunctionExecutableRareData::decode const): CachedFunctionExecutable did not have
sourceMappingURL to sourceMappingURLDirective. So this patch keeps the same logic.
(JSC::CachedFunctionExecutable::rareData const):
(JSC::CachedFunctionExecutable::encode):
(JSC::CachedFunctionExecutable::decode const):
(JSC::UnlinkedFunctionExecutable::UnlinkedFunctionExecutable):
- runtime/CodeCache.cpp:
(JSC::CodeCache::getUnlinkedGlobalCodeBlock):
(JSC::CodeCache::getUnlinkedGlobalFunctionExecutable):
- runtime/CodeCache.h:
(JSC::generateUnlinkedCodeBlockImpl):
- runtime/FunctionExecutable.h:
- runtime/SamplingProfiler.cpp:
(JSC::SamplingProfiler::StackFrame::url):
Feb 15, 2019:
- 11:41 PM Changeset in webkit [241644] by
-
- 4 edits in trunk/Source/JavaScriptCore
[JSC] Remove unused global private variables
https://bugs.webkit.org/show_bug.cgi?id=194741
Reviewed by Joseph Pecoraro.
There are some private functions and constants that are no longer referenced from builtin JS code.
This patch cleans up them.
- builtins/BuiltinNames.h:
- builtins/ObjectConstructor.js:
(entries):
- runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
- 10:41 PM Changeset in webkit [241643] by
-
- 3 edits in trunk/Source/WebInspectorUI
Web Inspector: Logging a native function to the console, such as
alert
, produces unhandled rejection
https://bugs.webkit.org/show_bug.cgi?id=194740
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-15
Reviewed by Matt Baker.
- UserInterface/Protocol/RemoteObject.js:
(WI.RemoteObject.prototype.findFunctionSourceCodeLocation):
In case of a protocol error (common when attempting to get a location
for a native function) produce the NoSourceFound result.
- UserInterface/Views/ConsoleMessageView.js:
(WI.ConsoleMessageView.prototype._appendLocationLink):
Simplify with an arrow function.
- 9:29 PM Changeset in webkit [241642] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: Some timelines views work, show Legacy CPU timeline
https://bugs.webkit.org/show_bug.cgi?id=194738
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-15
Reviewed by Yusuke Suzuki.
- UserInterface/Views/ContentView.js:
(WI.ContentView.createFromRepresentedObject):
- 8:57 PM Changeset in webkit [241641] by
-
- 2 edits in trunk/Source/WebKit
NetworkDataTask should check its client before calling shouldCaptureExtraNetworkLoadMetrics
https://bugs.webkit.org/show_bug.cgi?id=194732
Reviewed by Geoffrey Garen.
NetworkDataTask may be kept alive if refing it after its NetworkLoad is gone.
This might happen for instance in DownloadManager or when checking for TLS certificates.
In that case, if the NetworkLoad gets destroyed, it clears the client of the NetworkDataTask.
To ensure that NetworkDataTask does not try to use its client, add a null check.
- NetworkProcess/NetworkDataTask.cpp:
(WebKit::NetworkDataTask::shouldCaptureExtraNetworkLoadMetrics const):
- 8:32 PM Changeset in webkit [241640] by
-
- 7 edits in trunk/Source/JavaScriptCore
[JSC] Lazily create empty RegExp
https://bugs.webkit.org/show_bug.cgi?id=194735
Reviewed by Keith Miller.
Some scripts do not have any RegExp. In that case, allocating MarkedBlock for RegExp is costly.
Previously, there was always one RegExp, "empty RegExp". This patch lazily creates it and drop
one MarkedBlock.
- runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
- runtime/RegExpCache.cpp:
(JSC::RegExpCache::ensureEmptyRegExpSlow):
(JSC::RegExpCache::initialize): Deleted.
- runtime/RegExpCache.h:
(JSC::RegExpCache::ensureEmptyRegExp):
(JSC::RegExpCache::emptyRegExp const): Deleted.
- runtime/RegExpCachedResult.cpp:
(JSC::RegExpCachedResult::lastResult):
- runtime/RegExpCachedResult.h:
- runtime/VM.cpp:
(JSC::VM::VM):
- 7:51 PM Changeset in webkit [241639] by
-
- 3 edits in trunk/Source/WebInspectorUI
AX: Audit tab should have built-in accessibility tests.
https://bugs.webkit.org/show_bug.cgi?id=194005
<rdar://problem/47657503>
Updated built-in accessibility audits test suite.
Reviewed by Devin Rousso.
- Localizations/en.lproj/localizedStrings.js:
- UserInterface/Controllers/AuditManager.js:
(WI.AuditManager.prototype.addDefaultTestsIfNeeded):
(WI.AuditManager):
(WI.AuditManager.prototype.addDefaultTestsIfNeeded.): Deleted.
- 6:03 PM Changeset in webkit [241638] by
-
- 4 edits in trunk/Source/WebInspectorUI
Web Inspector: Dark Mode: commas in CSS selectors are too dim
https://bugs.webkit.org/show_bug.cgi?id=194729
<rdar://problem/48128592>
Reviewed by Matt Baker.
Use
--text-color-tertiary
for both light and dark modes.
- UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
(.spreadsheet-style-declaration-editor):
- UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
(.spreadsheet-css-declaration):
(.spreadsheet-css-declaration .selector > span):
(@media (prefers-color-scheme: dark)):
- UserInterface/Views/Variables.css:
(:root):
- 5:38 PM Changeset in webkit [241637] by
-
- 5 edits in trunk/Source
[JSC] Make builtin objects more lazily initialized under non-JIT mode
https://bugs.webkit.org/show_bug.cgi?id=194727
Reviewed by Saam Barati.
Source/JavaScriptCore:
Boolean, Symbol, and Number constructors and prototypes are initialized eagerly, but this is largely
because concurrent compiler can touch NumberPrototype etc. when traversing object's prototypes. This
means that eager initialization is not necessary under non-JIT mode. While we can investigate all the
accesses to these prototypes from the concurrent compiler threads, this "lazily initialize under non-JIT"
is safe and beneficial to non-JIT mode. This patch lazily initializes them under non-JIT mode, and
drop some @Number references to avoid eager initialization. This removes some object allocations and 1
MarkedBlock allocation just for Symbols.
- runtime/JSGlobalObject.cpp:
(JSC::JSGlobalObject::init):
(JSC::JSGlobalObject::visitChildren):
- runtime/JSGlobalObject.h:
(JSC::JSGlobalObject::numberToStringWatchpoint):
(JSC::JSGlobalObject::booleanPrototype const):
(JSC::JSGlobalObject::numberPrototype const):
(JSC::JSGlobalObject::symbolPrototype const):
(JSC::JSGlobalObject::booleanObjectStructure const):
(JSC::JSGlobalObject::symbolObjectStructure const):
(JSC::JSGlobalObject::numberObjectStructure const):
(JSC::JSGlobalObject::stringObjectStructure const):
Source/WebCore:
- Modules/streams/ReadableByteStreamInternals.js:
(privateInitializeReadableByteStreamController):
(readableByteStreamControllerRespond):
- 5:21 PM Changeset in webkit [241636] by
-
- 2 edits in trunk/Source/WebInspectorUI
Unreviewed, fix intentation.
- UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css:
(.sidebar > .panel.details.css-style .rules):
(.sidebar > .panel.details.css-style > .content > .rules .section-header):
- 5:18 PM Changeset in webkit [241635] by
-
- 5 edits1 copy in trunk/Source/WebKit
[PSON] Allow tweaking WebProcess cache parameters via user defaults
https://bugs.webkit.org/show_bug.cgi?id=194731
<rdar://problem/48125377>
Reviewed by Geoffrey Garen.
Allow tweaking WebProcess cache parameters via user defaults like so:
$ defaults write com.apple.Safari WebProcessCacheCachedProcessLifetimeInSeconds 120
-> Cached processes will be evicted after 2 minutes (instead of 30)
$ defaults write com.apple.Safari WebProcessCacheClearingDelayAfterApplicationResignsActiveInSeconds 60
-> Web process cache will be cleared if Safari is no longer active for 1 minutes (instead of 5).
- SourcesCocoa.txt:
- UIProcess/Cocoa/WebProcessCacheCocoa.mm: Copied from Source/WebKit/UIProcess/WebProcessCache.h.
(WebKit::WebProcessCache::platformInitialize):
- UIProcess/WebProcessCache.cpp:
(WebKit::WebProcessCache::WebProcessCache):
(WebKit::WebProcessCache::platformInitialize):
- UIProcess/WebProcessCache.h:
- WebKit.xcodeproj/project.pbxproj:
- 5:13 PM Changeset in webkit [241634] by
-
- 3 edits1 add in trunk
RELEASE_ASSERT at com.apple.JavaScriptCore: JSC::jsSubstringOfResolved
https://bugs.webkit.org/show_bug.cgi?id=194558
Reviewed by Saam Barati.
JSTests:
New regression test.
- stress/regexp-unicode-within-string.js: Added.
Source/JavaScriptCore:
Added an in bounds check before the read of the next character for Unicode regular expressions
for pattern generation that didn't already have such checks.
- yarr/YarrJIT.cpp:
(JSC::Yarr::YarrGenerator::generatePatternCharacterOnce):
(JSC::Yarr::YarrGenerator::generatePatternCharacterFixed):
(JSC::Yarr::YarrGenerator::generateCharacterClassOnce):
(JSC::Yarr::YarrGenerator::generateCharacterClassFixed):
- 4:52 PM Changeset in webkit [241633] by
-
- 15 edits2 adds in trunk
Allow emulation of user gestures from Web Inspector console
https://bugs.webkit.org/show_bug.cgi?id=194725
<rdar://problem/48126604>
Reviewed by Joseph Pecoraro and Devin Rousso.
Source/JavaScriptCore:
- inspector/agents/InspectorRuntimeAgent.cpp: Add a new optional parameter, emulateUserGesture,
to the evaluate function, and mark the function as override so that PageRuntimeAgent
can change the behaviour.
(Inspector::InspectorRuntimeAgent::evaluate):
- inspector/agents/InspectorRuntimeAgent.h:
- inspector/protocol/Runtime.json:
Source/WebCore:
Test: inspector/runtime/evaluate-userGestureEmulation.html
- inspector/agents/page/PageRuntimeAgent.cpp: Override the emulate method and create
a UserGestureIndicator based on the emulateUserGesture option.
(WebCore::PageRuntimeAgent::evaluate):
- inspector/agents/page/PageRuntimeAgent.h:
Source/WebInspectorUI:
Add some UI for emulating a User Gesture when evaluating in the console. This
allows the developer to do things that would otherwise require actual interaction
with the page, such as start playback of media on iOS.
- Localizations/en.lproj/localizedStrings.js:
- UserInterface/Base/Setting.js: Add a new setting for this option.
- UserInterface/Controllers/JavaScriptLogViewController.js:
(WI.JavaScriptLogViewController.prototype.consolePromptTextCommitted):
- UserInterface/Controllers/RuntimeManager.js: Call evaluate with this new option.
(WI.RuntimeManager.prototype.evaluateInInspectedWindow):
- UserInterface/Views/LogContentView.js: Add a new checkbox in the upper bar
that allows the user to toggle the setting.
(WI.LogContentView):
(WI.LogContentView.prototype.get navigationItems):
(WI.LogContentView.prototype._handleEmulateInUserGestureSettingChanged):
- UserInterface/Views/NetworkTableContentView.js: Two drive-by typo fixes :)
(WI.NetworkTableContentView): perserve -> preserve
(WI.NetworkTableContentView.prototype.get navigationItems): checkboxs -> checkboxes
LayoutTests:
- inspector/runtime/evaluate-userGestureEmulation-expected.txt: Added.
- inspector/runtime/evaluate-userGestureEmulation.html: Added.
- 4:36 PM Changeset in webkit [241632] by
-
- 2 edits in trunk/Source/WebCore
Sample domainsVisited diagnostic logging
https://bugs.webkit.org/show_bug.cgi?id=194657
Reviewed by Ryosuke Niwa.
Sample domainsVisited diagnostic logging, we are getting a lot of data from
this key and this is hurting our other keys.
- page/Page.cpp:
(WebCore::Page::logNavigation):
- 4:35 PM Changeset in webkit [241631] by
-
- 2 edits in trunk/Source/WebKit
[PSON] Disable WebContent process cache on devices with less than 3GB of RAM
https://bugs.webkit.org/show_bug.cgi?id=194726
<rdar://problem/48126255>
Reviewed by Geoffrey Garen.
- UIProcess/WebProcessCache.cpp:
(WebKit::WebProcessCache::updateCapacity):
- 4:18 PM Changeset in webkit [241630] by
-
- 3 edits in trunk/Source/JavaScriptCore
[JSC] Do not initialize Wasm related data if Wasm is not enabled
https://bugs.webkit.org/show_bug.cgi?id=194728
Reviewed by Mark Lam.
Under non-JIT mode, these data structures are unnecessary. Should not allocate extra memory for that.
- runtime/InitializeThreading.cpp:
(JSC::initializeThreading):
- runtime/JSLock.cpp:
(JSC::JSLock::didAcquireLock):
- 4:17 PM Changeset in webkit [241629] by
-
- 7 edits in tags/Safari-608.1.6.2/Source
Versioning.
- 4:06 PM Changeset in webkit [241628] by
-
- 1 copy in tags/Safari-608.1.6.2
New tag.
- 3:59 PM Changeset in webkit [241627] by
-
- 7 edits in branches/safari-608.1.5.1-branch/Source
Versioning.
- 3:49 PM Changeset in webkit [241626] by
-
- 4 edits2 adds in trunk
Crash in the hit testing code via HTMLPlugInElement::isReplacementObscured()
https://bugs.webkit.org/show_bug.cgi?id=194691
Reviewed by Simon Fraser.
Source/WebCore:
The crash was caused by HTMLPlugInElement::isReplacementObscured updating the document
without updating the layout of ancestor documents (i.e. documents in which frame owner
elements appear) even though it hit-tests against the top-level document's RenderView.
Fixed the bug by updating the layout of the top-level document as needed.
Test: plugins/unsupported-plugin-with-replacement-in-iframe-crash.html
- html/HTMLPlugInElement.cpp:
(WebCore::HTMLPlugInElement::isReplacementObscured):
LayoutTests:
Added a regression test. It hits the newly added debug assertion without the fix.
- platform/mac-wk1/TestExpectations: Skip the test since DumpRenderTree doesn't support
testRunner.setPluginSupportedMode.
- plugins/unsupported-plugin-with-replacement-in-iframe-crash-expected.txt: Added.
- plugins/unsupported-plugin-with-replacement-in-iframe-crash.html: Added.
- 3:47 PM Changeset in webkit [241625] by
-
- 1 copy in tags/Safari-608.1.5.1.3
Tag Safari-608.1.5.1.3.
- 3:45 PM Changeset in webkit [241624] by
-
- 2 edits in trunk/Source/WebKit
[iOS] Stop setting a background color on the PDF host view
https://bugs.webkit.org/show_bug.cgi?id=194722
<rdar://48124152>
Reviewed by Wenson Hsieh.
PDFKit already sets a background color on this view, so there’s no need (and some harm) in
us doing it too.
- UIProcess/ios/WKPDFView.mm:
(-[WKPDFView web_setContentProviderData:suggestedFilename:]):
- 3:44 PM Changeset in webkit [241623] by
-
- 3 edits2 adds in trunk
Web Inspector: Styles: valid values in style attributes are reported as unsupported property values
https://bugs.webkit.org/show_bug.cgi?id=194619
<rdar://problem/47917373>
Source/WebInspectorUI:
Reviewed by Devin Rousso.
Payload of inline styles may contain
range
that doesn't match
the actual text of the payload - it has an extra empty line at the end.
Mismatching ranges caused data corruption.
- UserInterface/Models/DOMNodeStyles.js:
(WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
LayoutTests:
Reviewed by Devin Rousso and Joseph Pecoraro.
- inspector/css/modify-inline-style-expected.txt: Added.
- inspector/css/modify-inline-style.html: Added.
- 3:39 PM Changeset in webkit [241622] by
-
- 4 edits in trunk/Source/WebKit
Update IPC code generator unit test expectations after r241611
https://bugs.webkit.org/show_bug.cgi?id=194678
- Scripts/webkit/LegacyMessages-expected.h:
- Scripts/webkit/Messages-expected.h:
- Scripts/webkit/MessagesSuperclass-expected.h:
- 3:37 PM Changeset in webkit [241621] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: remove unused parameter in _parseStylePropertyPayload
https://bugs.webkit.org/show_bug.cgi?id=194642
Reviewed by Devin Rousso.
- UserInterface/Models/DOMNodeStyles.js:
(WI.DOMNodeStyles.prototype._parseStyleDeclarationPayload):
ThestyleText
parameter was never used
- 2:47 PM Changeset in webkit [241620] by
-
- 81 edits3 adds in trunk
[WTF] Add environment variable helpers
https://bugs.webkit.org/show_bug.cgi?id=192405
Reviewed by Michael Catanzaro.
Source/JavaScriptCore:
- inspector/remote/glib/RemoteInspectorGlib.cpp:
(Inspector::RemoteInspector::RemoteInspector):
(Inspector::RemoteInspector::start):
- jsc.cpp:
(startTimeoutThreadIfNeeded):
- runtime/Options.cpp:
(JSC::overrideOptionWithHeuristic):
(JSC::Options::overrideAliasedOptionWithHeuristic):
(JSC::Options::initialize):
- runtime/VM.cpp:
(JSC::enableAssembler):
(JSC::VM::VM):
- tools/CodeProfiling.cpp:
(JSC::CodeProfiling::notifyAllocator):
Utilize WTF::Environment where possible.
Source/WebCore:
- platform/NotImplemented.h:
- platform/cocoa/SystemVersion.mm:
(WebCore::createSystemMarketingVersion):
- platform/graphics/gstreamer/GStreamerCommon.cpp:
(WebCore::initializeGStreamer):
- platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
- platform/graphics/nicosia/NicosiaPaintingEngine.cpp:
(Nicosia::PaintingEngine::create):
- platform/graphics/texmap/TextureMapperFPSCounter.cpp:
(WebCore::TextureMapperFPSCounter::TextureMapperFPSCounter):
- platform/graphics/x11/PlatformDisplayX11.cpp:
(WebCore::PlatformDisplayX11::create):
- platform/gtk/RenderThemeWidget.cpp:
(WebCore::RenderThemeScrollbar::RenderThemeScrollbar):
- platform/gtk/ScrollbarThemeGtk.cpp:
(WebCore::ScrollbarThemeGtk::ScrollbarThemeGtk):
- platform/network/curl/CurlContext.cpp:
(WebCore::CurlContext::CurlContext):
(WebCore::EnvironmentVariableReader::read): Deleted.
(WebCore::EnvironmentVariableReader::defined): Deleted.
(WebCore::EnvironmentVariableReader::readAs): Deleted.
(WebCore::EnvironmentVariableReader::sscanTemplate): Deleted.
(WebCore::EnvironmentVariableReader::sscanTemplate<signed>): Deleted.
(WebCore::EnvironmentVariableReader::sscanTemplate<unsigned>): Deleted.
- platform/network/curl/NetworkStorageSessionCurl.cpp:
(WebCore::defaultCookieJarPath):
- platform/network/playstation/CurlSSLHandlePlayStation.cpp:
(WebCore::getCACertPathEnv):
- platform/network/win/CurlSSLHandleWin.cpp:
(WebCore::getCACertPathEnv):
- platform/text/hyphen/HyphenationLibHyphen.cpp:
(WebCore::topLevelPath):
(WebCore::webkitBuildDirectory):
- platform/unix/LoggingUnix.cpp:
(WebCore::logLevelString):
- platform/win/LoggingWin.cpp:
(WebCore::logLevelString):
Utilize WTF::Environment where possible.
Source/WebCore/PAL:
- pal/unix/LoggingUnix.cpp:
(PAL::logLevelString):
- pal/win/LoggingWin.cpp:
(PAL::logLevelString):
Utilize WTF::Environment where possible.
Source/WebKit:
- NetworkProcess/EntryPoint/unix/NetworkProcessMain.cpp:
(main):
- Platform/unix/LoggingUnix.cpp:
(WebKit::logLevelString):
- Platform/win/LoggingWin.cpp:
(WebKit::logLevelString):
- PluginProcess/mac/PluginProcessMac.mm:
(WebKit::shouldCallRealDebugger):
- Shared/Plugins/unix/PluginSearchPath.cpp:
(WebKit::pluginsDirectories):
- Shared/glib/ProcessExecutablePathGLib.cpp:
(WebKit::findWebKitProcess):
- UIProcess/API/glib/WebKitSettings.cpp:
(webKitSettingsConstructed):
(webKitSettingsSetProperty):
- UIProcess/API/glib/WebKitWebContext.cpp:
(injectedBundleDirectory):
(webkitWebContextConstructed):
- UIProcess/API/gtk/WebKitWebViewGtk.cpp:
(webkitWebViewMaximizeWindow):
(webkitWebViewRestoreWindow):
- UIProcess/API/wpe/WPEView.cpp:
(WKWPE::m_backend):
- UIProcess/AuxiliaryProcessProxy.cpp:
(WebKit::AuxiliaryProcessProxy::getLaunchOptions):
- UIProcess/Launcher/glib/BubblewrapLauncher.cpp:
(WebKit::XDGDBusProxyLauncher::launch):
(WebKit::bindDBusSession):
(WebKit::bindX11):
(WebKit::bindWayland):
(WebKit::bindPulse):
(WebKit::bindPathVar):
(WebKit::bindGStreamerData):
(WebKit::bubblewrapSpawn):
- UIProcess/Launcher/glib/ProcessLauncherGLib.cpp:
(WebKit::ProcessLauncher::launchProcess):
- UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::systemDirectoryPath):
(WebKit::ProcessLauncher::launchProcess):
- UIProcess/glib/WebProcessPoolGLib.cpp:
(WebKit::memoryPressureMonitorDisabled):
(WebKit::WebProcessPool::platformInitialize):
(WebKit::WebProcessPool::platformInitializeWebProcess):
- UIProcess/gtk/HardwareAccelerationManager.cpp:
(WebKit::HardwareAccelerationManager::HardwareAccelerationManager):
- WebProcess/EntryPoint/unix/WebProcessMain.cpp:
(main):
- WebProcess/gtk/WebProcessMainGtk.cpp:
- WebProcess/wpe/WebProcessMainWPE.cpp:
Utilize WTF::Environment where possible.
Source/WebKitLegacy/ios:
- Misc/WebUIKitSupport.mm:
(WebKitPlatformSystemRootDirectory):
Utilize WTF::Environment where possible.
Source/WebKitLegacy/mac:
- WebView/WebView.mm:
(-[WebView _initWithFrame:frameName:groupName:]):
Utilize WTF::Environment where possible.
Source/WTF:
Create a new Environment API as a platform-independent, thread-safe(r)
way to get and set environment variables.
- WTF.xcodeproj/project.pbxproj:
- wtf/CMakeLists.txt:
- wtf/Environment.h: Added.
- wtf/PlatformGTK.cmake:
- wtf/PlatformJSCOnly.cmake:
- wtf/PlatformMac.cmake:
- wtf/PlatformPlayStation.cmake:
- wtf/PlatformWPE.cmake:
- wtf/PlatformWin.cmake:
- wtf/posix/EnvironmentPOSIX.cpp: Added.
- wtf/win/EnvironmentWin.cpp: Added.
Introduce WTF::Environment.
- wtf/Threading.cpp:
(WTF::threadingIsInitialized):
(WTF::initializeThreading):
- wtf/Threading.h:
Introduce WTF::threadingIsInitialized() so that we can ASSERT that it's
false before setting an environment variable through the new API.
- wtf/DataLog.cpp:
(WTF::initializeLogFileOnce):
- wtf/NumberOfCores.cpp:
(WTF::numberOfProcessorCores):
- wtf/posix/FileSystemPOSIX.cpp:
(WTF::FileSystemImpl::openTemporaryFile):
Utilize WTF::Environment where possible.
Tools:
- DumpRenderTree/mac/DumpRenderTree.mm:
(libraryPathForDumpRenderTree):
- DumpRenderTree/win/DumpRenderTree.cpp:
(libraryPathForDumpRenderTree):
- TestRunnerShared/IOSLayoutTestCommunication.cpp:
(setUpIOSLayoutTestCommunication):
- TestWebKitAPI/Tests/WebKitGLib/TestAutomationSession.cpp:
(beforeAll):
- TestWebKitAPI/glib/WebKitGLib/TestMain.cpp:
(main):
- TestWebKitAPI/glib/WebKitGLib/WebKitTestBus.cpp:
(WebKitTestBus::run):
- WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
(WTR::getOutputDir):
(WTR::initializeFontConfigSetting):
- WebKitTestRunner/InjectedBundle/gtk/InjectedBundleGtk.cpp:
(WTR::InjectedBundle::platformInitialize):
- WebKitTestRunner/InjectedBundle/gtk/InjectedBundleUtilities.cpp:
(WTR::topLevelPath):
- WebKitTestRunner/InjectedBundle/wpe/ActivateFontsWPE.cpp:
(WTR::topLevelPath):
(WTR::getOutputDir):
(WTR::activateFonts):
- WebKitTestRunner/TestController.cpp:
(WTR::TestController::libraryPathForTesting):
(WTR::TestController::generateContextConfiguration const):
(WTR::TestController::generatePageConfiguration):
(WTR::TestController::decideDestinationWithSuggestedFilename):
(WTR::TestController::platformAdjustContext):
- WebKitTestRunner/TestController.h:
- WebKitTestRunner/cocoa/TestControllerCocoa.mm:
(WTR::TestController::cocoaPlatformInitialize):
(WTR::TestController::platformAdjustContext):
- WebKitTestRunner/gtk/main.cpp:
(main):
- WebKitTestRunner/mac/TestControllerMac.mm:
(WTR::TestController::configureContentExtensionForTest):
- WebKitTestRunner/wpe/main.cpp:
(main):
Utilize WTF::Environment where possible.
- 2:25 PM Changeset in webkit [241619] by
-
- 7 edits in branches/safari-607-branch/Source
Versioning.
- 2:19 PM Changeset in webkit [241618] by
-
- 3 edits in trunk/Source/WebKit
Add SPI version of WKPreferences.safeBrowsingEnabled
https://bugs.webkit.org/show_bug.cgi?id=194718
<rdar://problem/48122993>
Rubber-stamped by Brady Eidson.
- UIProcess/API/Cocoa/WKPreferences.mm:
(-[WKPreferences _isSafeBrowsingEnabled]):
(-[WKPreferences _setSafeBrowsingEnabled:]):
- UIProcess/API/Cocoa/WKPreferencesPrivate.h:
- 2:18 PM Changeset in webkit [241617] by
-
- 3 edits in trunk/Source/WebCore
Add a method to dispatch a PointerEvent based on a PlatformTouchEvent
https://bugs.webkit.org/show_bug.cgi?id=194702
<rdar://problem/48109355>
Reviewed by Dean Jackson.
- page/EventHandler.cpp:
(WebCore::EventHandler::dispatchPointerEventForTouchAtIndex):
- page/EventHandler.h:
- 2:14 PM Changeset in webkit [241616] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: Canvas: all actions after an offscreen path modification are marked as offscreen path errors
https://bugs.webkit.org/show_bug.cgi?id=194684
Reviewed by Joseph Pecoraro.
- UserInterface/Models/RecordingAction.js:
(WI.RecordingAction.prototype.process):
- 1:41 PM Changeset in webkit [241615] by
-
- 4 edits4 adds in trunk
SamplingProfiler::stackTracesAsJSON() should escape strings.
https://bugs.webkit.org/show_bug.cgi?id=194649
<rdar://problem/48072386>
Reviewed by Saam Barati.
JSTests:
- stress/sampling-profiler-stack-trace-with-double-quote-in-function-name.js: Added.
- stress/type-profiler-with-double-quote-in-constructor-name.js: Added.
- stress/type-profiler-with-double-quote-in-field-name.js: Added.
- stress/type-profiler-with-double-quote-in-optional-field-name.js: Added.
Source/JavaScriptCore:
Ditto for TypeSet::toJSONString() and TypeSet::toJSONString().
- runtime/SamplingProfiler.cpp:
(JSC::SamplingProfiler::stackTracesAsJSON):
- runtime/TypeSet.cpp:
(JSC::TypeSet::toJSONString const):
(JSC::StructureShape::toJSONString const):
- 1:35 PM Changeset in webkit [241614] by
-
- 9 edits in trunk
[iOS] WKWebView callout bar is missing Change Writing Direction item
https://bugs.webkit.org/show_bug.cgi?id=190015
<rdar://problem/44810366>
Reviewed by Tim Horton.
Source/WebKit:
Support -makeTextWritingDirectionLeftToRight: and -makeTextWritingDirectionRightToLeft: in WKWebView on iOS.
To match behavior in native UITextViews on iOS, we implement these methods by changing the *base* writing
direction, rather than the text writing direction (this is in contrast to macOS, which has different
NSResponder methods for changing the base writing direction as opposed to the text writing direction).
Additionally fixes the implementation of -makeTextWritingDirectionNatural:, which currently attempts to change
the text writing direction instead of the base writing direction.
- Platform/spi/ios/UIKitSPI.h:
Add a forward declaration for keyboards SPI to determine whether the user has an active RTL keyboard.
- Shared/EditorState.cpp:
(WebKit::EditorState::PostLayoutData::encode const):
(WebKit::EditorState::PostLayoutData::decode):
(WebKit::operator<<):
- Shared/EditorState.h:
Plumb the base writing direction to the UI process through EditorState.
- UIProcess/ios/WKContentViewInteraction.h:
- UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView makeTextWritingDirectionNaturalForWebView:]):
(-[WKContentView makeTextWritingDirectionLeftToRightForWebView:]):
(-[WKContentView makeTextWritingDirectionRightToLeftForWebView:]):
Implement the new SPI (see above for more details).
(-[WKContentView canPerformActionForWebView:withSender:]):
Implement -canPerformAction: for LTR and RTL actions. To match existing UIWebView behavior, we only enable
these actions if either the base writing direction is RTL, or the user has an active RTL keyboard. This means,
for instance, that in the case where a user with only an English keyboard is editing LTR content, we would never
show an option to convert to RTL.
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::editorState const):
Tools:
Make an existing API test that exercises platform SPI to change the inline text writing direction run only on
macOS, and add a new API test that uses similarly named SPI on iOS to change the base writing direction.
- TestWebKitAPI/Tests/WebKitCocoa/WKWebViewEditActions.mm:
(TestWebKitAPI::TEST):
- 1:34 PM Changeset in webkit [241613] by
-
- 5 edits1 add in trunk
[JSC] CodeBlock::jettison should clear related watchpoints
https://bugs.webkit.org/show_bug.cgi?id=194544
Reviewed by Mark Lam.
- bytecode/CodeBlock.cpp:
(JSC::CodeBlock::jettison):
- dfg/DFGCommonData.h:
(JSC::DFG::CommonData::clearWatchpoints): Added.
- dfg/CommonData.cpp:
(JSC::DFG::CommonData::clearWatchpoints): Added.
- 1:27 PM Changeset in webkit [241612] by
-
- 5 edits in trunk/Source/JavaScriptCore
Move bytecode cache-related filesystem code out of CodeCache
https://bugs.webkit.org/show_bug.cgi?id=194675
Reviewed by Saam Barati.
That code is only used for the bytecode-cache tests, so it should live in
jsc.cpp rather than in the CodeCache.
- jsc.cpp:
(CliSourceProvider::create):
(CliSourceProvider::~CliSourceProvider):
(CliSourceProvider::cachePath const):
(CliSourceProvider::loadBytecode):
(CliSourceProvider::CliSourceProvider):
(jscSource):
(GlobalObject::moduleLoaderFetch):
(functionDollarEvalScript):
(runWithOptions):
- parser/SourceProvider.h:
(JSC::SourceProvider::cacheBytecode const):
- runtime/CodeCache.cpp:
(JSC::writeCodeBlock):
- runtime/CodeCache.h:
(JSC::CodeCacheMap::fetchFromDiskImpl):
- 1:25 PM Changeset in webkit [241611] by
-
- 7 edits in trunk/Source/WebKit
Make WebPaymentCoordinatorProxy more robust and modern
https://bugs.webkit.org/show_bug.cgi?id=194678
Reviewed by Andy Estes.
Use WeakPtr instead of storing raw pointers in lambdas or the global activePaymentCoordinatorProxy to avoid UAF problems.
Call CompletionHandlers in all code paths to avoid hangs.
Use Delayed instead of LegacySync for synchronous messaging to progress towards removing LegacySync messages.
- Scripts/webkit/messages.py:
- UIProcess/ApplePay/WebPaymentCoordinatorProxy.cpp:
(WebKit::activePaymentCoordinatorProxy):
(WebKit::WebPaymentCoordinatorProxy::~WebPaymentCoordinatorProxy):
(WebKit::WebPaymentCoordinatorProxy::availablePaymentNetworks):
(WebKit::WebPaymentCoordinatorProxy::canMakePayments):
(WebKit::WebPaymentCoordinatorProxy::showPaymentUI):
(WebKit::WebPaymentCoordinatorProxy::didReachFinalState):
- UIProcess/ApplePay/WebPaymentCoordinatorProxy.h:
- UIProcess/ApplePay/WebPaymentCoordinatorProxy.messages.in:
- UIProcess/ApplePay/ios/WebPaymentCoordinatorProxyIOS.mm:
(WebKit::WebPaymentCoordinatorProxy::platformShowPaymentUI):
- UIProcess/ApplePay/mac/WebPaymentCoordinatorProxyMac.mm:
(WebKit::WebPaymentCoordinatorProxy::platformShowPaymentUI):
- 1:21 PM Changeset in webkit [241610] by
-
- 3 edits in trunk/Source/JavaScriptCore
[JSC] DFG, FTL, and Wasm worklist creation should be fenced
https://bugs.webkit.org/show_bug.cgi?id=194714
Reviewed by Mark Lam.
Let's consider about the following extreme case.
- VM (A) is created.
- Another VM (B) is created on a different thread.
- (A) is being destroyed. It calls DFG::existingWorklistForIndexOrNull in a destructor.
- At the same time, (B) starts using DFG Worklist and it is instantiated in call_once.
- But (A) reads the pointer directly through DFG::existingWorklistForIndexOrNull.
- (A) sees the half-baked worklist, which may be in the middle of creation.
This patch puts store-store fence just before putting a pointer to a global variable.
This fence is executed only three times at most, for DFG, FTL, and Wasm worklist initializations.
- dfg/DFGWorklist.cpp:
(JSC::DFG::ensureGlobalDFGWorklist):
(JSC::DFG::ensureGlobalFTLWorklist):
- wasm/WasmWorklist.cpp:
(JSC::Wasm::ensureWorklist):
- 1:18 PM Changeset in webkit [241609] by
-
- 2 edits in trunk/Source/WebKit
Make ServiceWorkerClientFetch closer to WebResourceLoader
https://bugs.webkit.org/show_bug.cgi?id=194651
Unreviewed, build fix for WPE.
- WebProcess/Storage/WebServiceWorkerFetchTaskClient.h:
- 1:13 PM Changeset in webkit [241608] by
-
- 4 edits in trunk
[WebVTT] Inline WebVTT styles should start with '::cue'
https://bugs.webkit.org/show_bug.cgi?id=194227
Reviewed by Eric Carlson.
Source/WebCore:
The original fix in r241203 is not sufficient, since it only checks if the CSS string starts
with '::cue'. Before accepting a CSS string from a WebVTT file, it should be checked that
all selectors starts with '::cue'.
Test: media/track/track-cue-css.html
- html/track/WebVTTParser.cpp:
(WebCore::WebVTTParser::checkAndStoreStyleSheet):
LayoutTests:
Add invalid 'STYLE' blocks which the WebVTT parser should reject.
- media/track/captions-webvtt/css-styling.vtt:
- 1:09 PM Changeset in webkit [241607] by
-
- 3 edits in trunk/Source/WebCore
Add binding tests for ContextAllowsMediaDevices and ContextHasServiceWorkerScheme
https://bugs.webkit.org/show_bug.cgi?id=194713
Reviewed by Eric Carlson.
Binding tests covering mediaDevices and serviceWorker attributes.
- bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::JSTestObjPrototype::finishCreation):
(WebCore::jsTestObjMediaDevices1Getter):
(WebCore::jsTestObjMediaDevices1):
(WebCore::jsTestObjMediaDevices2Getter):
(WebCore::jsTestObjMediaDevices2):
(WebCore::jsTestObjServiceWorkers1Getter):
(WebCore::jsTestObjServiceWorkers1):
(WebCore::jsTestObjServiceWorkers2Getter):
(WebCore::jsTestObjServiceWorkers2):
- bindings/scripts/test/TestObj.idl:
- 1:03 PM Changeset in webkit [241606] by
-
- 4 edits in trunk
Regression(PSON) Navigating quickly back and forth can lead to getting 'about:blank' in the backforward list
https://bugs.webkit.org/show_bug.cgi?id=194717
<rdar://problem/47884404>
Reviewed by Brady Eidson.
Source/WebKit:
When the client does a history navigation, the UIProcess sends a WebPage::GoToBackForwardItem IPC to the
WebProcess and the WebProcess sends a WebPageProxy::BackForwardGoToItem IPC back to the UIProcess to
update the current item in the BackForwardList. This means that there is a slight delay between the
point a client requests a history navigation and the point where the BackForwardList's current item gets
update. This delay is pre-existing behavior and not new to PSON.
However, with PSON enabled, if we decide to process-swap for the history navigation, we'll tell the
previous (committed) process to ignore the load and we ask a new (provisional) process to do the history
navigation. When the previous process receives the request to ignore the history navigation, it restores
the History's current item to the one previous the navigation, which sends a WebPageProxy::GoToBackForwardItem
IPC to the UIProcess to update the BackForwardList as well. In parallel, the new process starts the
history navigation and also sends a WebPageProxy::GoToBackForwardItem to update the BackForwardList's
current item as well. We end up with a race between the 2 GoToBackForwardItem IPC messages coming from
the old and new process. If the old process's message loses the race, we end up with the wrong current
history item getting set in the UIProcess. Later, when we commit the provisional load and try to suspend
the previous page, we would save the SuspendedPage on the *wrong* BackForwardList item. If one tries to
load this BackForwardList item later, we'll use its SuspendedPage and try to unsuspend it. However,
because the PageCache entry is saved on another HistoryItem than the one getting loaded in the WebProcess
side, we attempt to do a regular load instead of a PageCache restore. We end up failing the load because
pages cannot trigger new loads while in page cache. Because the load fails, we end up loading the
initial empty document and this is how we end up with 'about:blank' in the back forward list.
To address the issue, update WebPageProxy::backForwardGoToItem() to ignore messages from the old/committed
WebProcess when there is a pending provisional load. If the committed processes starts a legit new
load, it would clear any existing pending provisional load before attempting the call backForwardGoToItem().
As a result, ignoring such messages from the old processes when there is a pending provisional load is
safe.
In the future, we should probably move more of the history / backForwardList management to the UIProcess
to avoid this sort of issues. This would be a much larger refactoring though so I am going with this
simpler fix that is easily cherry-pickable for now.
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::suspendCurrentPageIfPossible):
(WebKit::WebPageProxy::continueNavigationInNewProcess):
(WebKit::WebPageProxy::backForwardGoToItem):
Tools:
Add API test coverage.
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
- 1:00 PM Changeset in webkit [241605] by
-
- 2 edits in trunk/Source/WebCore
Build fix.
- rendering/RenderThemeIOS.mm:
(WebCore::iconForAttachment):
- 12:55 PM Changeset in webkit [241604] by
-
- 3 edits in trunk/Source/WebKit
Update IPC code generator unit test expectations after r241595
https://bugs.webkit.org/show_bug.cgi?id=194679
- Scripts/webkit/LegacyMessageReceiver-expected.cpp:
(WebKit::WebPage::didReceiveSyncWebPageMessage):
- Scripts/webkit/MessageReceiver-expected.cpp:
(WebKit::WebPage::didReceiveSyncMessage):
- 12:25 PM Changeset in webkit [241603] by
-
- 24 edits in trunk/Source
Make ServiceWorkerClientFetch closer to WebResourceLoader
https://bugs.webkit.org/show_bug.cgi?id=194651
Reviewed by Alex Christensen.
Source/WebCore:
Check for redirection response and if so call a specific client API.
Ensure ServiceWorkerFetch::Client gets called in the service worker thread proxy
so that its m_connection is only accessed on that thread.
Covered by existing tests.
- platform/network/FormData.h:
- platform/network/ResourceErrorBase.h:
- workers/service/context/ServiceWorkerFetch.cpp:
(WebCore::ServiceWorkerFetch::processResponse):
- workers/service/context/ServiceWorkerFetch.h:
- workers/service/context/ServiceWorkerThreadProxy.cpp:
(WebCore::ServiceWorkerThreadProxy::cancelFetch):
(WebCore::ServiceWorkerThreadProxy::continueDidReceiveFetchResponse):
- workers/service/context/ServiceWorkerThreadProxy.h:
Source/WebKit:
The goal of this refactoring is to, at some point use the regular network process load path for service worker loads.
This should simplify things and allow less IPC exchanges, for instance in the case of fetch not handled by service worker.
Introduce two IPC messages for supporting redirect responses and allow the didReceiveResponse/continueDidReceiveResponse
handshake for navigation loads.
This makes ServiceWorker having to buffer load information for this particular case.
- NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::didReceiveFetchRedirectResponse):
(WebKit::NetworkProcess::didReceiveFetchResponse):
- NetworkProcess/NetworkProcess.h:
- NetworkProcess/NetworkProcess.messages.in:
- NetworkProcess/ServiceWorker/WebSWServerConnection.cpp:
(WebKit::WebSWServerConnection::continueDidReceiveFetchResponse):
(WebKit::WebSWServerConnection::didReceiveFetchRedirectResponse):
(WebKit::WebSWServerConnection::didReceiveFetchResponse):
- NetworkProcess/ServiceWorker/WebSWServerConnection.h:
- NetworkProcess/ServiceWorker/WebSWServerConnection.messages.in:
- WebProcess/Storage/ServiceWorkerClientFetch.cpp:
(WebKit::ServiceWorkerClientFetch::start):
(WebKit::ServiceWorkerClientFetch::didReceiveRedirectResponse):
(WebKit::ServiceWorkerClientFetch::didReceiveResponse):
(WebKit::ServiceWorkerClientFetch::didReceiveData):
(WebKit::ServiceWorkerClientFetch::didFinish):
(WebKit::ServiceWorkerClientFetch::didFail):
(WebKit::ServiceWorkerClientFetch::didNotHandle):
(WebKit::ServiceWorkerClientFetch::cancel):
- WebProcess/Storage/ServiceWorkerClientFetch.h:
- WebProcess/Storage/ServiceWorkerClientFetch.messages.in:
- WebProcess/Storage/WebSWClientConnection.cpp:
(WebKit::WebSWClientConnection::startFetch):
(WebKit::WebSWClientConnection::cancelFetch):
(WebKit::WebSWClientConnection::continueDidReceiveFetchResponse):
- WebProcess/Storage/WebSWClientConnection.h:
- WebProcess/Storage/WebSWContextManagerConnection.cpp:
(WebKit::WebSWContextManagerConnection::continueDidReceiveFetchResponse):
(WebKit::WebSWContextManagerConnection::startFetch):
- WebProcess/Storage/WebSWContextManagerConnection.h:
- WebProcess/Storage/WebSWContextManagerConnection.messages.in:
- WebProcess/Storage/WebServiceWorkerFetchTaskClient.cpp:
(WebKit::WebServiceWorkerFetchTaskClient::WebServiceWorkerFetchTaskClient):
(WebKit::WebServiceWorkerFetchTaskClient::didReceiveRedirection):
(WebKit::WebServiceWorkerFetchTaskClient::didReceiveResponse):
(WebKit::WebServiceWorkerFetchTaskClient::didReceiveData):
(WebKit::WebServiceWorkerFetchTaskClient::didReceiveFormDataAndFinish):
(WebKit::WebServiceWorkerFetchTaskClient::didFail):
(WebKit::WebServiceWorkerFetchTaskClient::didFinish):
(WebKit::WebServiceWorkerFetchTaskClient::continueDidReceiveResponse):
- WebProcess/Storage/WebServiceWorkerFetchTaskClient.h:
- 11:22 AM Changeset in webkit [241602] by
-
- 8 edits in trunk
Make navigator.mediaDevices SecureContext
https://bugs.webkit.org/show_bug.cgi?id=194666
Reviewed by Eric Carlson.
Source/WebCore:
Make navigator.mediaDevices SecureContext.
This can still be enabled for unsecure context using the existing page settings.
To cover that case, introduce ContextHasMediaDevices custom IDL keyword.
Covered by API test.
- Modules/mediastream/NavigatorMediaDevices.idl:
- bindings/scripts/CodeGeneratorJS.pm:
(GenerateRuntimeEnableConditionalString):
- bindings/scripts/IDLAttributes.json:
- dom/ScriptExecutionContext.cpp:
(WebCore::ScriptExecutionContext::hasMediaDevices const):
(WebCore::ScriptExecutionContext::hasServiceWorkerScheme const):
- dom/ScriptExecutionContext.h:
Tools:
- TestWebKitAPI/Tests/WebKitCocoa/UserMediaDisabled.mm:
(MediaCaptureDisabledTest::loadTestAndWaitForMessage):
(TEST_F):
- 11:12 AM Changeset in webkit [241601] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: Canvas: taking a second recording doesn't select the Initial State by default
https://bugs.webkit.org/show_bug.cgi?id=194685
Reviewed by Matt Baker.
- UserInterface/Views/CanvasSidebarPanel.js:
(WI.CanvasSidebarPanel.prototype._recordingChanged):
- 11:09 AM Changeset in webkit [241600] by
-
- 2 edits in trunk/LayoutTests
Layout Test accessibility/loading-iframe-sends-notification.html is timing out
https://bugs.webkit.org/show_bug.cgi?id=194712
Unreviewed test gardening.
- platform/win/TestExpectations:
- 11:08 AM Changeset in webkit [241599] by
-
- 3 edits in trunk/Source/WebCore
WebSocket should not fire events after being stopped
https://bugs.webkit.org/show_bug.cgi?id=194690
Reviewed by Geoffrey Garen.
dispatchOrQueueErrorEvent is scheduled using RunLoop::main().dispatch or dispatch_async.
This makes it possible to dispatch an event while WebSocket is already stopped.
Instead, use Document::postTask so that the task is only executed if WebSocket is not stopped.
As a refactoring, make use of PendingActivity to keep track of setPendingActivity/unsetPendingActivity more easily.
- Modules/websockets/WebSocket.cpp:
(WebCore::WebSocket::stop):
(WebCore::WebSocket::connect):
- Modules/websockets/WebSocket.h:
- 11:06 AM Changeset in webkit [241598] by
-
- 2 edits in trunk/Source/WebCore
Performance should not fire events when its context is stopped
https://bugs.webkit.org/show_bug.cgi?id=194689
Reviewed by Alex Christensen.
Stop the timer when its context is destroyed.
Add an assertion to ensure the timer does not fire after context is destroyed.
- page/Performance.cpp:
(WebCore::Performance::stop):
- 11:01 AM Changeset in webkit [241597] by
-
- 12 edits in trunk
[Mac] WebInspectorUI.framework does not need to be soft-linked anymore
https://bugs.webkit.org/show_bug.cgi?id=194411
<rdar://problem/47787614>
Reviewed by Joseph Pecoraro.
Source/WebKit:
- Configurations/WebKit.xcconfig:
Conditionalize weak linking to WebInspectorUI.framework for Mac only.
- UIProcess/mac/WebInspectorProxyMac.mm:
(WebKit::WebInspectorProxy::inspectorPageURL):
(WebKit::WebInspectorProxy::inspectorTestPageURL):
(WebKit::WebInspectorProxy::inspectorBaseURL):
- WebProcess/WebPage/mac/WebInspectorUIMac.mm:
(WebKit::webInspectorUILocalizedStringsURL):
Rewrite uses of the bundle to exit early if bundle couldn't be loaded.
Source/WebKitLegacy/mac:
- Configurations/WebKitLegacy.xcconfig:
Conditionalize weak linking to WebInspectorUI.framework for Mac only.
- WebCoreSupport/WebInspectorClient.mm:
(WebInspectorFrontendClient::localizedStringsURL):
(-[WebInspectorWindowController inspectorPagePath]):
(-[WebInspectorWindowController inspectorTestPagePath]):
Rewrite uses of the bundle to exit early if bundle couldn't be loaded.
Source/WTF:
- wtf/cocoa/SoftLinking.h:
Remove macro that now has no uses.
Tools:
Remove unnecessary soft linking macro usage.
- DumpRenderTree/mac/TestRunnerMac.mm:
(TestRunner::inspectorTestStubURL):
(SOFT_LINK_STAGED_FRAMEWORK): Deleted.
- WebKitTestRunner/InjectedBundle/mac/TestRunnerMac.mm:
(WTR::TestRunner::inspectorTestStubURL):
- 11:01 AM Changeset in webkit [241596] by
-
- 2 edits in trunk/LayoutTests
Layout Test fast/replaced/encrypted-pdf-as-object-and-embed.html is failing
https://bugs.webkit.org/show_bug.cgi?id=194711
Unreviewed test gardening.
- platform/win/TestExpectations:
- 10:53 AM Changeset in webkit [241595] by
-
- 6 edits in trunk/Source/WebKit
IPC code should support messages with both Delayed and WantsConnection attributes
https://bugs.webkit.org/show_bug.cgi?id=194679
Reviewed by Geoffrey Garen.
- Platform/IPC/HandleMessage.h:
(IPC::callMemberFunctionImpl):
(IPC::callMemberFunction):
(IPC::handleMessageDelayedWantsConnection):
- Scripts/webkit/messages.py:
- UIProcess/WebStorage/StorageManager.cpp:
(WebKit::StorageManager::getValues):
- UIProcess/WebStorage/StorageManager.h:
- UIProcess/WebStorage/StorageManager.messages.in:
- 10:51 AM Changeset in webkit [241594] by
-
- 2 edits in trunk/Source/WebCore
REGRESSION: ( r240978-r240985 ) [ iOS Release ] Layout Test imported/w3c/web-platform-tests/xhr/send-redirect-post-upload.htm is crashing
https://bugs.webkit.org/show_bug.cgi?id=194523
Reviewed by Geoffrey Garen.
The scope of the FormCreationContext was limited to the scope of createHTTPBodyCFReadStream,
so when it was used in formCreate it was lucky to get the same context if the stack hadn't been overwritten
and if the FormData hadn't been freed. Instead, keep it alive with new/delete like we do the FormStreamFields.
A younger me should've noticed this when reviewing r218517.
- platform/network/cf/FormDataStreamCFNet.cpp:
(WebCore::formCreate):
(WebCore::createHTTPBodyCFReadStream):
- 10:26 AM Changeset in webkit [241593] by
-
- 83 edits3 deletes in trunk
Unreviewed, rolling out r241559 and r241566.
https://bugs.webkit.org/show_bug.cgi?id=194710
Causes layout test crashes under GuardMalloc (Requested by
ryanhaddad on #webkit).
Reverted changesets:
"[WTF] Add environment variable helpers"
https://bugs.webkit.org/show_bug.cgi?id=192405
https://trac.webkit.org/changeset/241559
"Unreviewed build fix for WinCairo Debug after r241559."
https://trac.webkit.org/changeset/241566
- 10:25 AM Changeset in webkit [241592] by
-
- 2 edits in trunk/Source/WebCore
Stop the endpoint synchronously in RTCPeerConnection::close
https://bugs.webkit.org/show_bug.cgi?id=194688
Reviewed by Eric Carlson.
In the case where the peer connection is being closed, it was asynchronously stopping the endpoint.
But the endpoint, before being stopped, could try to fire an event.
If the context is gone in between, we end up with a null pointer dereference.
- Modules/mediastream/RTCPeerConnection.cpp:
(WebCore::RTCPeerConnection::close):
- 10:04 AM Changeset in webkit [241591] by
-
- 5 edits2 adds in trunk
[LFC] Out-of-flow box is never a float box
https://bugs.webkit.org/show_bug.cgi?id=194704
Reviewed by Antti Koivisto.
Source/WebCore:
We can't have it both ways. Absolute positioning wins.
Test: fast/block/block-only/out-of-flow-is-never-float-box.html
- layout/layouttree/LayoutBox.cpp:
(WebCore::Layout::Box::isFloatingPositioned const):
(WebCore::Layout::Box::isLeftFloatingPositioned const):
(WebCore::Layout::Box::isRightFloatingPositioned const):
Tools:
- LayoutReloaded/misc/LFC-passing-tests.txt:
LayoutTests:
- fast/block/block-only/out-of-flow-is-never-float-box-expected.html: Added.
- fast/block/block-only/out-of-flow-is-never-float-box.html: Added.
- 9:26 AM Changeset in webkit [241590] by
-
- 2 edits in trunk/Source/WebCore
[GStreamer] Simplify GObject class name check
https://bugs.webkit.org/show_bug.cgi?id=194537
Patch by Philippe Normand <pnormand@igalia.com> on 2019-02-15
Reviewed by Michael Catanzaro.
- platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::uriDecodeBinElementAddedCallback):
Use G_OBJECT_TYPE_NAME() to filter out uridecodebin child
elements.
- 9:14 AM Changeset in webkit [241589] by
-
- 2 edits in trunk/Source/WebKit
[WPE][GTK] Defer sandboxing APIs to 2.26
https://bugs.webkit.org/show_bug.cgi?id=194274
Reviewed by Carlos Garcia Campos.
The web process sandbox has not been widely-tested yet, so we should defer the new APIs to
2.26.
- UIProcess/API/glib/WebKitWebContext.cpp:
- 8:52 AM Changeset in webkit [241588] by
-
- 4 edits in trunk/Source/WebCore
Refactor EditingStyle::textDirection to return an Optional<WritingDirection> instead of a bool
https://bugs.webkit.org/show_bug.cgi?id=194686
Reviewed by Ryosuke Niwa.
Changes EditingStyle::textDirection to return an Optional<WritingDirection>, instead of taking a reference to
the resulting WritingDirection. No change in behavior.
- editing/ApplyStyleCommand.cpp:
(WebCore::ApplyStyleCommand::splitAncestorsWithUnicodeBidi):
(WebCore::ApplyStyleCommand::applyInlineStyle):
- editing/EditingStyle.cpp:
(WebCore::EditingStyle::textDirection const):
(WebCore::EditingStyle::textDirectionForSelection):
- editing/EditingStyle.h:
- 8:19 AM Changeset in webkit [241587] by
-
- 28 edits in trunk
Replace more uses of String::format with StringConcatenate (mostly non-Apple platform-specific cases)
https://bugs.webkit.org/show_bug.cgi?id=194487
Reviewed by Daniel Bates.
Source/WebCore:
- accessibility/win/AccessibilityObjectWrapperWin.cpp:
(WebCore::AccessibilityObjectWrapper::accessibilityAttributeValue): Use makeString
instead of String::format.
- page/linux/ResourceUsageOverlayLinux.cpp:
(WebCore::formatByteNumber): Use String::number instead of String::format.
- platform/audio/gstreamer/AudioSourceProviderGStreamer.cpp:
(WebCore::AudioSourceProviderGStreamer::AudioSourceProviderGStreamer):
Use makeString instead of String::format.
- platform/glib/UserAgentGLib.cpp:
(WebCore::platformVersionForUAString): Ditto.
- platform/graphics/gstreamer/GStreamerCommon.cpp:
(WebCore::simpleBusMessageCallback): Ditto.
- platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::handleMessage): Ditto.
- platform/graphics/gstreamer/mse/AppendPipeline.cpp:
(WebCore::AppendPipeline::AppendPipeline): Ditto.
(WebCore::AppendPipeline::handleStateChangeMessage): Ditto.
(WebCore::AppendPipeline::resetParserState): Ditto.
- platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
(WebCore::MediaPlayerPrivateGStreamerMSE::load): Ditto.
(WebCore::MediaPlayerPrivateGStreamerMSE::doSeek): Ditto.
- platform/graphics/gtk/ImageBufferGtk.cpp:
(WebCore::encodeImage): Use String::number instead of String::format.
- platform/mediastream/gstreamer/GStreamerAudioCaptureSource.cpp:
(WebCore::GStreamerAudioCaptureSource::create): Use makeString instead of
String::format.
- platform/mediastream/gstreamer/GStreamerCaptureDeviceManager.cpp:
(WebCore::GStreamerCaptureDeviceManager::addDevice): Ditto.
- platform/mediastream/gstreamer/GStreamerMediaStreamSource.cpp:
(WebCore::webkitMediaStreamSrcAddPad): Ditto.
- platform/mediastream/gstreamer/GStreamerVideoCaptureSource.cpp:
(WebCore::GStreamerVideoCaptureSource::create): Ditto.
- platform/network/curl/CookieJarDB.cpp:
(WebCore::CookieJarDB::verifySchemaVersion): Ditto.
- platform/win/SearchPopupMenuDB.cpp:
(WebCore::SearchPopupMenuDB::verifySchemaVersion): Ditto.
Source/WebKit:
- NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::switchToNewTestingSession): Use makeString instead of String::format.
- NetworkProcess/soup/NetworkProcessSoup.cpp:
(WebKit::buildAcceptLanguages): Ditto.
- UIProcess/API/glib/IconDatabase.cpp:
(WebKit::IconDatabase::performURLImport): Ditto.
- UIProcess/gtk/InputMethodFilter.cpp:
(WebKit::InputMethodFilter::logConfirmCompositionForTesting): Ditto.
(WebKit::InputMethodFilter::logSetPreeditForTesting): Ditto.
Source/WebKitLegacy/win:
- WebView.cpp:
(webKitVersionString): Use makeString instead of String::format.
Tools:
- DumpRenderTree/win/DumpRenderTree.cpp:
(applicationId): Use makeString instead of String::format.
(main): Ditto.
- TestWebKitAPI/win/PlatformUtilitiesWin.cpp:
(TestWebKitAPI::Util::createURLForResource): Ditto.
- WebKitTestRunner/InjectedBundle/atk/AccessibilityNotificationHandlerAtk.cpp:
(WTR::AccessibilityNotificationHandler::connectAccessibilityCallbacks): Ditto.
- WebKitTestRunner/InjectedBundle/atk/AccessibilityUIElementAtk.cpp:
(WTR::attributeSetToString): Use StringBuilder functions directly instead of g_strconcat.
(WTR::attributesOfElement): Use StringBuilder functions directly instead of String::format.
(WTR::createStringWithAttributes): Use appendLiteral.
(WTR::AccessibilityUIElement::helpText const): Ditto.
(WTR::AccessibilityUIElement::attributedStringForRange): Use StringBuilder functions
directly instead of using String::format.
(WTR::AccessibilityUIElement::url): Use makeString instead of String::format.
(WTR::stringAtOffset): Use StringBuilder::appendNumber instead of String::format.
- 8:11 AM Changeset in webkit [241586] by
-
- 12 edits in trunk
Unreviewed, rolling out r241564.
Caused 50+ Timeouts on Mac WK2, mostly in the http/ directory
Reverted changeset:
"[Mac] WebInspectorUI.framework does not need to be soft-
linked anymore"
https://bugs.webkit.org/show_bug.cgi?id=194411
https://trac.webkit.org/changeset/241564
- 6:24 AM Changeset in webkit [241585] by
-
- 12 edits6 adds in trunk/Source/WebCore
Decoding media-capabilities configuration initial support https://bugs.webkit.org/show_bug.cgi?id=191191
Reviewed by Xabier Rodriguez-Calvar.
This patch enables basic platform probing for GStreamer decoders,
optionally using Hardware decoding capabilities. The previous code
for decoders/demuxers probing partially duplicated between the MSE
player and its parent class was moved to a new module called
GStreamerRegistryScanner. There is one instance of it for the MSE player
and one for the parent class.
The scanner can check for the presence of the GstElement Hardware
metadata classifier in decoders and thus advise the
MediaEngineConfigurationFactoryGStreamer that hardware decoding is
supported or not. This is only a first step though. The scanner
should also probably attempt a NULL->READY transition on decoders
to validate specific input caps are supported. As this might
require changes in GStreamer, this part of the patch wasn't
included.
This patch is covered by the existing media tests.
- platform/GStreamer.cmake: New files.
- platform/graphics/MediaPlayer.cpp: Add support for converting
SupportsType enum to string.
(WebCore::convertEnumerationToString):
- platform/graphics/MediaPlayer.h: Ditto.
- platform/graphics/MediaPlayerEnums.h: Ditto.
- platform/graphics/gstreamer/GStreamerCommon.cpp: Move
gstRegistryHasElementForMediaType to GStreamerRegistryScanner.
- platform/graphics/gstreamer/GStreamerCommon.h: Ditto.
- platform/graphics/gstreamer/GStreamerRegistryScanner.cpp: Added.
(WebCore::GStreamerRegistryScanner::singleton):
(WebCore::GStreamerRegistryScanner::GStreamerRegistryScanner): Initialize
supported mime-types and codecs from the GStreamer registry.
(WebCore::GStreamerRegistryScanner::~GStreamerRegistryScanner): Free the element factories.
(WebCore::GStreamerRegistryScanner::gstRegistryHasElementForMediaType):
Check the input caps are supported, optionally using hardware
device.
(WebCore::GStreamerRegistryScanner::fillMimeTypeSetFromCapsMapping):
Moved from MediaPlayerPrivateGStreamer{,MSE}.
(WebCore::GStreamerRegistryScanner::initialize): Ditto.
(WebCore::GStreamerRegistryScanner::supportsCodec const): Ditto.
(WebCore::GStreamerRegistryScanner::supportsAllCodecs const): Ditto.
(WebCore::GStreamerRegistryScanner::isDecodingSupported const): Check
the given configuration is supported. For now hardware support is
checked for video configurations only as it is quite uncommon
anyway to have hardware-enabled audio decoders.
- platform/graphics/gstreamer/GStreamerRegistryScanner.h: Added.
(WebCore::GStreamerRegistryScanner::mimeTypeSet):
(WebCore::GStreamerRegistryScanner::supportsContainerType const):
(WebCore::GStreamerRegistryScanner::RegistryLookupResult::operator bool const):
- platform/graphics/gstreamer/MediaEngineConfigurationFactoryGStreamer.cpp: Added.
(WebCore::createMediaPlayerDecodingConfigurationGStreamer):
- platform/graphics/gstreamer/MediaEngineConfigurationFactoryGStreamer.h: Added.
- platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
Rely on new GStreamerRegistryScanner and add some debugging macros.
(WebCore::MediaPlayerPrivateGStreamer::getSupportedTypes):
(WebCore::MediaPlayerPrivateGStreamer::supportsType):
- platform/graphics/gstreamer/mse/AppendPipeline.cpp: Ditto. Also
plug qtdemux for AAC containers, this is an explicit consequence
of finer-grained codecs probing.
(WebCore::AppendPipeline::AppendPipeline):
(WebCore::AppendPipeline::parseDemuxerSrcPadCaps):
- platform/graphics/gstreamer/mse/GStreamerRegistryScannerMSE.cpp: Added.
(WebCore::GStreamerRegistryScannerMSE::singleton):
(WebCore::GStreamerRegistryScannerMSE::GStreamerRegistryScannerMSE):
- platform/graphics/gstreamer/mse/GStreamerRegistryScannerMSE.h: Added.
- platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.cpp:
Rely on new GStreamerRegistryScanner and add some debugging macros.
(WebCore::MediaPlayerPrivateGStreamerMSE::getSupportedTypes):
(WebCore::MediaPlayerPrivateGStreamerMSE::supportsType):
- platform/graphics/gstreamer/mse/MediaPlayerPrivateGStreamerMSE.h:
- platform/mediacapabilities/MediaEngineConfigurationFactory.cpp:
(WebCore::factories): GStreamer support.
- 5:49 AM Changeset in webkit [241584] by
-
- 3 edits in trunk/Source/WebKit
Unreviewed. Fix GTK+ build after r241556
I guess this is due to unified builds after a new file being added in r241556.
Patch by Carlos Garcia Campos <cgarcia@igalia.com> on 2019-02-15
- UIProcess/API/C/WKAuthenticationDecisionListener.cpp:
- UIProcess/API/C/WKPage.cpp:
- 5:41 AM Changeset in webkit [241583] by
-
- 4 edits in trunk/Source/WTF
Fix deadlock on Linux/x64 between SamplingProfiler and VMTraps
https://bugs.webkit.org/show_bug.cgi?id=194014
Reviewed by Michael Catanzaro.
Do not block SIGUSR1 when installing signal handlers, since this signal
is used to suspend/resume machine threads on Linux.
ftl-ai-filter-phantoms-should-clear-clear-value.js deadlocked with
enabled watchdog and sampling.
Deadlock happened in the following situation:
Thread 1 (Sampling): SamplingProfiler.cpp:takeSample takes all needed locks
and then tries to suspend the main thread.
Thread 2 (Watchdog/VMTraps): Before the Sampling-Thread suspends the main thread
a signal is caught and the signal handler is invoked (VMTraps.cpp:SignalSender).
SignalSender tries to lock codeBlockSet, but this is already locked by the
SamplingProfiler.
The SamplingProfiler can only give up the lock when it suspends
the thread. However since the VMTraps signal handler is active, all other signals blocked,
therefore the SamplingProfiler also waits until its signal handler is invoked.
This patch fixes this by not blocking SIGUSR1 in installSignalHandler, since
it is used to suspend/resume threads on Linux.
- wtf/Threading.h:
- wtf/posix/ThreadingPOSIX.cpp:
- wtf/threads/Signals.cpp:
(WTF::installSignalHandler):
- 1:27 AM Changeset in webkit [241582] by
-
- 11 edits in trunk/Source/JavaScriptCore
[JSC] Do not even allocate JIT worklists in non-JIT mode
https://bugs.webkit.org/show_bug.cgi?id=194693
Reviewed by Mark Lam.
Heap always allocates JIT worklists for Baseline, DFG, and FTL. While they do not have actual threads, Worklist itself already allocates some memory.
And we do not perform any GC operations that are only meaningful in JIT environment.
- We add VM::canUseJIT() check in Heap's ensureXXXWorklist things to prevent them from being allocated.
- We remove DFG marking constraint in non-JIT mode.
- We do not gather conservative roots from scratch buffers under the non-JIT mode (BTW, # of scratch buffers are always zero in non-JIT mode)
- We do not visit JITStubRoutineSet.
- Align JITWorklist function names to the other worklists.
- dfg/DFGOSRExitPreparation.cpp:
(JSC::DFG::prepareCodeOriginForOSRExit):
- dfg/DFGPlan.h:
- dfg/DFGWorklist.cpp:
(JSC::DFG::markCodeBlocks): Deleted.
- dfg/DFGWorklist.h:
- heap/Heap.cpp:
(JSC::Heap::completeAllJITPlans):
(JSC::Heap::iterateExecutingAndCompilingCodeBlocks):
(JSC::Heap::gatherScratchBufferRoots):
(JSC::Heap::removeDeadCompilerWorklistEntries):
(JSC::Heap::stopThePeriphery):
(JSC::Heap::suspendCompilerThreads):
(JSC::Heap::resumeCompilerThreads):
(JSC::Heap::addCoreConstraints):
- jit/JITWorklist.cpp:
(JSC::JITWorklist::existingGlobalWorklistOrNull):
(JSC::JITWorklist::ensureGlobalWorklist):
(JSC::JITWorklist::instance): Deleted.
- jit/JITWorklist.h:
- llint/LLIntSlowPaths.cpp:
(JSC::LLInt::jitCompileAndSetHeuristics):
- runtime/VM.cpp:
(JSC::VM::~VM):
(JSC::VM::gatherScratchBufferRoots):
(JSC::VM::gatherConservativeRoots): Deleted.
- runtime/VM.h:
- 1:09 AM Changeset in webkit [241581] by
-
- 2 edits in trunk/Source/bmalloc
[bmalloc] NSBundle-based application name check should be executed after debug-heap environment variable check
https://bugs.webkit.org/show_bug.cgi?id=194694
Reviewed by Mark Lam.
Interestingly, NSBundle allocates fair amount of memory and keeps it for a process-long time. For example, it
allocates global NSConcreteHashTable, which takes 2.5KB. This patch changes the order of gigacage-check, we
first check "Malloc=1" status, and then check the process name through NSBundle. This allows us to remove NSBundle
related allocation in JSC initialization in the system malloc mode.
- bmalloc/Gigacage.cpp:
(Gigacage::shouldBeEnabled):
- 12:43 AM Changeset in webkit [241580] by
-
- 2 edits in trunk/Source/bmalloc
[bmalloc] Do not start scavenger thread if we use system malloc
https://bugs.webkit.org/show_bug.cgi?id=194674
Reviewed by Mark Lam.
We always start the scavenger thread even if system malloc is used by the environment variable like "Malloc=1".
Because bmalloc allocation goes to the system malloc if "Malloc=1" is set, we do not need to scavenge. This patch
changes it not to start the scavenger thread.
- bmalloc/Scavenger.cpp:
(bmalloc::Scavenger::Scavenger):
- 12:26 AM Changeset in webkit [241579] by
-
- 21 edits3 adds in trunk
[WebAssembly] Write a new register allocator for Air O0 and make BBQ use it
https://bugs.webkit.org/show_bug.cgi?id=194036
Reviewed by Yusuke Suzuki.
JSTests:
- stress/tail-call-many-arguments.js: Added.
(foo):
(bar):
Source/JavaScriptCore:
This patch adds a new Air-O0 backend. Air-O0 runs fewer passes and doesn't
use linear scan for register allocation. Instead of linear scan, Air-O0 does
mostly block-local register allocation, and it does this as it's emitting
code directly. The register allocator uses liveness analysis to reduce
the number of spills. Doing register allocation as we're emitting code
allows us to skip editing the IR to insert spills, which saves a non trivial
amount of compile time. For stack allocation, we give each Tmp its own slot.
This is less than ideal. We probably want to do some trivial live range analysis
in the future. The reason this isn't a deal breaker for Wasm is that this patch
makes it so that we reuse Tmps as we're generating Air IR in the AirIRGenerator.
Because Wasm is a stack machine, we trivially know when we kill a stack value (its last use).
This patch is another 25% Wasm startup time speedup. It seems to be worth
another 1% on JetStream2.
- JavaScriptCore.xcodeproj/project.pbxproj:
- Sources.txt:
- b3/air/AirAllocateRegistersAndStackAndGenerateCode.cpp: Added.
(JSC::B3::Air::GenerateAndAllocateRegisters::GenerateAndAllocateRegisters):
(JSC::B3::Air::GenerateAndAllocateRegisters::buildLiveRanges):
(JSC::B3::Air::GenerateAndAllocateRegisters::insertBlocksForFlushAfterTerminalPatchpoints):
(JSC::B3::Air::callFrameAddr):
(JSC::B3::Air::GenerateAndAllocateRegisters::flush):
(JSC::B3::Air::GenerateAndAllocateRegisters::spill):
(JSC::B3::Air::GenerateAndAllocateRegisters::alloc):
(JSC::B3::Air::GenerateAndAllocateRegisters::freeDeadTmpsIfNeeded):
(JSC::B3::Air::GenerateAndAllocateRegisters::assignTmp):
(JSC::B3::Air::GenerateAndAllocateRegisters::isDisallowedRegister):
(JSC::B3::Air::GenerateAndAllocateRegisters::prepareForGeneration):
(JSC::B3::Air::GenerateAndAllocateRegisters::generate):
- b3/air/AirAllocateRegistersAndStackAndGenerateCode.h: Added.
- b3/air/AirCode.cpp:
- b3/air/AirCode.h:
- b3/air/AirGenerate.cpp:
(JSC::B3::Air::prepareForGeneration):
(JSC::B3::Air::generateWithAlreadyAllocatedRegisters):
(JSC::B3::Air::generate):
- b3/air/AirHandleCalleeSaves.cpp:
(JSC::B3::Air::handleCalleeSaves):
- b3/air/AirHandleCalleeSaves.h:
- b3/air/AirTmpMap.h:
- runtime/Options.h:
- wasm/WasmAirIRGenerator.cpp:
(JSC::Wasm::AirIRGenerator::didKill):
(JSC::Wasm::AirIRGenerator::newTmp):
(JSC::Wasm::AirIRGenerator::AirIRGenerator):
(JSC::Wasm::parseAndCompileAir):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncUF64>):
(JSC::Wasm::AirIRGenerator::addOp<OpType::I64TruncUF32>):
- wasm/WasmAirIRGenerator.h:
- wasm/WasmB3IRGenerator.cpp:
(JSC::Wasm::B3IRGenerator::didKill):
- wasm/WasmBBQPlan.cpp:
(JSC::Wasm::BBQPlan::compileFunctions):
- wasm/WasmFunctionParser.h:
(JSC::Wasm::FunctionParser<Context>::parseBody):
(JSC::Wasm::FunctionParser<Context>::parseExpression):
- wasm/WasmValidate.cpp:
(JSC::Wasm::Validate::didKill):
Source/WTF:
- wtf/IndexMap.h:
(WTF::IndexMap::at):
(WTF::IndexMap::at const):
(WTF::IndexMap::operator[]):
(WTF::IndexMap::operator[] const):
Tools:
- Scripts/run-jsc-stress-tests:
Feb 14, 2019:
- 10:37 PM Changeset in webkit [241578] by
-
- 7 edits in branches/safari-608.1.5.1-branch/Source
Versioning.
- 10:37 PM Changeset in webkit [241577] by
-
- 4 edits in trunk/Source/JavaScriptCore
lowerStackArgs should lower Lea32/64 on ARM64 to Add
https://bugs.webkit.org/show_bug.cgi?id=194656
Reviewed by Yusuke Suzuki.
On arm64, Lea is just implemented as an add. However, Air treats it as an
address with a given width. Because of this width, we were incorrectly
computing whether or not this immediate could fit into the instruction itself
or it needed to be explicitly put into a register. This patch makes
AirLowerStackArgs lower Lea to Add on arm64.
- b3/air/AirLowerStackArgs.cpp:
(JSC::B3::Air::lowerStackArgs):
- b3/air/AirOpcode.opcodes:
- b3/air/testair.cpp:
- 10:06 PM Changeset in webkit [241576] by
-
- 7 edits in tags/Safari-608.1.6.1/Source
Versioning.
- 10:01 PM Changeset in webkit [241575] by
-
- 1 copy in tags/Safari-608.1.6.1
New tag.
- 5:55 PM Changeset in webkit [241574] by
-
- 4 edits in trunk/Source/WebKit
REGRESSION (r240446): Storage Access API does not handle domains consistently
https://bugs.webkit.org/show_bug.cgi?id=194664
Reviewed by Alex Christensen.
During my refactoring of the ResourceLoadStatistics code, I introduced two bugs:
(1) I neglected to be consistent in my use of 'primaryDomain', causing some Storage
Access API code paths to store approves under one domain (e.g., 'www.example.com'),
while checking status under the eTLD+1 (e.g., 'example.com'). The exact string matching
requirement caused these to get missed.
(2) I used a move operator before a final set of copies of domain names, leading to
some empty strings being passed to Storage Access API calls.
Both issues are corrected in this patch.
- NetworkProcess/Classifier/WebResourceLoadStatisticsStore.cpp:
(WebKit::WebResourceLoadStatisticsStore::setPrevalentResourceForDebugMode): Always make the
domain comply with our 'primaryDomain' logic.
(WebKit::WebResourceLoadStatisticsStore::hasStorageAccess): Ditto.
(WebKit::WebResourceLoadStatisticsStore::requestStorageAccessGranted): Ditto.
(WebKit::WebResourceLoadStatisticsStore::logFrameNavigation): Ditto.
(WebKit::WebResourceLoadStatisticsStore::logWebSocketLoading): Ditto.
(WebKit::WebResourceLoadStatisticsStore::logSubresourceLoading): Ditto.
(WebKit::WebResourceLoadStatisticsStore::logSubresourceRedirect): Ditto.
(WebKit::WebResourceLoadStatisticsStore::logUserInteraction): Ditto.
(WebKit::WebResourceLoadStatisticsStore::clearUserInteraction): Ditto.
(WebKit::WebResourceLoadStatisticsStore::hasHadUserInteraction): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setLastSeen): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setPrevalentResource): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setVeryPrevalentResource): Ditto.
(WebKit::WebResourceLoadStatisticsStore::isPrevalentResource): Ditto.
(WebKit::WebResourceLoadStatisticsStore::isVeryPrevalentResource): Ditto.
(WebKit::WebResourceLoadStatisticsStore::isRegisteredAsSubresourceUnder): Ditto.
(WebKit::WebResourceLoadStatisticsStore::isRegisteredAsSubFrameUnder): Ditto.
(WebKit::WebResourceLoadStatisticsStore::isRegisteredAsRedirectingTo): Ditto.
(WebKit::WebResourceLoadStatisticsStore::clearPrevalentResource): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setGrandfathered): Ditto.
(WebKit::WebResourceLoadStatisticsStore::isGrandfathered): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setSubframeUnderTopFrameOrigin): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setSubresourceUnderTopFrameOrigin): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setSubresourceUniqueRedirectTo): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setSubresourceUniqueRedirectFrom): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setTopFrameUniqueRedirectTo): Ditto.
(WebKit::WebResourceLoadStatisticsStore::setTopFrameUniqueRedirectFrom): Ditto.
- UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::hasStorageAccess): Always make the
domain comply with our 'primaryDomain' logic.
(WebKit::WebsiteDataStore::requestStorageAccess): Ditto. Also make copy of domain
names before moving them to the completion handler.
(WebKit::WebsiteDataStore::grantStorageAccess): Ditto.
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::hasStorageAccess): Always make the domain comply with our
'primaryDomain' logic.
(WebKit::WebPage::requestStorageAccess): Ditto.
- 4:51 PM Changeset in webkit [241573] by
-
- 4 edits in trunk/Tools
Fix the build.
- WebKitTestRunner/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptController::drawSquareInEditableImage):
- TestWebKitAPI/Tests/WebKitCocoa/WKAttachmentTests.mm:
(TestWebKitAPI::drawSquareInEditableImage):
- 4:19 PM Changeset in webkit [241572] by
-
- 3 edits2 deletes in trunk
Unreviewed, rolling out r241497.
https://bugs.webkit.org/show_bug.cgi?id=194676
New test times out (Requested by NVI on #webkit).
Reverted changeset:
"Web Inspector: Styles: valid values in style attributes are
reported as unsupported property values"
https://bugs.webkit.org/show_bug.cgi?id=194619
https://trac.webkit.org/changeset/241497
- 4:06 PM Changeset in webkit [241571] by
-
- 10 edits1 add in trunk
Cache the results of BytecodeGenerator::getVariablesUnderTDZ
https://bugs.webkit.org/show_bug.cgi?id=194583
<rdar://problem/48028140>
Reviewed by Yusuke Suzuki.
JSTests:
- microbenchmarks/cache-get-variables-under-tdz-in-bytecode-generator.js: Added.
Source/JavaScriptCore:
This patch makes it so that getVariablesUnderTDZ caches a result of
CompactVariableMap::Handle. getVariablesUnderTDZ is costly when
it's called in an environment where there are a lot of variables.
This patch makes it so we cache its results. This is profitable when
getVariablesUnderTDZ is called repeatedly with the same environment
state. This is common since we call this every time we encounter a
function definition/expression node.
- builtins/BuiltinExecutables.cpp:
(JSC::BuiltinExecutables::createExecutable):
- bytecode/UnlinkedFunctionExecutable.cpp:
(JSC::UnlinkedFunctionExecutable::UnlinkedFunctionExecutable):
- bytecode/UnlinkedFunctionExecutable.h:
- bytecompiler/BytecodeGenerator.cpp:
(JSC::BytecodeGenerator::popLexicalScopeInternal):
(JSC::BytecodeGenerator::liftTDZCheckIfPossible):
(JSC::BytecodeGenerator::pushTDZVariables):
(JSC::BytecodeGenerator::getVariablesUnderTDZ):
(JSC::BytecodeGenerator::restoreTDZStack):
- bytecompiler/BytecodeGenerator.h:
(JSC::BytecodeGenerator::makeFunction):
- parser/VariableEnvironment.cpp:
(JSC::CompactVariableMap::Handle::Handle):
(JSC::CompactVariableMap::Handle::operator=):
- parser/VariableEnvironment.h:
(JSC::CompactVariableMap::Handle::operator bool const):
- runtime/CodeCache.cpp:
(JSC::CodeCache::getUnlinkedGlobalFunctionExecutable):
- 4:01 PM Changeset in webkit [241570] by
-
- 5 edits in trunk
Fix the build.
- UIProcess/ios/WKDrawingView.mm:
(-[WKDrawingView renderedDrawing]):
- WebKitTestRunner/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptController::drawSquareInEditableImage):
- TestWebKitAPI/Tests/WebKitCocoa/WKAttachmentTests.mm:
(TestWebKitAPI::drawSquareInEditableImage):
- 3:52 PM Changeset in webkit [241569] by
-
- 1 copy in tags/Safari-607.1.36
Tag Safari-607.1.36.
- 3:49 PM Changeset in webkit [241568] by
-
- 1 copy in tags/Safari-608.1.5.1.2
Tag Safari-608.1.5.1.2.
- 3:39 PM Changeset in webkit [241567] by
-
- 2 edits in trunk/Source/WebCore
Web Inspector: Occasional crash under WebCore::CSSStyleSheet::item called from Inspector
https://bugs.webkit.org/show_bug.cgi?id=194671
<rdar://problem/47628191>
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-14
Reviewed by Devin Rousso.
- css/CSSStyleSheet.cpp:
(WebCore::CSSStyleSheet::item):
A crash may happen if the m_childRuleCSSOMWrappers Vector gets out of
sync with the m_contents list of rules. In particular if the wrappers
vector is shorter than the rule list. We tried exercising code paths
that modify these lists but were not able to reproduce the crash.
To avoid a crash we can make this access safer and avoid the original
overflow. At the same time we will keep and promote the assertion that
would catch the lists getting out of sync in debug builds.
- 3:06 PM Changeset in webkit [241566] by
-
- 2 edits in trunk/Source/WebCore
Unreviewed build fix for WinCairo Debug after r241559.
- platform/network/curl/CurlContext.cpp:
(WebCore::CurlContext::CurlContext):
- 2:55 PM Changeset in webkit [241565] by
-
- 3 edits in trunk/Source/WebKit
ASSERTION FAILED: m_caches.isEmpty() !m_pendingInitializationCallbacks.isEmpty() in WebKit::CacheStorage::Caches::clearMemoryRepresentation() https://bugs.webkit.org/show_bug.cgi?id=188393
<rdar://problem/43025665>
Reviewed by Alex Christensen.
In case Caches::dispose is called, clearMemoryRepresentation might be called if there is no active cache.
We also ensure to not clear the memory representation if there is any remaining removed cache.
Update the clearMemoryRepresentation assertion to take that into account.
In case a Caches is cleared twice, the clearMemoryRepresentation assertion will assert while it should not.
In that case m_storage is null the second time. Update the assertion accordingly.
- NetworkProcess/cache/CacheStorageEngineCaches.cpp:
(WebKit::CacheStorage::Caches::hasActiveCache const):
(WebKit::CacheStorage::Caches::dispose):
(WebKit::CacheStorage::Caches::clearMemoryRepresentation):
- NetworkProcess/cache/CacheStorageEngineCaches.h:
- 2:32 PM Changeset in webkit [241564] by
-
- 12 edits in trunk
[Mac] WebInspectorUI.framework does not need to be soft-linked anymore
https://bugs.webkit.org/show_bug.cgi?id=194411
<rdar://problem/47787614>
Reviewed by Joseph Pecoraro.
Source/WebKit:
- Configurations/WebKit.xcconfig:
Conditionalize weak linking to WebInspectorUI.framework for Mac only.
- UIProcess/mac/WebInspectorProxyMac.mm:
(WebKit::WebInspectorProxy::inspectorPageURL):
(WebKit::WebInspectorProxy::inspectorTestPageURL):
(WebKit::WebInspectorProxy::inspectorBaseURL):
- WebProcess/WebPage/mac/WebInspectorUIMac.mm:
(WebKit::webInspectorUILocalizedStringsURL):
Rewrite uses of the bundle to exit early if bundle couldn't be loaded.
Source/WebKitLegacy/mac:
- Configurations/WebKitLegacy.xcconfig:
Conditionalize weak linking to WebInspectorUI.framework for Mac only.
- WebCoreSupport/WebInspectorClient.mm:
(WebInspectorFrontendClient::localizedStringsURL):
(-[WebInspectorWindowController inspectorPagePath]):
(-[WebInspectorWindowController inspectorTestPagePath]):
Rewrite uses of the bundle to exit early if bundle couldn't be loaded.
Source/WTF:
- wtf/cocoa/SoftLinking.h:
Remove macro that now has no uses.
Tools:
Remove unnecessary soft linking macro usage.
- DumpRenderTree/mac/TestRunnerMac.mm:
(TestRunner::inspectorTestStubURL):
(SOFT_LINK_STAGED_FRAMEWORK): Deleted.
- WebKitTestRunner/InjectedBundle/mac/TestRunnerMac.mm:
(WTR::TestRunner::inspectorTestStubURL):
- 2:11 PM Changeset in webkit [241563] by
-
- 7 edits in trunk/Source/WebKit
[GTK] WebKitGTK+ -> WebKitGTK
https://bugs.webkit.org/show_bug.cgi?id=194658
Reviewed by Alex Christensen.
This renames WebKitGTK+ to WebKitGTK in a few user-visible places: the API documentation,
the pkg-config, and an error message.
In a couple places where it's exposed in WPE documentation, WPE is now mentioned, or the
reference to "WebKitGTK+" is changed to just "WebKit."
- UIProcess/API/glib/WebKitSettings.cpp:
(webkit_settings_class_init):
- UIProcess/API/glib/WebKitWebView.cpp:
- UIProcess/API/gtk/docs/webkit2gtk-docs.sgml:
- WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMPrivateGtk.h:
- gtk/webkit2gtk-web-extension.pc.in:
- gtk/webkit2gtk.pc.in:
- 2:10 PM Changeset in webkit [241562] by
-
- 2 edits in trunk/Tools
[ews-app] status bubble should fetch builder name info from BuilderMapping table
https://bugs.webkit.org/show_bug.cgi?id=194599
Reviewed by Lucas Forschler.
- BuildSlaveSupport/ews-app/ews/views/statusbubble.py:
(StatusBubble._build_bubble):
- 2:08 PM Changeset in webkit [241561] by
-
- 2 edits in trunk/Tools
[ews-app] Set Foreign Key in Django build model
https://bugs.webkit.org/show_bug.cgi?id=194667
Reviewed by Lucas Forschler.
- BuildSlaveSupport/ews-app/ews/models/build.py:
(Build):
- 1:35 PM Changeset in webkit [241560] by
-
- 6 edits in trunk/Source/JavaScriptCore
[JSC] Non-JIT entrypoints should share NativeJITCode per entrypoint type
https://bugs.webkit.org/show_bug.cgi?id=194659
Reviewed by Mark Lam.
Non-JIT entrypoints create NativeJITCode every time it is called. But it is meaningless since these entry point code are identical.
We should create one per entrypoint type (for function, we should have CodeForCall and CodeForConstruct) and continue to use them.
And we use NativeJITCode instead of DirectJITCode if it does not have difference between usual entrypoint and arity check entrypoint.
- dfg/DFGJITCode.h:
- dfg/DFGJITFinalizer.cpp:
(JSC::DFG::JITFinalizer::finalize):
(JSC::DFG::JITFinalizer::finalizeFunction):
- jit/JITCode.cpp:
(JSC::DirectJITCode::initializeCodeRefForDFG):
(JSC::DirectJITCode::initializeCodeRef): Deleted.
(JSC::NativeJITCode::initializeCodeRef): Deleted.
- jit/JITCode.h:
- llint/LLIntEntrypoint.cpp:
(JSC::LLInt::setFunctionEntrypoint):
(JSC::LLInt::setEvalEntrypoint):
(JSC::LLInt::setProgramEntrypoint):
(JSC::LLInt::setModuleProgramEntrypoint): Retagged is removed since the tag is the same.
- 12:03 PM Changeset in webkit [241559] by
-
- 83 edits3 adds in trunk
[WTF] Add environment variable helpers
https://bugs.webkit.org/show_bug.cgi?id=192405
Reviewed by Michael Catanzaro.
Source/JavaScriptCore:
- inspector/remote/glib/RemoteInspectorGlib.cpp:
(Inspector::RemoteInspector::RemoteInspector):
(Inspector::RemoteInspector::start):
- jsc.cpp:
(startTimeoutThreadIfNeeded):
- runtime/Options.cpp:
(JSC::overrideOptionWithHeuristic):
(JSC::Options::overrideAliasedOptionWithHeuristic):
(JSC::Options::initialize):
- runtime/VM.cpp:
(JSC::enableAssembler):
(JSC::VM::VM):
- tools/CodeProfiling.cpp:
(JSC::CodeProfiling::notifyAllocator):
Utilize WTF::Environment where possible.
Source/WebCore:
- platform/NotImplemented.h:
- platform/cocoa/SystemVersion.mm:
(WebCore::createSystemMarketingVersion):
- platform/graphics/gstreamer/GStreamerCommon.cpp:
(WebCore::initializeGStreamer):
- platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
(WebCore::MediaPlayerPrivateGStreamer::createGSTPlayBin):
- platform/graphics/nicosia/NicosiaPaintingEngine.cpp:
(Nicosia::PaintingEngine::create):
- platform/graphics/texmap/TextureMapperFPSCounter.cpp:
(WebCore::TextureMapperFPSCounter::TextureMapperFPSCounter):
- platform/graphics/x11/PlatformDisplayX11.cpp:
(WebCore::PlatformDisplayX11::create):
- platform/gtk/RenderThemeWidget.cpp:
(WebCore::RenderThemeScrollbar::RenderThemeScrollbar):
- platform/gtk/ScrollbarThemeGtk.cpp:
(WebCore::ScrollbarThemeGtk::ScrollbarThemeGtk):
- platform/network/curl/CurlContext.cpp:
(WebCore::CurlContext::CurlContext):
(WebCore::EnvironmentVariableReader::read): Deleted.
(WebCore::EnvironmentVariableReader::defined): Deleted.
(WebCore::EnvironmentVariableReader::readAs): Deleted.
(WebCore::EnvironmentVariableReader::sscanTemplate): Deleted.
(WebCore::EnvironmentVariableReader::sscanTemplate<signed>): Deleted.
(WebCore::EnvironmentVariableReader::sscanTemplate<unsigned>): Deleted.
- platform/network/curl/NetworkStorageSessionCurl.cpp:
(WebCore::defaultCookieJarPath):
- platform/network/playstation/CurlSSLHandlePlayStation.cpp:
(WebCore::getCACertPathEnv):
- platform/network/win/CurlSSLHandleWin.cpp:
(WebCore::getCACertPathEnv):
- platform/text/hyphen/HyphenationLibHyphen.cpp:
(WebCore::topLevelPath):
(WebCore::webkitBuildDirectory):
- platform/unix/LoggingUnix.cpp:
(WebCore::logLevelString):
- platform/win/LoggingWin.cpp:
(WebCore::logLevelString):
Utilize WTF::Environment where possible.
Source/WebCore/PAL:
- pal/unix/LoggingUnix.cpp:
(PAL::logLevelString):
- pal/win/LoggingWin.cpp:
(PAL::logLevelString):
Utilize WTF::Environment where possible.
Source/WebKit:
- NetworkProcess/EntryPoint/unix/NetworkProcessMain.cpp:
(main):
- Platform/unix/EnvironmentUtilities.cpp:
(WebKit::EnvironmentUtilities::stripValuesEndingWithString):
- Platform/unix/LoggingUnix.cpp:
(WebKit::logLevelString):
- Platform/win/LoggingWin.cpp:
(WebKit::logLevelString):
- PluginProcess/mac/PluginProcessMac.mm:
(WebKit::shouldCallRealDebugger):
- Shared/Plugins/unix/PluginSearchPath.cpp:
(WebKit::pluginsDirectories):
- Shared/glib/ProcessExecutablePathGLib.cpp:
(WebKit::findWebKitProcess):
- UIProcess/API/glib/WebKitSettings.cpp:
(webKitSettingsConstructed):
(webKitSettingsSetProperty):
- UIProcess/API/glib/WebKitWebContext.cpp:
(injectedBundleDirectory):
(webkitWebContextConstructed):
- UIProcess/API/gtk/WebKitWebViewGtk.cpp:
(webkitWebViewMaximizeWindow):
(webkitWebViewRestoreWindow):
- UIProcess/API/wpe/WPEView.cpp:
(WKWPE::m_backend):
- UIProcess/AuxiliaryProcessProxy.cpp:
(WebKit::AuxiliaryProcessProxy::getLaunchOptions):
- UIProcess/Launcher/glib/BubblewrapLauncher.cpp:
(WebKit::XDGDBusProxyLauncher::launch):
(WebKit::bindDBusSession):
(WebKit::bindX11):
(WebKit::bindWayland):
(WebKit::bindPulse):
(WebKit::bindPathVar):
(WebKit::bindGStreamerData):
(WebKit::bubblewrapSpawn):
- UIProcess/Launcher/glib/ProcessLauncherGLib.cpp:
(WebKit::ProcessLauncher::launchProcess):
- UIProcess/Launcher/mac/ProcessLauncherMac.mm:
(WebKit::systemDirectoryPath):
(WebKit::ProcessLauncher::launchProcess):
- UIProcess/glib/WebProcessPoolGLib.cpp:
(WebKit::memoryPressureMonitorDisabled):
(WebKit::WebProcessPool::platformInitialize):
(WebKit::WebProcessPool::platformInitializeWebProcess):
- UIProcess/gtk/HardwareAccelerationManager.cpp:
(WebKit::HardwareAccelerationManager::HardwareAccelerationManager):
- WebProcess/EntryPoint/unix/WebProcessMain.cpp:
(main):
- WebProcess/gtk/WebProcessMainGtk.cpp:
- WebProcess/wpe/WebProcessMainWPE.cpp:
Utilize WTF::Environment where possible.
Source/WebKitLegacy/ios:
- Misc/WebUIKitSupport.mm:
(WebKitPlatformSystemRootDirectory):
Utilize WTF::Environment where possible.
Source/WebKitLegacy/mac:
- WebView/WebView.mm:
(-[WebView _initWithFrame:frameName:groupName:]):
Utilize WTF::Environment where possible.
Source/WTF:
Create a new Environment API as a platform-independent, thread-safe(r)
way to get and set environment variables.
- WTF.xcodeproj/project.pbxproj:
- wtf/CMakeLists.txt:
- wtf/Environment.h: Added.
- wtf/PlatformGTK.cmake:
- wtf/PlatformJSCOnly.cmake:
- wtf/PlatformMac.cmake:
- wtf/PlatformPlayStation.cmake:
- wtf/PlatformWPE.cmake:
- wtf/PlatformWin.cmake:
- wtf/posix/EnvironmentPOSIX.cpp: Added.
- wtf/win/EnvironmentWin.cpp: Added.
Introduce WTF::Environment.
- wtf/Threading.cpp:
(WTF::threadingIsInitialized):
(WTF::initializeThreading):
- wtf/Threading.h:
Introduce WTF::threadingIsInitialized() so that we can ASSERT that it's
false before setting an environment variable through the new API.
- wtf/DataLog.cpp:
(WTF::initializeLogFileOnce):
- wtf/NumberOfCores.cpp:
(WTF::numberOfProcessorCores):
- wtf/posix/FileSystemPOSIX.cpp:
(WTF::FileSystemImpl::openTemporaryFile):
Utilize WTF::Environment where possible.
Tools:
- DumpRenderTree/mac/DumpRenderTree.mm:
(libraryPathForDumpRenderTree):
- DumpRenderTree/win/DumpRenderTree.cpp:
(libraryPathForDumpRenderTree):
- TestRunnerShared/IOSLayoutTestCommunication.cpp:
(setUpIOSLayoutTestCommunication):
- TestWebKitAPI/Tests/WebKit/EnvironmentUtilitiesTest.cpp:
(TestWebKitAPI::strip):
- TestWebKitAPI/Tests/WebKitGLib/TestAutomationSession.cpp:
(beforeAll):
- TestWebKitAPI/glib/WebKitGLib/TestMain.cpp:
(main):
- TestWebKitAPI/glib/WebKitGLib/WebKitTestBus.cpp:
(WebKitTestBus::run):
- WebKitTestRunner/InjectedBundle/gtk/ActivateFontsGtk.cpp:
(WTR::getOutputDir):
(WTR::initializeFontConfigSetting):
- WebKitTestRunner/InjectedBundle/gtk/InjectedBundleGtk.cpp:
(WTR::InjectedBundle::platformInitialize):
- WebKitTestRunner/InjectedBundle/gtk/InjectedBundleUtilities.cpp:
(WTR::topLevelPath):
- WebKitTestRunner/InjectedBundle/wpe/ActivateFontsWPE.cpp:
(WTR::topLevelPath):
(WTR::getOutputDir):
(WTR::activateFonts):
- WebKitTestRunner/TestController.cpp:
(WTR::TestController::libraryPathForTesting):
(WTR::TestController::generateContextConfiguration const):
(WTR::TestController::generatePageConfiguration):
(WTR::TestController::decideDestinationWithSuggestedFilename):
(WTR::TestController::platformAdjustContext):
- WebKitTestRunner/TestController.h:
- WebKitTestRunner/cocoa/TestControllerCocoa.mm:
(WTR::TestController::cocoaPlatformInitialize):
(WTR::TestController::platformAdjustContext):
- WebKitTestRunner/gtk/main.cpp:
(main):
- WebKitTestRunner/mac/TestControllerMac.mm:
(WTR::TestController::configureContentExtensionForTest):
- WebKitTestRunner/wpe/main.cpp:
(main):
Utilize WTF::Environment where possible.
- 11:54 AM Changeset in webkit [241558] by
-
- 2 edits in trunk/Source/WebKit
Handle _WKNavigationActionPolicyAllowWithoutTryingAppLink for LoadOptimizer
https://bugs.webkit.org/show_bug.cgi?id=194640
<rdar://problem/48064140>
Reviewed by Brent Fulgham.
- UIProcess/Cocoa/NavigationState.mm:
(WebKit::NavigationState::NavigationClient::decidePolicyForNavigationAction):
- 11:10 AM Changeset in webkit [241557] by
-
- 2 edits in trunk/Source/JavaScriptCore
[JSC] Should have default NativeJITCode
https://bugs.webkit.org/show_bug.cgi?id=194634
Reviewed by Mark Lam.
In JSC_useJIT=false mode, we always create identical NativeJITCode for call and construct when we create NativeExecutable.
This is meaningless since we do not modify NativeJITCode after the creation. This patch adds singleton used as a default one.
Since NativeJITCode (& JITCode) is ThreadSafeRefCounted, we can just share it in a whole process level. This removes 446 NativeJITCode
allocations, which takes 14KB.
- runtime/VM.cpp:
(JSC::jitCodeForCallTrampoline):
(JSC::jitCodeForConstructTrampoline):
(JSC::VM::getHostFunction):
- 11:06 AM Changeset in webkit [241556] by
-
- 29 edits2 adds in trunk
[PSON] Introduce a WebContent Process cache
https://bugs.webkit.org/show_bug.cgi?id=194594
<rdar://problem/46793397>
Reviewed by Geoff Garen.
Source/WebCore:
Update localizable strings.
- en.lproj/Localizable.strings:
Source/WebKit:
Introduce a WebContent Process cache to reduce the number of process launches when
process swap on navigation is enabled, and to reduce the power cost of the feature.
If a WebProcess loaded pages from a single registrable domain then it is eligible
for the cache. When process-swapping on navigation to a new registrable domain, we
now attempt to retrieve a process from the cache for the domain in question instead
of always launching a new one.
The WebProcess cache currently has the following attributes:
- It may contains 4 processes per GB of RAM the machine has, up to 30 processes.
- WebProcesses automatically get evicted from the cache after 30 minutes.
- If the application is no longer the active app, then the cache will get cleared after 5 minutes.
- WebProcesses that are in the cache are reported as "(Cached)" in Activity Monitor.
The WebProcess cache is currently disabled by default and can by enabled by the
client via SPI.
- Shared/WebBackForwardListItem.cpp:
(WebKit::WebBackForwardListItem::WebBackForwardListItem):
- Shared/WebBackForwardListItem.h:
(WebKit::WebBackForwardListItem::lastProcessIdentifier const):
(WebKit::WebBackForwardListItem::setLastProcessIdentifier):
Add new lastProcessIdentifier data member that reflects which process this item
was last loaded in. It is normally identical to the identifier of the process
that created the item but it gets overriden in case of cross-site client-side
redirect, since a new process takes over the item in this case.
- Sources.txt:
Add new source file.
- UIProcess/API/APIProcessPoolConfiguration.cpp:
(API::ProcessPoolConfiguration::copy):
- UIProcess/API/APIProcessPoolConfiguration.h:
- UIProcess/API/C/WKContextConfigurationRef.cpp:
(WKContextConfigurationUsesWebProcessCache):
(WKContextConfigurationSetUsesWebProcessCache):
- UIProcess/API/C/WKContextConfigurationRef.h:
- UIProcess/API/Cocoa/_WKProcessPoolConfiguration.h:
- UIProcess/API/Cocoa/_WKProcessPoolConfiguration.mm:
(-[_WKProcessPoolConfiguration setUsesWebProcessCache:]):
(-[_WKProcessPoolConfiguration usesWebProcessCache]):
Add new SPI to enable the WebProcess cache.
- UIProcess/API/Cocoa/WKProcessPool.mm:
(-[WKProcessPool _webProcessCountIgnoringPrewarmedAndCached]):
- UIProcess/API/Cocoa/WKProcessPoolPrivate.h:
Add new SPI for testing which returns the number of WebProcesses ignoring
both prewarmed and cached ones.
- UIProcess/Cocoa/WebProcessPoolCocoa.mm:
(WebKit::WebProcessPool::registerNotificationObservers):
(WebKit::WebProcessPool::unregisterNotificationObservers):
Add application active state observers as the WebProcess cache gets cleared
when the application resigns active state for more than 5 minutes.
- UIProcess/ProvisionalPageProxy.cpp:
(WebKit::ProvisionalPageProxy::loadRequest):
When doing a load in a new process with the BackForwardList locked (i.e. client-side
redirect), make sure we update the last process identifier for the BackForwardListItem.
This is important because the logic in WebProcessPool::processForNavigation() relies on
this identifier to select which process to do the history navigation into, and we want
to do the load in the post-redirect process, not the pre-redirect one.
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didStartProvisionalLoadForFrameShared):
Tell the WebProcess whenever a main frame provisional load is started, providing the URL.
- UIProcess/WebProcessCache.cpp: Added.
(WebKit::WebProcessCache::WebProcessCache):
(WebKit::WebProcessCache::addProcess):
(WebKit::WebProcessCache::takeProcess):
(WebKit::WebProcessCache::updateMaximumSize):
(WebKit::WebProcessCache::clear):
(WebKit::WebProcessCache::setApplicationIsActive):
(WebKit::WebProcessCache::evictProcess):
(WebKit::WebProcessCache::CachedProcess::CachedProcess):
(WebKit::WebProcessCache::CachedProcess::~CachedProcess):
(WebKit::WebProcessCache::CachedProcess::takeProcess):
(WebKit::WebProcessCache::CachedProcess::evictionTimerFired):
- UIProcess/WebProcessCache.h: Added.
(WebKit::WebProcessCache::maximumSize):
(WebKit::WebProcessCache::size const):
(WebKit::WebProcessCache::CachedProcess::process):
Add process cache implementation.
- UIProcess/WebProcessPool.cpp:
(WebKit::m_webProcessCache):
WebProcessCache is stored on the WebProcessPool via m_webProcessCache data member.
(WebKit::WebProcessPool::~WebProcessPool):
Clear the WebProcess cache in the destructor.
(WebKit::WebProcessPool::setApplicationIsActive):
Notify the WebProcessCache whenever the application's active state changes.
(WebKit::WebProcessPool::createWebPage):
If the state of PSON changes via the experimental features menu, dynamically
update the WebProcessCache's size. This is needed because the cache is disabled
when PSON is disabled.
(WebKit::WebProcessPool::handleMemoryPressureWarning):
Clear the WebProcess cache on memory pressure.
(WebKit::WebProcessPool::processForNavigationInternal):
Query the WebProcessCache before attempting to create a new WebProcess for a cross-site
navigation.
(WebKit::WebProcessPool::findReusableSuspendedPageProcess):
This logic was split out of processForNavigationInternal() to reduce the size
of the method.
- UIProcess/WebProcessPool.h:
- UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::setIsInProcessCache):
Update the isInProcessCache flag on the WebProcessProxy and send an IPC to the WebContent
process so that it can update its name in Activity Monitor.
We also need to stop holding a strong reference to the WebProcessPool whenever the process
is in the cache, similarly to what we do for pre-warmed processes, given that such processes
should not keep the process pool alive.
(WebKit::WebProcessProxy::addExistingWebPage):
Assert that we never try to add a page to a cached process, it should be taken out of the
cache before use.
(WebKit::WebProcessProxy::hasProvisionalPageWithID const):
(WebKit::WebProcessProxy::isAllowedToUpdateBackForwardItem const):
(WebKit::WebProcessProxy::updateBackForwardItem):
In case of client-side redirects, the previous process would sometimes send an IPC causing
the UIProcess' backforward list item to get updated with the pre-redirect URL after we've
already redirected. This previously would be unlikely to occur because we do not suspend
client-redirect pages and their process would normally exit before getting a chance to send
the IPC. However, with the process cache, the bug became obvious as the process would stay
alive and send up the "bad" IPC. To address the issue, we now only let the IPC update the
item if the item's page is (still) associated with the process. In the future, we may want
to update the IPC so that it gets sent to the WebPageProxy instead of the WebProcessProxy.
(WebKit::WebProcessProxy::processDidTerminateOrFailedToLaunch):
If a cached WebProcess crashes, remove it from the cache so that we do not attempt to use
it for a load later.
(WebKit::WebProcessProxy::canBeAddedToWebProcessCache const):
Only cache WebProcesses that have loaded a single registrable domain. Also prevent caching
for service worker and inspector processes.
(WebKit::WebProcessProxy::maybeShutDown):
If the process is cacheable, add it to the cache instead of shutting it down right away.
(WebKit::WebProcessProxy::canTerminateAuxiliaryProcess):
Make sure we do not attempt to terminate a processes that is in the cache.
(WebKit::WebProcessProxy::didStartProvisionalLoadForMainFrame):
Whenever a main frame provisional load starts, make sure we update the process's associated
registrable domain. nullopt indicates that there is no associated domain yet. Null string
indicates that the process is associated with several registrable domain and is therefore
not eligible for caching.
- UIProcess/WebProcessProxy.h:
(WebKit::WebProcessProxy::registrableDomain const):
(WebKit::WebProcessProxy::isInProcessCache const):
(WebKit::WebProcessProxy::provisionalPageCount const):
Add convenience getters.
- WebKit.xcodeproj/project.pbxproj:
Add new files to project.
- WebProcess/WebProcess.cpp:
(WebKit::WebProcess::setIsInProcessCache):
- WebProcess/WebProcess.h:
- WebProcess/WebProcess.messages.in:
- WebProcess/cocoa/WebProcessCocoa.mm:
(WebKit::WebProcess::updateProcessName):
Update the WebProcess' name in Activity Monitor whenever it goes into or out of the WebProcess
cache.
Tools:
Update API tests to turn on the WebContent Process cache.
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
- 11:00 AM Changeset in webkit [241555] by
-
- 2 edits in branches/safari-607-branch/Tools
Cherry-pick r241553. rdar://problem/47610130
Unreviewed, build fix after r241480
- TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm: (-[DragAndDropSimulator initWithWebViewFrame:configuration:]): (-[DragAndDropSimulator initWithWebView:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241553 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:55 AM Changeset in webkit [241554] by
-
- 2 edits in trunk/Source/WebKit
[iOS] Open sandbox for certain calls.
https://bugs.webkit.org/show_bug.cgi?id=194626
Reviewed by Brent Fulgham.
Reporting shows that certain calls needs to be allowed in the sandbox.
- Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
- 10:47 AM Changeset in webkit [241553] by
-
- 2 edits in trunk/Tools
Unreviewed, build fix after r241480
- TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm:
(-[DragAndDropSimulator initWithWebViewFrame:configuration:]):
(-[DragAndDropSimulator initWithWebView:]):
- 10:12 AM Changeset in webkit [241552] by
-
- 4 edits in trunk/Source/JavaScriptCore
generateUnlinkedCodeBlockForFunctions shouldn't need to create a FunctionExecutable just to get its source code
https://bugs.webkit.org/show_bug.cgi?id=194576
Reviewed by Saam Barati.
Extract a new function,
linkedSourceCode
from UnlinkedFunctionExecutable::link
and use it ingenerateUnlinkedCodeBlockForFunctions
instead.
- bytecode/UnlinkedFunctionExecutable.cpp:
(JSC::UnlinkedFunctionExecutable::linkedSourceCode const):
(JSC::UnlinkedFunctionExecutable::link):
- bytecode/UnlinkedFunctionExecutable.h:
- runtime/CodeCache.cpp:
(JSC::generateUnlinkedCodeBlockForFunctions):
- 10:12 AM Changeset in webkit [241551] by
-
- 2 edits in trunk/Source/WebCore/platform/gtk/po
[l10n] Updated Italian translation of WebKitGTK+
https://bugs.webkit.org/show_bug.cgi?id=194652
Patch by Milo Casagrande <milo@milo.name> on 2019-02-14
Rubber-stamped by Michael Catanzaro.
- it.po:
- 9:37 AM Changeset in webkit [241550] by
-
- 2 edits in trunk/Source/JavaScriptCore
CachedBitVector's size must be converted from bits to bytes
https://bugs.webkit.org/show_bug.cgi?id=194441
Reviewed by Saam Barati.
CachedBitVector used its size in bits for memcpy. That didn't cause any
issues when encoding, since the size in bits was also used in the allocation,
but would overflow the actual BitVector buffer when decoding.
- runtime/CachedTypes.cpp:
(JSC::CachedBitVector::encode):
(JSC::CachedBitVector::decode const):
- 9:27 AM Changeset in webkit [241549] by
-
- 4 edits in trunk
AX: ARIA Reflection was disabled in error
https://bugs.webkit.org/show_bug.cgi?id=194647
<rdar://problem/48068336>
Reviewed by Ryosuke Niwa.
Source/WebKit:
- Shared/WebPreferences.yaml:
Tools:
Remove test override now that this feature should be enabled by default.
- WebKitTestRunner/TestController.cpp:
(WTR::TestController::resetPreferencesToConsistentValues):
- 9:10 AM Changeset in webkit [241548] by
-
- 20 edits1 delete in trunk
Unreviewed, rolling out r241486.
https://bugs.webkit.org/show_bug.cgi?id=194655
causing API failures in builds (Requested by ShawnRoberts on
#webkit).
Reverted changeset:
"[Cocoa] Media elements will restart network buffering just
before suspending"
https://bugs.webkit.org/show_bug.cgi?id=193691
https://trac.webkit.org/changeset/241486
- 9:06 AM Changeset in webkit [241547] by
-
- 5 edits in trunk/Source
Web Inspector: don't include accessibility role in DOM.Node object payloads
https://bugs.webkit.org/show_bug.cgi?id=194623
<rdar://problem/36384037>
Reviewed by Devin Rousso.
Source/JavaScriptCore:
Remove property of DOM.Node that is no longer being sent.
- inspector/protocol/DOM.json:
Source/WebCore:
Accessibility properties are complicated to fetch at all the points where we want to build and push nodes immediately.
Turning on AX often indirectly causes style recalc and layout. This is bad because we are often building nodes in the
first place due to a DOM node tree update (i.e., NodeInserted).
It turns out that DOM.getAccessibilityPropertiesForNode is called every time we display
the computed role in the Elements Tab > Nodes Sidebar > Accessibility Section. So it is not
necessary to collect this information in a problematic way when initially pushing the node, as
it will be updated anyway.
No new tests, no change in behavior.
- inspector/agents/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::buildObjectForNode):
- 8:44 AM Changeset in webkit [241546] by
-
- 5 edits2 adds in trunk
[LFC][BFC][MarginCollapse] Replaced boxes don't collapse through their margins
https://bugs.webkit.org/show_bug.cgi?id=194622
Reviewed by Antti Koivisto.
Source/WebCore:
Ensure that block replaced boxes don't collapse through their vertical margins.
Test: fast/block/block-only/block-replaced-with-vertical-margins.html
- layout/blockformatting/BlockMarginCollapse.cpp:
(WebCore::Layout::BlockFormattingContext::MarginCollapse::marginsCollapseThrough):
- page/FrameViewLayoutContext.cpp:
(WebCore::layoutUsingFormattingContext):
Tools:
- LayoutReloaded/misc/LFC-passing-tests.txt:
LayoutTests:
- fast/block/block-only/block-replaced-with-vertical-margins-expected.html: Added.
- fast/block/block-only/block-replaced-with-vertical-margins.html: Added.
- 8:32 AM Changeset in webkit [241545] by
-
- 7 edits in trunk
[LFC] Shrink-to-fit-width should be constrained by min/max width
https://bugs.webkit.org/show_bug.cgi?id=194653
Reviewed by Antti Koivisto.
Source/WebCore:
Use the fixed value of min-width/max-width to constrain the computed preferred width.
- layout/FormattingContext.h:
- layout/FormattingContextGeometry.cpp:
(WebCore::Layout::FormattingContext::Geometry::constrainByMinMaxWidth):
- layout/blockformatting/BlockFormattingContextGeometry.cpp:
(WebCore::Layout::BlockFormattingContext::Geometry::intrinsicWidthConstraints):
- layout/inlineformatting/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthConstraints const):
Tools:
- LayoutReloaded/misc/LFC-passing-tests.txt:
- 7:51 AM Changeset in webkit [241544] by
-
- 2 edits in trunk/Source/WebKit
Do not add a caches to its engine if the salt cannot be initialized
https://bugs.webkit.org/show_bug.cgi?id=194604
Reviewed by Antti Koivisto.
This is a follow-up to https://bugs.webkit.org/show_bug.cgi?id=194588.
We should return early if initialize fails.
- NetworkProcess/cache/CacheStorageEngine.cpp:
(WebKit::CacheStorage::Engine::readCachesFromDisk):
- 4:57 AM Changeset in webkit [241543] by
-
- 1 copy in releases/WebKitGTK/webkit-2.23.90
WebKitGTK 2.23.90
- 4:57 AM Changeset in webkit [241542] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24
Unreviewed. Update OptionsGTK.cmake and NEWS for 2.23.90 release
.:
- Source/cmake/OptionsGTK.cmake: Bump version numbers
Source/WebKit:
- gtk/NEWS: Add release notes for 2.23.90.
- 4:57 AM Changeset in webkit [241541] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Unreviewed. Add missing symbols to webkitglib-symbols.map
Add symbols global in JSC and present in WebKit.
- webkitglib-symbols.map:
- 3:28 AM Changeset in webkit [241540] by
-
- 15 edits4 deletes in releases/WebKitGTK/webkit-2.24
[WPE][GTK][STABLE] Remove sandbox APIs from 2.24 branch
https://bugs.webkit.org/show_bug.cgi?id=194553
Patch by Michael Catanzaro <Michael Catanzaro> on 2019-02-14
Reviewed by Carlos Garcia Campos.
.:
- Source/cmake/OptionsGTK.cmake:
- Source/cmake/WebKitFeatures.cmake:
Source/WebKit:
- PlatformGTK.cmake:
- SourcesGTK.txt:
- SourcesWPE.txt:
- UIProcess/API/glib/WebKitWebContext.cpp:
(webkit_web_context_set_sandbox_enabled): Deleted.
(webkit_web_context_add_path_to_sandbox): Deleted.
(webkit_web_context_get_sandbox_enabled): Deleted.
- UIProcess/API/gtk/WebKitWebContext.h:
- UIProcess/API/gtk/docs/webkit2gtk-4.0-sections.txt:
- UIProcess/API/wpe/WebKitWebContext.h:
- UIProcess/API/wpe/docs/wpe-0.1-sections.txt:
- UIProcess/Launcher/glib/BubblewrapLauncher.cpp: Removed.
- UIProcess/Launcher/glib/BubblewrapLauncher.h: Removed.
- UIProcess/Launcher/glib/FlatpakLauncher.cpp: Removed.
- UIProcess/Launcher/glib/FlatpakLauncher.h: Removed.
- UIProcess/Launcher/glib/ProcessLauncherGLib.cpp:
(WebKit::ProcessLauncher::launchProcess):
(WebKit::isInsideFlatpak): Deleted.
- UIProcess/WebProcessPool.h:
- UIProcess/glib/WebProcessProxyGLib.cpp:
(WebKit::WebProcessProxy::platformGetLaunchOptions):
- 3:28 AM Changeset in webkit [241539] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241515 - [GTK] Use a scrolled window for script alerts text
https://bugs.webkit.org/show_bug.cgi?id=184875
Reviewed by Michael Catanzaro.
To ensure long text doesn't make the dialog bigger.
- UIProcess/API/gtk/WebKitScriptDialogImpl.cpp:
(webkitScriptDialogImplConstructed): Use PANGO_ELLIPSIZE_END for the title and add a scrolled window for the body.
(webkitScriptDialogImplSetText): Helper function to set the dialog body, ensuring the scrolled window fills the
dialog available size.
(webkitScriptDialogImplNew): It now receives the maximum size and uses webkitScriptDialogImplSetText().
- UIProcess/API/gtk/WebKitScriptDialogImpl.h:
- UIProcess/API/gtk/WebKitWebViewGtk.cpp:
(webkitWebViewScriptDialog): Pass the 80% of the web view size as the maximum size of script dialogs.
- 3:28 AM Changeset in webkit [241538] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24
Merge r241500 - Crash in WKBundleFrameGetParentFrame when called inside didRemoveFrameFromHierarchy
https://bugs.webkit.org/show_bug.cgi?id=194641
Reviewed by Geoffrey Garen.
Source/WebKit:
Fixed the bug by adding a null check to WebFrame::parentFrame.
- WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::parentFrame const):
Tools:
Added a call to WKBundleFrameGetParentFrame to an existing test for didRemoveFrameFromHierarchy
so that the test would fail without this fix.
- TestWebKitAPI/Tests/WebKit/DidRemoveFrameFromHiearchyInPageCache_Bundle.cpp:
(TestWebKitAPI::didRemoveFrameFromHierarchyCallback):
- 3:28 AM Changeset in webkit [241537] by
-
- 3 edits2 adds in releases/WebKitGTK/webkit-2.24
Merge r241499 - Crash in DOMTimer::fired
https://bugs.webkit.org/show_bug.cgi?id=194638
Reviewed by Brent Fulgham.
Source/WebCore:
This patch continues the saga of hunting down timer related crashes after r239814, r225985, r227934.
The crash was caused by the bug that we don't remove a DOMTimer from NestedTimersMap if a DOMTimer
is created & installed inside another DOMTimer's callback (via execute call in DOMTimer::fired).
Fixed the crash by using a Ref in NestedTimersMap. This will keep the timer alive until we exit
from DOMTimer::fired. Because DOMTimer::fired always calls stopTracking() which clears the map
we would not leak these DOM timers.
We could, alternatively, use WeakPtr in NestedTimersMap but that would unnecessarily increase the
size of DOMTimer for a very marginal benefit of DOMTimer objcets being deleted slightly earlier.
Deleting itself in DOMTimer's destructor involves more logic & house keeping in the timer code,
and is no longer the preferred approach when dealing with these classes of bugs in WebKit.
Test: fast/dom/timer-destruction-during-firing.html
- page/DOMTimer.cpp:
(WebCore::NestedTimersMap::add):
(WebCore::DOMTimer::install):
(WebCore::DOMTimer::fired):
LayoutTests:
Added a regression test. It needs debug assertions without the fix.
- fast/dom/timer-destruction-during-firing-expected.txt: Added.
- fast/dom/timer-destruction-during-firing.html: Added.
- 3:28 AM Changeset in webkit [241536] by
-
- 3 edits2 adds in releases/WebKitGTK/webkit-2.24
Merge r241497 - Web Inspector: Styles: valid values in style attributes are reported as unsupported property values
https://bugs.webkit.org/show_bug.cgi?id=194619
<rdar://problem/47917373>
Reviewed by Devin Rousso.
Source/WebInspectorUI:
Payload of inline styles may contain
range
that doesn't match
the actual text of the payload - it has an extra empty line at the end.
Mismatching ranges caused data corruption.
- UserInterface/Models/DOMNodeStyles.js:
(WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
LayoutTests:
- inspector/css/modify-inline-style-expected.txt: Added.
- inspector/css/modify-inline-style.html: Added.
- 3:28 AM Changeset in webkit [241535] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241495 - Web Inspector: Crash when inspecting an element that constantly changes visibility
https://bugs.webkit.org/show_bug.cgi?id=194632
<rdar://problem/48060258>
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-13
Reviewed by Matt Baker and Devin Rousso.
- inspector/agents/InspectorDOMAgent.h:
- inspector/agents/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::processAccessibilityChildren):
(WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
Don't use rvalue-references as that was taking ownership and deleting
the object we want to keep around. Instead simplify this to just use
references so no ref counting changes happen.
- 3:28 AM Changeset in webkit [241534] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241494 - AX: Crash in handleMenuOpen
https://bugs.webkit.org/show_bug.cgi?id=194627
Reviewed by Zalan Bujtas.
Tests run under libGuardMalloc will cause crashes.
This list of objects is a Node list, not an Element list, so we were
not removing some nodes when they were being deallocated.
- accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::remove):
- 3:28 AM Changeset in webkit [241533] by
-
- 8 edits in releases/WebKitGTK/webkit-2.24/Source
Merge r241493 - We should only make rope strings when concatenating strings long enough.
https://bugs.webkit.org/show_bug.cgi?id=194465
Reviewed by Mark Lam.
Source/JavaScriptCore:
This patch stops us from allocating a rope string if the resulting
rope would be smaller than the size of the JSRopeString object we
would need to allocate.
This patch also adds paths so that we don't unnecessarily allocate
JSString cells for primitives we are going to concatenate with a
string anyway.
The important change from the previous one is that we do not apply
the above rule to JSRopeStrings generated by JSStrings. If we convert
it to JSString, comparison of memory consumption becomes the following,
because JSRopeString does not have StringImpl until it is resolved.
sizeof(JSRopeString) v.s. sizeof(JSString) + sizeof(StringImpl) + content
Since sizeof(JSString) + sizeof(StringImpl) is larger than sizeof(JSRopeString),
resolving eagerly increases memory footprint. The point is that we need to
account newly created JSString and JSRopeString from the operands. This is the
reason why this patch adds different thresholds for each jsString functions.
This patch also avoids concatenation for ropes conservatively. Many ropes are
temporary cells. So we do not resolve eagerly if one of operands is already a
rope.
In CLI execution, this change is performance neutral in JetStream2 (run 6 times, 1 for warming up and average in latter 5.).
Before: 159.3778
After: 160.72340000000003
- dfg/DFGOperations.cpp:
- runtime/CommonSlowPaths.cpp:
(JSC::SLOW_PATH_DECL):
- runtime/JSString.h:
(JSC::JSString::isRope const):
- runtime/Operations.cpp:
(JSC::jsAddSlowCase):
- runtime/Operations.h:
(JSC::jsString):
(JSC::jsAddNonNumber):
(JSC::jsAdd):
Source/WTF:
- wtf/text/StringImpl.h:
(WTF::StringImpl::headerSize):
- 3:28 AM Changeset in webkit [241532] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24/LayoutTests
Merge r241491 - Unreviewed GTK test gardening
https://bugs.webkit.org/show_bug.cgi?id=194631
- platform/gtk/TestExpectations:
- platform/gtk/editing/pasteboard/smart-paste-007-expected.txt:
- platform/gtk/editing/pasteboard/smart-paste-008-expected.txt:
- 3:28 AM Changeset in webkit [241531] by
-
- 4 edits2 adds in releases/WebKitGTK/webkit-2.24
Merge r241484 - Entering fullscreen inside a shadow root will not set fullscreen pseudoclasses outside of root
https://bugs.webkit.org/show_bug.cgi?id=194516
<rdar://problem/44678353>
Reviewed by Antoine Quint.
Source/WebCore:
Test: fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor.html
When walking up the element ancestor chain, use parentElementInComposedTree() to
walk past the shadow root boundary.
- dom/Element.cpp:
(WebCore::parentCrossingFrameBoundaries):
LayoutTests:
- fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor-expected.txt: Added.
- fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor.html: Added.
- platform/ios-wk2/TestExpectations:
- 3:27 AM Changeset in webkit [241530] by
-
- 30 edits4 adds in releases/WebKitGTK/webkit-2.24
Merge r241480 - Further restricting webarchive loads
https://bugs.webkit.org/show_bug.cgi?id=194567
<rdar://problem/47610130>
Reviewed by Youenn Fablet.
Source/WebCore:
This patch futher restricts main frame webarchive loads to the followings:
1) loaded by clients;
2) loaded by drag;
3) reloaded from any of the previous two.
It moves setAlwaysAllowLocalWebarchive, which is used for testing only, from Document
to FrameLoader such that the option is remembered during redirections.
Covered by API tests.
- dom/Document.h:
(WebCore::Document::setAlwaysAllowLocalWebarchive): Deleted.
(WebCore::Document::alwaysAllowLocalWebarchive const): Deleted.
- loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::disallowWebArchive const):
- loader/DocumentLoader.h:
(WebCore::DocumentLoader::setAllowsWebArchiveForMainFrame):
(WebCore::DocumentLoader::allowsWebArchiveForMainFrame):
- loader/FrameLoadRequest.h:
(WebCore::FrameLoadRequest::setIsRequestFromClientOrUserInput):
(WebCore::FrameLoadRequest::isRequestFromClientOrUserInput):
- loader/FrameLoader.cpp:
(WebCore::FrameLoader::load):
(WebCore::FrameLoader::reload):
- loader/FrameLoader.h:
(WebCore::FrameLoader::setAlwaysAllowLocalWebarchive):
(WebCore::FrameLoader::alwaysAllowLocalWebarchive const):
- page/DragController.cpp:
(WebCore::DragController::performDragOperation):
- testing/Internals.cpp:
(WebCore::Internals::setAlwaysAllowLocalWebarchive const):
- testing/Internals.h:
- testing/Internals.idl:
Source/WebKit:
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::loadRequest):
Set a flag to indicate a load is started from clients.
Tools:
Besides adding API tests, this patch also enhances DragAndDropSimulator to allow
navigations on drop.
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/mac/LoadWebArchive.mm: Added.
(-[TestLoadWebArchiveNavigationDelegate webView:didFinishNavigation:]):
(-[TestLoadWebArchiveNavigationDelegate webView:didFailProvisionalNavigation:withError:]):
(-[TestLoadWebArchiveNavigationDelegate webView:createWebViewWithConfiguration:forNavigationAction:windowFeatures:]):
(TestWebKitAPI::TEST):
- TestWebKitAPI/Tests/mac/helloworld.webarchive: Added.
- TestWebKitAPI/Tests/mac/load-web-archive-1.html: Added.
- TestWebKitAPI/Tests/mac/load-web-archive-2.html: Added.
- TestWebKitAPI/cocoa/DragAndDropSimulator.h:
- TestWebKitAPI/mac/DragAndDropSimulatorMac.mm:
(-[DragAndDropSimulator initWithWebViewFrame:configuration:]):
(-[DragAndDropSimulator _webView:dragDestinationActionMaskForDraggingInfo:]):
LayoutTests:
- platform/mac/fast/loader/webarchive-encoding-respected.html:
- webarchive/loading/cache-expired-subresource.html:
- webarchive/loading/javascript-url-iframe-crash.html:
- webarchive/loading/mainresource-null-mimetype-crash.html:
- webarchive/loading/missing-data.html:
- webarchive/loading/object.html:
- webarchive/loading/test-loading-archive-subresource-null-mimetype.html:
- webarchive/loading/test-loading-archive-subresource.html:
- webarchive/loading/test-loading-archive.html:
- webarchive/loading/test-loading-top-archive.html:
- webarchive/loading/video-in-webarchive.html:
- 3:27 AM Changeset in webkit [241529] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
Merge r241475 - AirIRGenerator::addSwitch switch patchpoint needs to model clobbering the scratch register
https://bugs.webkit.org/show_bug.cgi?id=194610
Reviewed by Michael Saboff.
BinarySwitch might use the scratch register. We must model the
effects of that properly. This is already caught by our br-table
tests on arm64.
- wasm/WasmAirIRGenerator.cpp:
(JSC::Wasm::AirIRGenerator::addSwitch):
- 3:27 AM Changeset in webkit [241528] by
-
- 3 edits1 move1 delete in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241474 - [WPE][GTK] Merge WebProcessPoolWPE.cpp and WebProcessPoolGtk.cpp
https://bugs.webkit.org/show_bug.cgi?id=194551
Reviewed by Carlos Garcia Campos.
- SourcesGTK.txt:
- SourcesWPE.txt:
- UIProcess/glib/WebProcessPoolGLib.cpp: Renamed from Source/WebKit/UIProcess/gtk/WebProcessPoolGtk.cpp.
(WebKit::initializeRemoteInspectorServer):
(WebKit::memoryPressureMonitorDisabled):
(WebKit::WebProcessPool::platformInitialize):
(WebKit::WebProcessPool::platformInitializeWebProcess):
(WebKit::WebProcessPool::platformInvalidateContext):
(WebKit::WebProcessPool::platformResolvePathsForSandboxExtensions):
- UIProcess/wpe/WebProcessPoolWPE.cpp: Removed.
- 3:27 AM Changeset in webkit [241527] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241472 - Unreviewed, fix unused variable warnings after r241148/r241251
https://bugs.webkit.org/show_bug.cgi?id=194348
<rdar://problem/47566449>
- Modules/mediasource/SourceBuffer.cpp:
(WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError):
(WebCore::SourceBuffer::evictCodedFrames):
(WebCore::SourceBuffer::provideMediaData):
- 3:27 AM Changeset in webkit [241526] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241468 - REGRESSION: [ Mac Debug WK2 ] Layout Test storage/indexeddb/key-type-infinity-private.html is a flaky crash
https://bugs.webkit.org/show_bug.cgi?id=194413
<rdar://problem/47897254>
Reviewed by Brady Eidson.
IDB clients expected transaction operations to be executed in order, but in
UniqueIDBDatabase::immediateCloseForUserDelete, callbacks in callback map were errored out randomly.
This patch added a callback queue to UniqueIDBDatabase to make sure callbacks will be called in the same order
as IDB Server receives the request.
- Modules/indexeddb/server/UniqueIDBDatabase.cpp:
(WebCore::IDBServer::UniqueIDBDatabase::storeCallbackOrFireError):
(WebCore::IDBServer::UniqueIDBDatabase::immediateCloseForUserDelete):
(WebCore::IDBServer::UniqueIDBDatabase::performErrorCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performKeyDataCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performGetResultCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performGetAllResultsCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performCountCallback):
(WebCore::IDBServer::UniqueIDBDatabase::forgetErrorCallback):
- Modules/indexeddb/server/UniqueIDBDatabase.h:
- 3:27 AM Changeset in webkit [241525] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241453 - Fix -Wformat warning from r241401
https://bugs.webkit.org/show_bug.cgi?id=194584
<rdar://problem/47761293>
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::setActivityState):
- 3:27 AM Changeset in webkit [241524] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241450 - Revert r240434
https://bugs.webkit.org/show_bug.cgi?id=194600
<rdar://problem/48044566>
Reviewed by Brent Fulgham.
- html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::setVolume):
(WebCore::HTMLMediaElement::mediaPlayerVolumeChanged):
(WebCore::HTMLMediaElement::updateVolume):
- platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::setVolume):
- 3:27 AM Changeset in webkit [241523] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
Merge r241449 - Create a randomized free list for new StructureIDs on StructureIDTable resize.
https://bugs.webkit.org/show_bug.cgi?id=194566
<rdar://problem/47975502>
Reviewed by Michael Saboff.
Also isolate 32-bit implementation of StructureIDTable out more so the 64-bit
implementation is a little easier to read.
This patch appears to be perf neutral on JetStream2 (as run from the command line).
- runtime/StructureIDTable.cpp:
(JSC::StructureIDTable::StructureIDTable):
(JSC::StructureIDTable::makeFreeListFromRange):
(JSC::StructureIDTable::resize):
(JSC::StructureIDTable::allocateID):
(JSC::StructureIDTable::deallocateID):
- runtime/StructureIDTable.h:
(JSC::StructureIDTable::get):
(JSC::StructureIDTable::deallocateID):
(JSC::StructureIDTable::allocateID):
(JSC::StructureIDTable::flushOldTables):
- 3:27 AM Changeset in webkit [241522] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241448 - Crash in WebKit::CacheStorage::Engine::cachesRootPath
https://bugs.webkit.org/show_bug.cgi?id=194588
<rdar://problem/46363997>
Reviewed by Youenn Fablet.
- NetworkProcess/cache/CacheStorageEngine.cpp:
(WebKit::CacheStorage::Engine::cachesRootPath):
Salt may have not been initialized yet when the Engine is destroyed.
- 3:26 AM Changeset in webkit [241521] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
Merge r241447 - VariableLengthObject::allocate<T> should initialize objects
https://bugs.webkit.org/show_bug.cgi?id=194534
Reviewed by Michael Saboff.
buffer()
should not be called for empty VariableLengthObjects, but
these cases were not being caught due to the objects not being properly
initialized. Fix it so that allocate calls the constructor and fix the
assertion failues.
- runtime/CachedTypes.cpp:
(JSC::CachedObject::operator new):
(JSC::VariableLengthObject::allocate):
(JSC::CachedVector::encode):
(JSC::CachedVector::decode const):
(JSC::CachedUniquedStringImpl::decode const):
(JSC::CachedBitVector::encode):
(JSC::CachedBitVector::decode const):
(JSC::CachedArray::encode):
(JSC::CachedArray::decode const):
(JSC::CachedImmutableButterfly::CachedImmutableButterfly):
(JSC::CachedBigInt::decode const):
- 3:26 AM Changeset in webkit [241520] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
Merge r241442 - CodeBlocks read from disk should not be re-written
https://bugs.webkit.org/show_bug.cgi?id=194535
Reviewed by Michael Saboff.
Keep track of which CodeBlocks have been read from disk or have already
been serialized in CodeCache.
- runtime/CodeCache.cpp:
(JSC::CodeCache::write):
- runtime/CodeCache.h:
(JSC::SourceCodeValue::SourceCodeValue):
(JSC::CodeCacheMap::fetchFromDiskImpl):
- 3:26 AM Changeset in webkit [241519] by
-
- 13 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241441 - Remove legacy sync messaging in some IPC code
https://bugs.webkit.org/show_bug.cgi?id=194561
Reviewed by Geoffrey Garen.
Changing some LegacySync messages to Delayed messages. We should probably rename Delayed to Sync.
There are too many ways to send messages. Let's work to get rid of the old one.
- NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::setAllowsAnySSLCertificateForWebSocket):
(WebKit::NetworkProcess::processWillSuspendImminently):
- NetworkProcess/NetworkProcess.h:
- NetworkProcess/NetworkProcess.messages.in:
- PluginProcess/PluginControllerProxy.cpp:
(WebKit::PluginControllerProxy::handleWheelEvent):
(WebKit::PluginControllerProxy::handleMouseEnterEvent):
(WebKit::PluginControllerProxy::handleMouseLeaveEvent):
(WebKit::PluginControllerProxy::handleKeyboardEvent):
(WebKit::PluginControllerProxy::handleEditingCommand):
(WebKit::PluginControllerProxy::isEditingCommandEnabled):
(WebKit::PluginControllerProxy::handlesPageScaleFactor):
(WebKit::PluginControllerProxy::requiresUnifiedScaleFactor):
(WebKit::PluginControllerProxy::paintEntirePlugin):
(WebKit::PluginControllerProxy::supportsSnapshotting):
(WebKit::PluginControllerProxy::snapshot):
(WebKit::PluginControllerProxy::getPluginScriptableNPObject):
(WebKit::PluginControllerProxy::getFormValue):
- PluginProcess/PluginControllerProxy.h:
- PluginProcess/PluginControllerProxy.messages.in:
- Shared/Plugins/NPObjectMessageReceiver.cpp:
(WebKit::NPObjectMessageReceiver::deallocate):
(WebKit::NPObjectMessageReceiver::hasMethod):
(WebKit::NPObjectMessageReceiver::invoke):
(WebKit::NPObjectMessageReceiver::invokeDefault):
(WebKit::NPObjectMessageReceiver::hasProperty):
(WebKit::NPObjectMessageReceiver::getProperty):
(WebKit::NPObjectMessageReceiver::setProperty):
(WebKit::NPObjectMessageReceiver::removeProperty):
(WebKit::NPObjectMessageReceiver::enumerate):
(WebKit::NPObjectMessageReceiver::construct):
- Shared/Plugins/NPObjectMessageReceiver.h:
- Shared/Plugins/NPObjectMessageReceiver.messages.in:
- UIProcess/mac/SecItemShimProxy.cpp:
(WebKit::SecItemShimProxy::secItemRequest):
- UIProcess/mac/SecItemShimProxy.h:
- UIProcess/mac/SecItemShimProxy.messages.in:
- 3:26 AM Changeset in webkit [241518] by
-
- 3 edits6 adds in releases/WebKitGTK/webkit-2.24/LayoutTests
Merge r241436 - Add two regression tests for reference cycle in IndexedDB
https://bugs.webkit.org/show_bug.cgi?id=194527
Reviewed by Geoffrey Garen.
- fast/dom/reference-cycle-leaks.html:
- platform/win/TestExpectations:
The added tests are failing on win bots for unknown reasons, propably related to webkit.org/b/193540. Skip them
on win.
- storage/indexeddb/resources/result-request-cycle.js: Added.
(prepareDatabase):
- storage/indexeddb/resources/value-cursor-cycle.js: Added.
(prepareDatabase):
(onOpen.cursorRequest.onsuccess):
- storage/indexeddb/result-request-cycle-expected.txt: Added.
- storage/indexeddb/result-request-cycle.html: Added.
- storage/indexeddb/value-cursor-cycle-expected.txt: Added.
- storage/indexeddb/value-cursor-cycle.html: Added.
- 3:26 AM Changeset in webkit [241517] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
Merge r241431 - SourceCode should be copied when generating bytecode for functions
https://bugs.webkit.org/show_bug.cgi?id=194536
Reviewed by Saam Barati.
The FunctionExecutable might be collected while generating the bytecode
for nested functions, in which case the SourceCode reference would no
longer be valid.
- runtime/CodeCache.cpp:
(JSC::generateUnlinkedCodeBlockForFunctions):
- 3:26 AM Changeset in webkit [241516] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/LayoutTests
Merge r241430 - [GTK][WPE] Don't use DumpJSConsoleLogInStdErr expectation in platform TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=194587
Unreviewed gardening.
- platform/gtk/TestExpectations: Removed DumpJSConsoleLogInStdErr markers which are marked in top TestExpectations.
- platform/wpe/TestExpectations: Ditto.
- 2:11 AM Changeset in webkit [241515] by
-
- 4 edits in trunk/Source/WebKit
[GTK] Use a scrolled window for script alerts text
https://bugs.webkit.org/show_bug.cgi?id=184875
Reviewed by Michael Catanzaro.
To ensure long text doesn't make the dialog bigger.
- UIProcess/API/gtk/WebKitScriptDialogImpl.cpp:
(webkitScriptDialogImplConstructed): Use PANGO_ELLIPSIZE_END for the title and add a scrolled window for the body.
(webkitScriptDialogImplSetText): Helper function to set the dialog body, ensuring the scrolled window fills the
dialog available size.
(webkitScriptDialogImplNew): It now receives the maximum size and uses webkitScriptDialogImplSetText().
- UIProcess/API/gtk/WebKitScriptDialogImpl.h:
- UIProcess/API/gtk/WebKitWebViewGtk.cpp:
(webkitWebViewScriptDialog): Pass the 80% of the web view size as the maximum size of script dialogs.
- 12:35 AM Changeset in webkit [241514] by
-
- 3 edits in branches/safari-607-branch/Source/WebKit
Apply patch. rdar://problem/47673836
- 12:35 AM Changeset in webkit [241513] by
-
- 4 edits in branches/safari-607-branch
Cherry-pick r241500. rdar://problem/48065631
Crash in WKBundleFrameGetParentFrame when called inside didRemoveFrameFromHierarchy
https://bugs.webkit.org/show_bug.cgi?id=194641
Reviewed by Geoffrey Garen.
Source/WebKit:
Fixed the bug by adding a null check to WebFrame::parentFrame.
- WebProcess/WebPage/WebFrame.cpp: (WebKit::WebFrame::parentFrame const):
Tools:
Added a call to WKBundleFrameGetParentFrame to an existing test for didRemoveFrameFromHierarchy
so that the test would fail without this fix.
- TestWebKitAPI/Tests/WebKit/DidRemoveFrameFromHiearchyInPageCache_Bundle.cpp: (TestWebKitAPI::didRemoveFrameFromHierarchyCallback):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241500 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241512] by
-
- 3 edits2 adds in branches/safari-607-branch
Cherry-pick r241499. rdar://problem/48065634
Crash in DOMTimer::fired
https://bugs.webkit.org/show_bug.cgi?id=194638
Reviewed by Brent Fulgham.
Source/WebCore:
This patch continues the saga of hunting down timer related crashes after r239814, r225985, r227934.
The crash was caused by the bug that we don't remove a DOMTimer from NestedTimersMap if a DOMTimer
is created & installed inside another DOMTimer's callback (via execute call in DOMTimer::fired).
Fixed the crash by using a Ref in NestedTimersMap. This will keep the timer alive until we exit
from DOMTimer::fired. Because DOMTimer::fired always calls stopTracking() which clears the map
we would not leak these DOM timers.
We could, alternatively, use WeakPtr in NestedTimersMap but that would unnecessarily increase the
size of DOMTimer for a very marginal benefit of DOMTimer objcets being deleted slightly earlier.
Deleting itself in DOMTimer's destructor involves more logic & house keeping in the timer code,
and is no longer the preferred approach when dealing with these classes of bugs in WebKit.
Test: fast/dom/timer-destruction-during-firing.html
- page/DOMTimer.cpp: (WebCore::NestedTimersMap::add): (WebCore::DOMTimer::install): (WebCore::DOMTimer::fired):
LayoutTests:
Added a regression test. It needs debug assertions without the fix.
- fast/dom/timer-destruction-during-firing-expected.txt: Added.
- fast/dom/timer-destruction-during-firing.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241499 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241511] by
-
- 2 edits in branches/safari-607-branch/Source/WebCore
Cherry-pick r241494. rdar://problem/48065624
AX: Crash in handleMenuOpen
https://bugs.webkit.org/show_bug.cgi?id=194627
Reviewed by Zalan Bujtas.
Tests run under libGuardMalloc will cause crashes.
This list of objects is a Node list, not an Element list, so we were
not removing some nodes when they were being deallocated.
- accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::remove):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241494 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241510] by
-
- 4 edits2 adds in branches/safari-607-branch
Cherry-pick r241484. rdar://problem/48065620
Entering fullscreen inside a shadow root will not set fullscreen pseudoclasses outside of root
https://bugs.webkit.org/show_bug.cgi?id=194516
<rdar://problem/44678353>
Reviewed by Antoine Quint.
Source/WebCore:
Test: fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor.html
When walking up the element ancestor chain, use parentElementInComposedTree() to
walk past the shadow root boundary.
- dom/Element.cpp: (WebCore::parentCrossingFrameBoundaries):
LayoutTests:
- fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor-expected.txt: Added.
- fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor.html: Added.
- platform/ios-wk2/TestExpectations:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241484 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241509] by
-
- 3 edits4 adds in branches/safari-607-branch
Cherry-pick r241481. rdar://problem/48065616
Encrypted PDFs inside <embed> or <object> crash the Web Content process
https://bugs.webkit.org/show_bug.cgi?id=194605
<rdar://problem/19894818>
Reviewed by Andy Estes.
Source/WebKit:
- WebProcess/Plugins/PDF/PDFPlugin.mm: (WebKit::PDFPlugin::createPasswordEntryForm): Don't try to create a password form field if we can't make form fields.
This means you will be left with a useless embedded PDF, but at least
the Web Content process won't crash.
We'll need to find an alternative implementation of PDF embedded form
fields that is compatible with <embed> and <object> if we want to support
this. Currently we piggy-back off the fact that we can just insert
<input>s into the PluginDocument's DOM, but we can't do that if there
is no PluginDocument, just a main document, like in the <embed> case.
LayoutTests:
- fast/replaced/encrypted-pdf-as-object-and-embed-expected.txt: Added.
- fast/replaced/encrypted-pdf-as-object-and-embed.html: Added.
- fast/replaced/resources/encrypted-image.pdf: Added. Add a test ensuring that we don't crash with encrypted PDF in <object> or <embed>.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241481 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241508] by
-
- 30 edits4 adds in branches/safari-607-branch
Cherry-pick r241480. rdar://problem/48065618
Further restricting webarchive loads
https://bugs.webkit.org/show_bug.cgi?id=194567
<rdar://problem/47610130>
Reviewed by Youenn Fablet.
Source/WebCore:
This patch futher restricts main frame webarchive loads to the followings:
1) loaded by clients;
2) loaded by drag;
3) reloaded from any of the previous two.
It moves setAlwaysAllowLocalWebarchive, which is used for testing only, from Document
to FrameLoader such that the option is remembered during redirections.
Covered by API tests.
- dom/Document.h: (WebCore::Document::setAlwaysAllowLocalWebarchive): Deleted. (WebCore::Document::alwaysAllowLocalWebarchive const): Deleted.
- loader/DocumentLoader.cpp: (WebCore::DocumentLoader::disallowWebArchive const):
- loader/DocumentLoader.h: (WebCore::DocumentLoader::setAllowsWebArchiveForMainFrame): (WebCore::DocumentLoader::allowsWebArchiveForMainFrame):
- loader/FrameLoadRequest.h: (WebCore::FrameLoadRequest::setIsRequestFromClientOrUserInput): (WebCore::FrameLoadRequest::isRequestFromClientOrUserInput):
- loader/FrameLoader.cpp: (WebCore::FrameLoader::load): (WebCore::FrameLoader::reload):
- loader/FrameLoader.h: (WebCore::FrameLoader::setAlwaysAllowLocalWebarchive): (WebCore::FrameLoader::alwaysAllowLocalWebarchive const):
- page/DragController.cpp: (WebCore::DragController::performDragOperation):
- testing/Internals.cpp: (WebCore::Internals::setAlwaysAllowLocalWebarchive const):
- testing/Internals.h:
- testing/Internals.idl:
Source/WebKit:
- WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::loadRequest): Set a flag to indicate a load is started from clients.
Tools:
Besides adding API tests, this patch also enhances DragAndDropSimulator to allow
navigations on drop.
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/mac/LoadWebArchive.mm: Added. (-[TestLoadWebArchiveNavigationDelegate webView:didFinishNavigation:]): (-[TestLoadWebArchiveNavigationDelegate webView:didFailProvisionalNavigation:withError:]): (-[TestLoadWebArchiveNavigationDelegate webView:createWebViewWithConfiguration:forNavigationAction:windowFeatures:]): (TestWebKitAPI::TEST):
- TestWebKitAPI/Tests/mac/helloworld.webarchive: Added.
- TestWebKitAPI/Tests/mac/load-web-archive-1.html: Added.
- TestWebKitAPI/Tests/mac/load-web-archive-2.html: Added.
- TestWebKitAPI/cocoa/DragAndDropSimulator.h:
- TestWebKitAPI/mac/DragAndDropSimulatorMac.mm: (-[DragAndDropSimulator initWithWebViewFrame:configuration:]): (-[DragAndDropSimulator _webView:dragDestinationActionMaskForDraggingInfo:]):
LayoutTests:
- platform/mac/fast/loader/webarchive-encoding-respected.html:
- webarchive/loading/cache-expired-subresource.html:
- webarchive/loading/javascript-url-iframe-crash.html:
- webarchive/loading/mainresource-null-mimetype-crash.html:
- webarchive/loading/missing-data.html:
- webarchive/loading/object.html:
- webarchive/loading/test-loading-archive-subresource-null-mimetype.html:
- webarchive/loading/test-loading-archive-subresource.html:
- webarchive/loading/test-loading-archive.html:
- webarchive/loading/test-loading-top-archive.html:
- webarchive/loading/video-in-webarchive.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241480 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241507] by
-
- 2 edits in branches/safari-607-branch/Source/WebCore
Cherry-pick r241479. rdar://problem/48065642
Null-deref crash at SourceBufferPrivateAVFObjC::outputObscuredDueToInsufficientExternalProtectionChanged()
https://bugs.webkit.org/show_bug.cgi?id=194613
<rdar://problem/48023912>
Reviewed by Eric Carlson.
- platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: (WebCore::SourceBufferPrivateAVFObjC::outputObscuredDueToInsufficientExternalProtectionChanged):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241479 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241506] by
-
- 2 edits in branches/safari-607-branch/Source/WebKit
Cherry-pick r241453. rdar://problem/48065612
Fix -Wformat warning from r241401
https://bugs.webkit.org/show_bug.cgi?id=194584
<rdar://problem/47761293>
- WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::setActivityState):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241453 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241505] by
-
- 2 edits in branches/safari-607-branch/Source/WebKit
Cherry-pick r241448. rdar://problem/48065637
Crash in WebKit::CacheStorage::Engine::cachesRootPath
https://bugs.webkit.org/show_bug.cgi?id=194588
<rdar://problem/46363997>
Reviewed by Youenn Fablet.
- NetworkProcess/cache/CacheStorageEngine.cpp: (WebKit::CacheStorage::Engine::cachesRootPath):
Salt may have not been initialized yet when the Engine is destroyed.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241448 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241504] by
-
- 4 edits in branches/safari-607-branch/Source/WebCore
Cherry-pick r241437. rdar://problem/48065626
[Cocoa] Switch to CVPixelBufferGetBytesPerRow() for calculating CVPixelBuffer base address size.
https://bugs.webkit.org/show_bug.cgi?id=194580
<rdar://problem/42727739>
Reviewed by Eric Carlson.
- platform/cocoa/CoreVideoSoftLink.cpp:
- platform/cocoa/CoreVideoSoftLink.h:
- platform/graphics/cv/PixelBufferConformerCV.cpp: (WebCore::CVPixelBufferGetBytePointerCallback): (WebCore::PixelBufferConformerCV::createImageFromPixelBuffer):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241437 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241503] by
-
- 2 edits in branches/safari-607-branch/Source/WebKit
Cherry-pick r241401. rdar://problem/48065612
Crash in Page::setActivityState because m_page is null
https://bugs.webkit.org/show_bug.cgi?id=194584
Reviewed by Antti Koivisto.
Add a null check to avoid the crash. Also add a debug assertion to help diagnose this in the future.
- WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::setActivityState):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241401 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241502] by
-
- 2 edits in branches/safari-607-branch/Source/WebKit
Cherry-pick r241349. rdar://problem/48065639
Null deref in userInterfaceLayoutDirection under ViewGestureController::handleSwipeGesture
https://bugs.webkit.org/show_bug.cgi?id=194569
<rdar://problem/46711049>
Reviewed by Wenson Hsieh.
- UIProcess/mac/ViewGestureControllerMac.mm: (WebKit::ViewGestureController::handleSwipeGesture): It is conceivable that we could get here if the client closes the page e.g. in the callback from willEndSwipeGesture. We already guarded against this ... one line too late! Rearrange the lines so we don't call into WebPageProxy at all if we don't have a drawing area (which is a strict subset of the time that isValid would return true). This is a speculative fix, since I can no longer reproduce the crash on demand.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241349 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 12:34 AM Changeset in webkit [241501] by
-
- 6 edits in branches/safari-607-branch
Cherry-pick r241336. rdar://problem/48065621
Regression(PSON) MESSAGE_CHECK() hit under WebPageProxy::didFailProvisionalLoadForFrameShared()
https://bugs.webkit.org/show_bug.cgi?id=194568
<rdar://problem/47944490>
Reviewed by Ryosuke Niwa.
Source/WebKit:
When the provisional process crashes, it is unsafe to call ProvisionalPageProxy::cancel() because
the WebProcessProxy clears its frame map as soon as the process crashes. Calling cancel() after
that would call WebPageProxy::didFailProvisionalLoadForFrameShared(), which would try to look up
the frame by ID and MESSAGE_CHECK() that the frame is not null. We would fail this check since
the frame has been removed from the WebProcessProxy at this point.
- UIProcess/API/Cocoa/WKWebView.mm: (-[WKWebView _provisionalWebProcessIdentifier]):
- UIProcess/API/Cocoa/WKWebViewPrivate.h:
- UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::didFailProvisionalLoadForFrameShared): (WebKit::WebPageProxy::provisionalProcessDidTerminate):
Tools:
Add API test coverage.
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm: (-[PSONNavigationDelegate webView:didStartProvisionalNavigation:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241336 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Feb 13, 2019:
- 10:47 PM Changeset in webkit [241500] by
-
- 4 edits in trunk
Crash in WKBundleFrameGetParentFrame when called inside didRemoveFrameFromHierarchy
https://bugs.webkit.org/show_bug.cgi?id=194641
Reviewed by Geoffrey Garen.
Source/WebKit:
Fixed the bug by adding a null check to WebFrame::parentFrame.
- WebProcess/WebPage/WebFrame.cpp:
(WebKit::WebFrame::parentFrame const):
Tools:
Added a call to WKBundleFrameGetParentFrame to an existing test for didRemoveFrameFromHierarchy
so that the test would fail without this fix.
- TestWebKitAPI/Tests/WebKit/DidRemoveFrameFromHiearchyInPageCache_Bundle.cpp:
(TestWebKitAPI::didRemoveFrameFromHierarchyCallback):
- 10:43 PM Changeset in webkit [241499] by
-
- 3 edits2 adds in trunk
Crash in DOMTimer::fired
https://bugs.webkit.org/show_bug.cgi?id=194638
Reviewed by Brent Fulgham.
Source/WebCore:
This patch continues the saga of hunting down timer related crashes after r239814, r225985, r227934.
The crash was caused by the bug that we don't remove a DOMTimer from NestedTimersMap if a DOMTimer
is created & installed inside another DOMTimer's callback (via execute call in DOMTimer::fired).
Fixed the crash by using a Ref in NestedTimersMap. This will keep the timer alive until we exit
from DOMTimer::fired. Because DOMTimer::fired always calls stopTracking() which clears the map
we would not leak these DOM timers.
We could, alternatively, use WeakPtr in NestedTimersMap but that would unnecessarily increase the
size of DOMTimer for a very marginal benefit of DOMTimer objcets being deleted slightly earlier.
Deleting itself in DOMTimer's destructor involves more logic & house keeping in the timer code,
and is no longer the preferred approach when dealing with these classes of bugs in WebKit.
Test: fast/dom/timer-destruction-during-firing.html
- page/DOMTimer.cpp:
(WebCore::NestedTimersMap::add):
(WebCore::DOMTimer::install):
(WebCore::DOMTimer::fired):
LayoutTests:
Added a regression test. It needs debug assertions without the fix.
- fast/dom/timer-destruction-during-firing-expected.txt: Added.
- fast/dom/timer-destruction-during-firing.html: Added.
- 9:33 PM Changeset in webkit [241498] by
-
- 2 edits in trunk/Source/WebKit
Allow some deprecations in WKDrawingView.
https://bugs.webkit.org/show_bug.cgi?id=194636
Reviewed by Wenson Hsieh.
- UIProcess/ios/WKDrawingView.mm:
(-[WKDrawingView PNGRepresentation]):
(-[WKDrawingView loadDrawingFromPNGRepresentation:]):
(-[WKDrawingView _canvasViewWillBeginDrawing:]):
(-[WKDrawingView didChangeInk:]):
- 9:32 PM Changeset in webkit [241497] by
-
- 3 edits2 adds in trunk
Web Inspector: Styles: valid values in style attributes are reported as unsupported property values
https://bugs.webkit.org/show_bug.cgi?id=194619
<rdar://problem/47917373>
Reviewed by Devin Rousso.
Source/WebInspectorUI:
Payload of inline styles may contain
range
that doesn't match
the actual text of the payload - it has an extra empty line at the end.
Mismatching ranges caused data corruption.
- UserInterface/Models/DOMNodeStyles.js:
(WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
LayoutTests:
- inspector/css/modify-inline-style-expected.txt: Added.
- inspector/css/modify-inline-style.html: Added.
- 7:47 PM Changeset in webkit [241496] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: Update combined and minified copyright header for 2018-2019
https://bugs.webkit.org/show_bug.cgi?id=194635
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-13
Reviewed by Devin Rousso.
- Scripts/copy-user-interface-resources.pl:
- 7:38 PM Changeset in webkit [241495] by
-
- 3 edits in trunk/Source/WebCore
Web Inspector: Crash when inspecting an element that constantly changes visibility
https://bugs.webkit.org/show_bug.cgi?id=194632
<rdar://problem/48060258>
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-13
Reviewed by Matt Baker and Devin Rousso.
- inspector/agents/InspectorDOMAgent.h:
- inspector/agents/InspectorDOMAgent.cpp:
(WebCore::InspectorDOMAgent::processAccessibilityChildren):
(WebCore::InspectorDOMAgent::buildObjectForAccessibilityProperties):
Don't use rvalue-references as that was taking ownership and deleting
the object we want to keep around. Instead simplify this to just use
references so no ref counting changes happen.
- 7:27 PM Changeset in webkit [241494] by
-
- 2 edits in trunk/Source/WebCore
AX: Crash in handleMenuOpen
https://bugs.webkit.org/show_bug.cgi?id=194627
Reviewed by Zalan Bujtas.
Tests run under libGuardMalloc will cause crashes.
This list of objects is a Node list, not an Element list, so we were
not removing some nodes when they were being deallocated.
- accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::remove):
- 7:01 PM Changeset in webkit [241493] by
-
- 8 edits in trunk/Source
We should only make rope strings when concatenating strings long enough.
https://bugs.webkit.org/show_bug.cgi?id=194465
Reviewed by Mark Lam.
Source/JavaScriptCore:
This patch stops us from allocating a rope string if the resulting
rope would be smaller than the size of the JSRopeString object we
would need to allocate.
This patch also adds paths so that we don't unnecessarily allocate
JSString cells for primitives we are going to concatenate with a
string anyway.
The important change from the previous one is that we do not apply
the above rule to JSRopeStrings generated by JSStrings. If we convert
it to JSString, comparison of memory consumption becomes the following,
because JSRopeString does not have StringImpl until it is resolved.
sizeof(JSRopeString) v.s. sizeof(JSString) + sizeof(StringImpl) + content
Since sizeof(JSString) + sizeof(StringImpl) is larger than sizeof(JSRopeString),
resolving eagerly increases memory footprint. The point is that we need to
account newly created JSString and JSRopeString from the operands. This is the
reason why this patch adds different thresholds for each jsString functions.
This patch also avoids concatenation for ropes conservatively. Many ropes are
temporary cells. So we do not resolve eagerly if one of operands is already a
rope.
In CLI execution, this change is performance neutral in JetStream2 (run 6 times, 1 for warming up and average in latter 5.).
Before: 159.3778
After: 160.72340000000003
- dfg/DFGOperations.cpp:
- runtime/CommonSlowPaths.cpp:
(JSC::SLOW_PATH_DECL):
- runtime/JSString.h:
(JSC::JSString::isRope const):
- runtime/Operations.cpp:
(JSC::jsAddSlowCase):
- runtime/Operations.h:
(JSC::jsString):
(JSC::jsAddNonNumber):
(JSC::jsAdd):
Source/WTF:
- wtf/text/StringImpl.h:
(WTF::StringImpl::headerSize):
- 6:28 PM Changeset in webkit [241492] by
-
- 2 edits in trunk/Source/WebCore
[Mac] PiP window can get "stuck" if PiP is closed while Safari window is minimized.
https://bugs.webkit.org/show_bug.cgi?id=194621
<rdar://problem/48002560>
Reviewed by Eric Carlson.
When Safari is minimized, no rAF() requests are executed. Don't gate responding to presentation
change events in the media-controller.js on rAF().
- Modules/modern-media-controls/media/media-controller.js:
(MediaController.prototype._returnMediaLayerToInlineIfNeeded):
- 6:28 PM Changeset in webkit [241491] by
-
- 4 edits in trunk/LayoutTests
Unreviewed GTK test gardening
https://bugs.webkit.org/show_bug.cgi?id=194631
- platform/gtk/TestExpectations:
- platform/gtk/editing/pasteboard/smart-paste-007-expected.txt:
- platform/gtk/editing/pasteboard/smart-paste-008-expected.txt:
- 5:36 PM Changeset in webkit [241490] by
-
- 6 edits in trunk
Ignore Ad Click Attribution where source and destination are same-site
https://bugs.webkit.org/show_bug.cgi?id=194620
<rdar://problem/47890018>
Reviewed by Jiewen Tan.
Source/WebCore:
Updated the existing test.
We should not accept Ad Click Attribution requests where the site of the
anchor tag and its addestination attribute are same-site. Such attributions
don’t make sense (the site can track intra-site clicks through better means)
and would just lead to increased memory use where are the pending
attributions are stored.
For ports that don't have access to the Public Suffix List, this patch
only checks that the hosts don't match, i.e. not just eTLD+1.
- html/HTMLAnchorElement.cpp:
(WebCore::HTMLAnchorElement::parseAdClickAttribution const):
Now returns WTF::nullopt if the current document and the
addestination are same site. Also fixed a console message
typo.
LayoutTests:
Same-site test added and test results updated.
- http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt:
- http/tests/adClickAttribution/anchor-tag-attributes-validation.html:
- platform/ios-wk2/http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt:
- 5:25 PM Changeset in webkit [241489] by
-
- 8 edits2 adds in trunk
getUserMedia with an ideal deviceId constraint doesn't always select the correct device
https://bugs.webkit.org/show_bug.cgi?id=193614
Source/WebCore:
Reviewed by Eric Carlson.
Compute a fitness score based on constraints.
For each constraint, a fitness score is computed from the distance.
The smaller the distance, the higher the score.
Fitness scores are then summed to give a device fitness score.
Matching devices are then sorted according the fitness score.
For important constraints, deviceId and facingMode, add a more important weight.
This ensures that should any of these ideal constraints are set, they will be respected.
Restrict our automatic setting of default constraints to not add a default ideal facingMode in case of existing deviceId constraint.
Do not set a default ideal frameRate if width and height are already set.
Covered by updated test.
- platform/mediastream/MediaConstraints.cpp:
(WebCore::FlattenedConstraint::set):
(WebCore::MediaConstraints::setDefaultVideoConstraints):
- platform/mediastream/RealtimeMediaSource.cpp:
(WebCore::RealtimeMediaSource::fitnessDistance):
(WebCore::RealtimeMediaSource::selectSettings):
(WebCore::RealtimeMediaSource::supportsConstraints):
(WebCore::RealtimeMediaSource::applyConstraints):
- platform/mediastream/RealtimeMediaSource.h:
- platform/mediastream/RealtimeMediaSourceCenter.cpp:
(WebCore::RealtimeMediaSourceCenter::validateRequestConstraints):
LayoutTests:
Reviewed by Eric Carlson.
- fast/mediastream/get-user-media-device-id-expected.txt:
- fast/mediastream/get-user-media-device-id.html:
- 4:31 PM Changeset in webkit [241488] by
-
- 2 edits in trunk/Tools
[ews-app] Change log level for a log statement
Unreviewed minor fix.
- BuildSlaveSupport/ews-app/ews/models/patch.py:
(Patch.save_patch):
- 4:28 PM Changeset in webkit [241487] by
-
- 4 edits2 adds in trunk
[iOS] Add a hack to work around buggy video control library
https://bugs.webkit.org/show_bug.cgi?id=194615
<rdar://problem/46146946>
Reviewed by Jer Noble.
Source/WebCore:
Test: media/ios/video-volume-ios-quirk.html
- html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::setVolume): Change m_volume for one turn of the runloop.
(WebCore::HTMLMediaElement::cancelPendingTasks): Clear the task queue used to restore m_volume.
(WebCore::HTMLMediaElement::closeTaskQueues): Close it.
- html/HTMLMediaElement.h:
LayoutTests:
- media/ios/video-volume-ios-quirk-expected.txt: Added.
- media/ios/video-volume-ios-quirk.html: Added.
- 4:21 PM Changeset in webkit [241486] by
-
- 20 edits1 add in trunk
[Cocoa] Media elements will restart network buffering just before suspending
https://bugs.webkit.org/show_bug.cgi?id=193691
Reviewed by Eric Carlson.
Source/WebCore:
API Test: WebKit.ProcessSuspendMediaBuffering
Allow the Page to suspend all media buffering in its child Documents.
- dom/Document.cpp:
(WebCore::Document::suspendAllMediaBuffering):
(WebCore::Document::resumeAllMediaBuffering):
- dom/Document.h:
- html/MediaElementSession.cpp:
(WebCore::MediaElementSession::dataBufferingPermitted const):
(WebCore::MediaElementSession::suspendBuffering):
(WebCore::MediaElementSession::resumeBuffering):
(WebCore::MediaElementSession::bufferingSuspended const):
- html/MediaElementSession.h:
- page/Page.cpp:
(WebCore::Page::suspendAllMediaBuffering):
(WebCore::Page::resumeAllMediaBuffering):
- page/Page.h:
(WebCore::Page::mediaPlaybackIsSuspended const):
(WebCore::Page::mediaBufferingIsSuspended const):
(WebCore::Page::mediaPlaybackIsSuspended): Deleted.
- platform/audio/PlatformMediaSession.h:
(WebCore::PlatformMediaSession::suspendBuffering):
(WebCore::PlatformMediaSession::resumeBuffering):
- platform/audio/PlatformMediaSessionManager.cpp:
(WebCore::PlatformMediaSessionManager::suspendAllMediaBufferingForDocument):
(WebCore::PlatformMediaSessionManager::resumeAllMediaBufferingForDocument):
- platform/audio/PlatformMediaSessionManager.h:
Source/WebKit:
When the WebProcess receives a notification that the process is about to become
suspended, it tells the MemoryPressureHandler to release all critical memory. This
has the side effect of causing AVFoundation-backed media elements to dump their
in-memory caches and start downloading media data again. Instead, media elements
should all stop buffering media data during suspension. Add new testing SPI to
simulate suspension and resume messages.
- UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _processWillSuspendImminentlyForTesting]):
(-[WKWebView _processDidResumeForTesting]):
- UIProcess/API/Cocoa/WKWebViewPrivate.h:
- UIProcess/WebProcessProxy.h:
- UIProcess/ios/WKInkPickerView.mm:
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::suspendAllMediaBuffering):
(WebKit::WebPage::resumeAllMediaBuffering):
- WebProcess/WebPage/WebPage.h:
- WebProcess/WebProcess.cpp:
(WebKit::WebProcess::actualPrepareToSuspend):
(WebKit::WebProcess::cancelPrepareToSuspend):
(WebKit::WebProcess::processDidResume):
(WebKit::WebProcess::suspendAllMediaBuffering):
(WebKit::WebProcess::resumeAllMediaBuffering):
- WebProcess/WebProcess.h:
Tools:
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSuspendMediaBuffering.mm: Added.
(TEST):
- 4:16 PM Changeset in webkit [241485] by
-
- 2 edits in trunk/Tools
[ews-app] Fetch builder id to name mapping
https://bugs.webkit.org/show_bug.cgi?id=194355
Reviewed by Lucas Forschler.
- BuildSlaveSupport/ews-app/ews/common/buildbot.py:
(Buildbot.get_builder_id_to_name_mapping):
(Buildbot._get_display_name_from_builder_name):
- 4:11 PM Changeset in webkit [241484] by
-
- 4 edits2 adds in trunk
Entering fullscreen inside a shadow root will not set fullscreen pseudoclasses outside of root
https://bugs.webkit.org/show_bug.cgi?id=194516
<rdar://problem/44678353>
Reviewed by Antoine Quint.
Source/WebCore:
Test: fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor.html
When walking up the element ancestor chain, use parentElementInComposedTree() to
walk past the shadow root boundary.
- dom/Element.cpp:
(WebCore::parentCrossingFrameBoundaries):
LayoutTests:
- fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor-expected.txt: Added.
- fast/shadow-dom/fullscreen-in-shadow-full-screen-ancestor.html: Added.
- platform/ios-wk2/TestExpectations:
- 4:03 PM Changeset in webkit [241483] by
-
- 2 edits in trunk/Source/WebKit
[iOS] Fix sandbox violation during media playback
https://bugs.webkit.org/show_bug.cgi?id=194616
<rdar://problem/48049264>
Reviewed by Brent Fulgham.
Mach lookup to "com.apple.coremedia.figcontentkeysession.xpc" should be allowed.
- Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
- 3:14 PM Changeset in webkit [241482] by
-
- 4 edits in trunk/Source
Unreviewed, update localizable strings.
Source/WebCore:
- en.lproj/Localizable.strings:
Source/WebInspectorUI:
- Localizations/en.lproj/localizedStrings.js:
- 3:08 PM Changeset in webkit [241481] by
-
- 3 edits4 adds in trunk
Encrypted PDFs inside <embed> or <object> crash the Web Content process
https://bugs.webkit.org/show_bug.cgi?id=194605
<rdar://problem/19894818>
Reviewed by Andy Estes.
Source/WebKit:
- WebProcess/Plugins/PDF/PDFPlugin.mm:
(WebKit::PDFPlugin::createPasswordEntryForm):
Don't try to create a password form field if we can't make form fields.
This means you will be left with a useless embedded PDF, but at least
the Web Content process won't crash.
We'll need to find an alternative implementation of PDF embedded form
fields that is compatible with <embed> and <object> if we want to support
this. Currently we piggy-back off the fact that we can just insert
<input>s into the PluginDocument's DOM, but we can't do that if there
is no PluginDocument, just a main document, like in the <embed> case.
LayoutTests:
- fast/replaced/encrypted-pdf-as-object-and-embed-expected.txt: Added.
- fast/replaced/encrypted-pdf-as-object-and-embed.html: Added.
- fast/replaced/resources/encrypted-image.pdf: Added.
Add a test ensuring that we don't crash with encrypted PDF in <object> or <embed>.
- 3:07 PM Changeset in webkit [241480] by
-
- 30 edits4 adds in trunk
Further restricting webarchive loads
https://bugs.webkit.org/show_bug.cgi?id=194567
<rdar://problem/47610130>
Reviewed by Youenn Fablet.
Source/WebCore:
This patch futher restricts main frame webarchive loads to the followings:
1) loaded by clients;
2) loaded by drag;
3) reloaded from any of the previous two.
It moves setAlwaysAllowLocalWebarchive, which is used for testing only, from Document
to FrameLoader such that the option is remembered during redirections.
Covered by API tests.
- dom/Document.h:
(WebCore::Document::setAlwaysAllowLocalWebarchive): Deleted.
(WebCore::Document::alwaysAllowLocalWebarchive const): Deleted.
- loader/DocumentLoader.cpp:
(WebCore::DocumentLoader::disallowWebArchive const):
- loader/DocumentLoader.h:
(WebCore::DocumentLoader::setAllowsWebArchiveForMainFrame):
(WebCore::DocumentLoader::allowsWebArchiveForMainFrame):
- loader/FrameLoadRequest.h:
(WebCore::FrameLoadRequest::setIsRequestFromClientOrUserInput):
(WebCore::FrameLoadRequest::isRequestFromClientOrUserInput):
- loader/FrameLoader.cpp:
(WebCore::FrameLoader::load):
(WebCore::FrameLoader::reload):
- loader/FrameLoader.h:
(WebCore::FrameLoader::setAlwaysAllowLocalWebarchive):
(WebCore::FrameLoader::alwaysAllowLocalWebarchive const):
- page/DragController.cpp:
(WebCore::DragController::performDragOperation):
- testing/Internals.cpp:
(WebCore::Internals::setAlwaysAllowLocalWebarchive const):
- testing/Internals.h:
- testing/Internals.idl:
Source/WebKit:
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::loadRequest):
Set a flag to indicate a load is started from clients.
Tools:
Besides adding API tests, this patch also enhances DragAndDropSimulator to allow
navigations on drop.
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/mac/LoadWebArchive.mm: Added.
(-[TestLoadWebArchiveNavigationDelegate webView:didFinishNavigation:]):
(-[TestLoadWebArchiveNavigationDelegate webView:didFailProvisionalNavigation:withError:]):
(-[TestLoadWebArchiveNavigationDelegate webView:createWebViewWithConfiguration:forNavigationAction:windowFeatures:]):
(TestWebKitAPI::TEST):
- TestWebKitAPI/Tests/mac/helloworld.webarchive: Added.
- TestWebKitAPI/Tests/mac/load-web-archive-1.html: Added.
- TestWebKitAPI/Tests/mac/load-web-archive-2.html: Added.
- TestWebKitAPI/cocoa/DragAndDropSimulator.h:
- TestWebKitAPI/mac/DragAndDropSimulatorMac.mm:
(-[DragAndDropSimulator initWithWebViewFrame:configuration:]):
(-[DragAndDropSimulator _webView:dragDestinationActionMaskForDraggingInfo:]):
LayoutTests:
- platform/mac/fast/loader/webarchive-encoding-respected.html:
- webarchive/loading/cache-expired-subresource.html:
- webarchive/loading/javascript-url-iframe-crash.html:
- webarchive/loading/mainresource-null-mimetype-crash.html:
- webarchive/loading/missing-data.html:
- webarchive/loading/object.html:
- webarchive/loading/test-loading-archive-subresource-null-mimetype.html:
- webarchive/loading/test-loading-archive-subresource.html:
- webarchive/loading/test-loading-archive.html:
- webarchive/loading/test-loading-top-archive.html:
- webarchive/loading/video-in-webarchive.html:
- 2:59 PM Changeset in webkit [241479] by
-
- 2 edits in trunk/Source/WebCore
Null-deref crash at SourceBufferPrivateAVFObjC::outputObscuredDueToInsufficientExternalProtectionChanged()
https://bugs.webkit.org/show_bug.cgi?id=194613
<rdar://problem/48023912>
Reviewed by Eric Carlson.
- platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
(WebCore::SourceBufferPrivateAVFObjC::outputObscuredDueToInsufficientExternalProtectionChanged):
- 2:49 PM Changeset in webkit [241478] by
-
- 5 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241297. rdar://problem/47969451
Source/WebCore:
Unreviewed build fix; add a HAVE_CELESTIAL guard around Celestial framework usage.
- platform/audio/ios/MediaSessionManagerIOS.h:
- platform/audio/ios/MediaSessionManagerIOS.mm: (WebCore::MediaSessionManageriOS::providePresentingApplicationPIDIfNecessary):
Source/WebCore/PAL:
Unreviewed build fix; add a HAVE_CELESTIAL guard around the CelestialSPI.h contents.
- pal/spi/ios/CelestialSPI.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241297 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 2:49 PM Changeset in webkit [241477] by
-
- 15 edits1 move in branches/safari-608.1.5.1-branch/Source
Cherry-pick r241281. rdar://problem/47969451
[Cocoa] Notify AVSystemController of our presenting PID before registering as a Now Playing app.
https://bugs.webkit.org/show_bug.cgi?id=194504
Reviewed by Eric Carlson.
Source/WebCore:
This allows the MediaRemote framework to associate the WebContent process with its host application.
- Modules/mediastream/UserMediaRequest.cpp: (WebCore::UserMediaRequest::start):
- platform/audio/PlatformMediaSessionManager.h: (WebCore::PlatformMediaSessionManager::prepareToSendUserMediaPermissionRequest):
- platform/audio/cocoa/MediaSessionManagerCocoa.h:
- platform/audio/cocoa/MediaSessionManagerCocoa.mm: (MediaSessionManagerCocoa::prepareToSendUserMediaPermissionRequest): (MediaSessionManagerCocoa::providePresentingApplicationPIDIfNecessary): (MediaSessionManagerCocoa::updateNowPlayingInfo):
Source/WebCore/PAL:
- PAL.xcodeproj/project.pbxproj:
- pal/spi/ios/CelestialSPI.h: Renamed from Source/WebKit/Platform/spi/ios/CelestialSPI.h.
Source/WebKit:
- WebKit.xcodeproj/project.pbxproj:
- WebProcess/WebCoreSupport/WebUserMediaClient.cpp: (WebKit::WebUserMediaClient::requestUserMediaAccess):
- WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::prepareToSendUserMediaPermissionRequest): Deleted.
- WebProcess/WebPage/WebPage.h: (WebKit::WebPage::userMediaPermissionRequestManager):
- WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::prepareToSendUserMediaPermissionRequest): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241281 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 2:42 PM Changeset in webkit [241476] by
-
- 4 edits in tags/Safari-607.1.34.1/Source
Cherry-pick r241352. rdar://problem/48038900
Release assert in PolicyCheckIdentifier::isValidFor via WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction
https://bugs.webkit.org/show_bug.cgi?id=194582
Reviewed by Antti Koivisto.
Source/WebCore:
Check the zero-ness of m_policyCheck first so that we can differentiate process ID being wrong
from the non-generated identifier being sent to us as it was the case in this failure.
- loader/PolicyChecker.cpp: (WebCore::PolicyCheckIdentifier::isValidFor):
Source/WebKit:
The bug was caused by WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction invoking the callback
with responseIdentifier even when we had failed to send the policy check IPC. Clearly, responseIdentifier
is invalid in that case, and we should be using requestIdentifier instead.
Unfortunately no new tests since I'm not aware of a way to make sendSync fail in this case.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 2:36 PM Changeset in webkit [241475] by
-
- 2 edits in trunk/Source/JavaScriptCore
AirIRGenerator::addSwitch switch patchpoint needs to model clobbering the scratch register
https://bugs.webkit.org/show_bug.cgi?id=194610
Reviewed by Michael Saboff.
BinarySwitch might use the scratch register. We must model the
effects of that properly. This is already caught by our br-table
tests on arm64.
- wasm/WasmAirIRGenerator.cpp:
(JSC::Wasm::AirIRGenerator::addSwitch):
- 2:35 PM Changeset in webkit [241474] by
-
- 3 edits1 move1 delete in trunk/Source/WebKit
[WPE][GTK] Merge WebProcessPoolWPE.cpp and WebProcessPoolGtk.cpp
https://bugs.webkit.org/show_bug.cgi?id=194551
Reviewed by Carlos Garcia Campos.
- SourcesGTK.txt:
- SourcesWPE.txt:
- UIProcess/glib/WebProcessPoolGLib.cpp: Renamed from Source/WebKit/UIProcess/gtk/WebProcessPoolGtk.cpp.
(WebKit::initializeRemoteInspectorServer):
(WebKit::memoryPressureMonitorDisabled):
(WebKit::WebProcessPool::platformInitialize):
(WebKit::WebProcessPool::platformInitializeWebProcess):
(WebKit::WebProcessPool::platformInvalidateContext):
(WebKit::WebProcessPool::platformResolvePathsForSandboxExtensions):
- UIProcess/wpe/WebProcessPoolWPE.cpp: Removed.
- 2:28 PM Changeset in webkit [241473] by
-
- 4 edits in tags/Safari-607.1.35.1/Source
Cherry-pick r241352. rdar://problem/48038900
Release assert in PolicyCheckIdentifier::isValidFor via WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction
https://bugs.webkit.org/show_bug.cgi?id=194582
Reviewed by Antti Koivisto.
Source/WebCore:
Check the zero-ness of m_policyCheck first so that we can differentiate process ID being wrong
from the non-generated identifier being sent to us as it was the case in this failure.
- loader/PolicyChecker.cpp: (WebCore::PolicyCheckIdentifier::isValidFor):
Source/WebKit:
The bug was caused by WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction invoking the callback
with responseIdentifier even when we had failed to send the policy check IPC. Clearly, responseIdentifier
is invalid in that case, and we should be using requestIdentifier instead.
Unfortunately no new tests since I'm not aware of a way to make sendSync fail in this case.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 2:23 PM Changeset in webkit [241472] by
-
- 2 edits in trunk/Source/WebCore
Unreviewed, fix unused variable warnings after r241148/r241251
https://bugs.webkit.org/show_bug.cgi?id=194348
<rdar://problem/47566449>
- Modules/mediasource/SourceBuffer.cpp:
(WebCore::SourceBuffer::sourceBufferPrivateDidReceiveRenderingError):
(WebCore::SourceBuffer::evictCodedFrames):
(WebCore::SourceBuffer::provideMediaData):
- 2:10 PM Changeset in webkit [241471] by
-
- 7 edits in tags/Safari-607.1.34.1/Source
Versioning.
- 1:39 PM Changeset in webkit [241470] by
-
- 7 edits in tags/Safari-607.1.35.1/Source
Versioning.
- 1:38 PM Changeset in webkit [241469] by
-
- 1 copy in tags/Safari-607.1.34.1
New tag.
- 1:32 PM Changeset in webkit [241468] by
-
- 3 edits in trunk/Source/WebCore
REGRESSION: [ Mac Debug WK2 ] Layout Test storage/indexeddb/key-type-infinity-private.html is a flaky crash
https://bugs.webkit.org/show_bug.cgi?id=194413
<rdar://problem/47897254>
Reviewed by Brady Eidson.
IDB clients expected transaction operations to be executed in order, but in
UniqueIDBDatabase::immediateCloseForUserDelete, callbacks in callback map were errored out randomly.
This patch added a callback queue to UniqueIDBDatabase to make sure callbacks will be called in the same order
as IDB Server receives the request.
- Modules/indexeddb/server/UniqueIDBDatabase.cpp:
(WebCore::IDBServer::UniqueIDBDatabase::storeCallbackOrFireError):
(WebCore::IDBServer::UniqueIDBDatabase::immediateCloseForUserDelete):
(WebCore::IDBServer::UniqueIDBDatabase::performErrorCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performKeyDataCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performGetResultCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performGetAllResultsCallback):
(WebCore::IDBServer::UniqueIDBDatabase::performCountCallback):
(WebCore::IDBServer::UniqueIDBDatabase::forgetErrorCallback):
- Modules/indexeddb/server/UniqueIDBDatabase.h:
- 1:29 PM Changeset in webkit [241467] by
-
- 1 copy in tags/Safari-607.1.35.1
New tag.
- 1:14 PM Changeset in webkit [241466] by
-
- 7 edits in branches/safari-607-branch/Source/WebKit
Apply patch. rdar://problem/40966400
- 1:11 PM Changeset in webkit [241465] by
-
- 3 edits2 adds in branches/safari-607-branch
Cherry-pick r241319. rdar://problem/48015672
Source/WebCore:
Remove setDefersLoading infrastructure from WebKit2
https://bugs.webkit.org/show_bug.cgi?id=194506
Patch by Alex Christensen <achristensen@webkit.org> on 2019-02-12
Reviewed by Brady Eidson.
setDefersLoading is inherently racy from WebCore to the NetworkProcess,
it adds unwanted complexity to the initialization and use of network objects,
and it has led to many unrecoverable hang bugs over the years.
We needed to force it into WebKit2 to transition some existing clients who relied on it,
but we have recently finished transitioning those clients to other solutions, mostly
completion handlers.
- inspector/PageScriptDebugServer.cpp: (WebCore::PageScriptDebugServer::setJavaScriptPaused):
LayoutTests:
BitmapRenderer should handle existing ImageBuffers
https://bugs.webkit.org/show_bug.cgi?id=194555
<rdar://problem/47857150>
Reviewed by Tim Horton.
Test that creates a canvas, triggers an ImageBuffer to be created, then
creates the bitmaprenderer context.
- fast/canvas/bitmaprenderer-created-after-toBlob-expected.txt: Added.
- fast/canvas/bitmaprenderer-created-after-toBlob.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241319 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241464] by
-
- 4 edits in branches/safari-607-branch/Source/WebCore
Cherry-pick r241300. rdar://problem/48016008
Add some null checks in JSNodeCustom.h's root() and generated isReachableFromOpaqueRoots() functions.
https://bugs.webkit.org/show_bug.cgi?id=194530
<rdar://problem/47973274>
Reviewed by Chris Dumez.
This is needed to fix a null pointer dereference that arises from the following scenario:
- a Document detaches from its StyleSheetList.
- the JSStyleSheetList that is associated with the detached StyleSheetList has yet to be scanned and collected by the GC.
- the GC eventually looks for the opaque root of the StyleSheetList's owner, and discovers a null owner pointer.
This patch fixes this issue by applying the following null checks:
- Add a null check in JSNodeCustom.h's root().
root() is called from a isReachableFromOpaqueRoots() generated by CodeGeneratorJS.pm.
isReachableFromOpaqueRoots() calls a ownerNode() method and passes its result
to root(). However, depending on which class the ownerNode() method belongs to,
it can either return a pointer or a reference. The null check only makes sense
in the pointer case.
To accommodate the 2 forms, root() itself is has an overload that takes a
reference instead of a pointer.
Since CodeGeneratorJS.pm can't tell what the generated class' ownerNode()
returns, it can't discern when the result is a pointer and apply the null check.
Instead, we just add the null check to the version of root() that takes a
pointer. If the node pointer is null, we'll return a null opaque root.
- Fix CodeGeneratorJS.pm to null check the opaque root before using it.
- bindings/js/JSNodeCustom.h: (WebCore::root):
- bindings/scripts/CodeGeneratorJS.pm: (GenerateImplementation):
- bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp: (WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241300 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241463] by
-
- 2 edits in branches/safari-607-branch/Source/WebCore
Cherry-pick r241296. rdar://problem/48015654
Crash in WebCore::ScrollingTree::updateTreeFromStateNode
https://bugs.webkit.org/show_bug.cgi?id=194538
<rdar://problem/47841926>
Reviewed by Zalan Bujtas.
- page/scrolling/ScrollingTree.cpp: (WebCore::ScrollingTree::updateTreeFromStateNode):
Make sure we don't leave node entry behind in m_nodeMap in case we failed to add it to the parent.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241296 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241462] by
-
- 11 edits in branches/safari-607-branch
Cherry-pick r241289. rdar://problem/48015662
AXObjectCache::childrenChanged shouldn't update layout or style during another style recalc
https://bugs.webkit.org/show_bug.cgi?id=182280
<rdar://problem/37018386>
Reviewed by Alan Bujtas.
Source/WebCore:
Remove the possibility that changing children calls back into updating layout by
handling children changes in a deferred manner.
This follows the same architecture as many other deferred changes, but also requires us to check deferred changes
in updateBackingStore, because things like aria-hidden changes won't trigger a layout, but will require us to update children.
A few tests had to be modified to no longer change the tree and then check the children immediately.
- accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::remove): (WebCore::AXObjectCache::childrenChanged): (WebCore::AXObjectCache::prepareForDocumentDestruction): (WebCore::AXObjectCache::performDeferredCacheUpdate):
- accessibility/AXObjectCache.h:
- accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::updateBackingStore):
- accessibility/mac/WebAccessibilityObjectWrapperBase.mm: (convertToNSArray): (-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
LayoutTests:
- accessibility/aria-hidden-update.html:
- accessibility/aria-hidden-updates-alldescendants.html:
- accessibility/image-load-on-delay.html:
- accessibility/mac/aria-hidden-changes-for-non-ignored-elements.html:
- accessibility/removed-anonymous-block-child-causes-crash.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241289 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241461] by
-
- 25 edits2 adds2 deletes in branches/safari-607-branch
Cherry-pick r241288. rdar://problem/47992210
[Cocoa] Ask platform for generic font family mappings
https://bugs.webkit.org/show_bug.cgi?id=187723
<rdar://problem/41892438>
Reviewed by Brent Fulgham.
Source/WebCore:
WebKit API allows setting the generic font families for the USCRIPT_COMMON script.
When trying to style a character with a generic font family, we first look to see if
we have a mapping for the particular script the character is rendered with, and if we
don't find a match, we then check USCRIPT_COMMON.
In the Cocoa ports, the only way families get set for non-USCRIPT_COMMON scripts (aka
the only scripts which won't use the API families) is in
SettingsBase::initializeDefaultFontFamilies(). That function only sets the families
for the CJK scripts.
The mappings inside SettingsBase are incorrect and conflict with our policy regarding
user-installed fonts. Instead, we should be consulting with the platform for some of
these mappings, by calling CTFontDescriptorCreateForCSSFamily(). However, the WebKit
API still has to work to set the mappings for untagged content. Therefore, we use the
system mappings for language-tagged content, and the API mappings for non-language-tagged
content. This is a good balance that makes sure we always have a good mapping for every
language, but API clients can still set the mappings, too.
Test: fast/text/ja-sans-serif.html
- css/CSSComputedStyleDeclaration.cpp:
- css/CSSFontSelector.cpp: (WebCore::resolveGenericFamily):
- css/parser/CSSPropertyParser.cpp: (WebCore::consumeFontFamily):
- page/cocoa/SettingsBaseCocoa.mm: (WebCore::SettingsBase::initializeDefaultFontFamilies): (WebCore::osakaMonoIsInstalled): Deleted.
- platform/graphics/FontDescription.cpp: (WebCore::FontDescription::platformResolveGenericFamily):
- platform/graphics/FontDescription.h:
- platform/graphics/cocoa/FontDescriptionCocoa.cpp: (WebCore::computeSpecializedChineseLocale): (WebCore::cachedSpecializedChineseLocale): (WebCore::languageChanged): (WebCore::FontDescription::platformResolveGenericFamily):
- platform/graphics/cocoa/SystemFontDatabaseCoreText.cpp: (WebCore::SystemFontDatabaseCoreText::clear): (WebCore::genericFamily): (WebCore::SystemFontDatabaseCoreText::serifFamily): (WebCore::SystemFontDatabaseCoreText::sansSerifFamily): (WebCore::SystemFontDatabaseCoreText::cursiveFamily): (WebCore::SystemFontDatabaseCoreText::fantasyFamily): (WebCore::SystemFontDatabaseCoreText::monospaceFamily):
- platform/graphics/cocoa/SystemFontDatabaseCoreText.h:
Source/WebCore/PAL:
- pal/spi/cocoa/CoreTextSPI.h:
Source/WTF:
Add an ENABLE in Platform.
- wtf/Platform.h:
Tools:
Allow testing infrastructure to use fonts that are returned from CTFontDescriptorCreateForCSSFamily().
- DumpRenderTree/mac/DumpRenderTree.mm: (allowedFontFamilySet):
- WebKitTestRunner/mac/TestControllerMac.mm: (WTR::allowedFontFamilySet):
LayoutTests:
Update the tests to work with this new model.
- fast/text/international/font-fallback-to-common-script-expected.html: Removed.
- fast/text/international/font-fallback-to-common-script.html: Removed.
- fast/text/international/lang-sensitive-fonts-expected.html:
- fast/text/international/lang-sensitive-fonts-xml-expected.html:
- fast/text/international/lang-sensitive-fonts-xml.xhtml:
- fast/text/international/lang-sensitive-fonts.html:
- fast/text/international/locale-sensitive-fonts-expected.html:
- fast/text/international/locale-sensitive-fonts.html:
- fast/text/ja-sans-serif-expected-mismatch.html: Added.
- fast/text/ja-sans-serif.html: Added.
- platform/ios/fast/block/float/016-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241288 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241460] by
-
- 2 edits in branches/safari-607-branch/Source/JavaScriptCore
Cherry-pick r241267. rdar://problem/47971556
Remove the RELEASE_ASSERT check for duplicate cases in the BinarySwitch constructor.
https://bugs.webkit.org/show_bug.cgi?id=194493
<rdar://problem/36380852>
Reviewed by Yusuke Suzuki.
Having duplicate cases in the BinarySwitch is not a correctness issue. It is
however not good for performance and memory usage. As such, a debug ASSERT will
do. We'll also do an audit of the clients of BinarySwitch to see if it's
possible to be instantiated with duplicate cases in
https://bugs.webkit.org/show_bug.cgi?id=194492 later.
Also added some value dumps to the RELEASE_ASSERT to help debug the issue when we
see duplicate cases.
- jit/BinarySwitch.cpp: (JSC::BinarySwitch::BinarySwitch):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241267 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241459] by
-
- 2 edits in branches/safari-607-branch/Source/WebCore
Cherry-pick r241231. rdar://problem/47971603
[Cocoa] CTLineGetGlyphRuns() might return nullptr
https://bugs.webkit.org/show_bug.cgi?id=194467
<rdar://problem/42423999>
Reviewed by Simon Fraser.
Be somewhat defensive to try to make sure this sort of thing doesn't happen in the future.
Covered by find/text/find-backwards.html
- platform/graphics/mac/ComplexTextControllerCoreText.mm: (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241231 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241458] by
-
- 14 edits1 add in branches/safari-607-branch
Cherry-pick r241228. rdar://problem/47971567
Nodes that rely on being dominated by CheckInBounds should have a child edge to it
https://bugs.webkit.org/show_bug.cgi?id=194334
<rdar://problem/47844327>
Reviewed by Mark Lam.
JSTests:
- stress/check-in-bounds-should-be-a-child-use.js: Added. (func):
Source/JavaScriptCore:
- dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
- dfg/DFGArgumentsEliminationPhase.cpp:
- dfg/DFGByteCodeParser.cpp: (JSC::DFG::ByteCodeParser::parseBlock):
- dfg/DFGClobberize.h: (JSC::DFG::clobberize):
- dfg/DFGConstantFoldingPhase.cpp: (JSC::DFG::ConstantFoldingPhase::foldConstants):
- dfg/DFGFixupPhase.cpp: (JSC::DFG::FixupPhase::fixupNode): (JSC::DFG::FixupPhase::convertToHasIndexedProperty):
- dfg/DFGIntegerCheckCombiningPhase.cpp: (JSC::DFG::IntegerCheckCombiningPhase::handleBlock):
- dfg/DFGIntegerRangeOptimizationPhase.cpp:
- dfg/DFGNodeType.h:
- dfg/DFGSSALoweringPhase.cpp: (JSC::DFG::SSALoweringPhase::lowerBoundsCheck):
- dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::compileHasIndexedProperty):
- ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileCheckInBounds): (JSC::FTL::DFG::LowerDFGToB3::compileHasIndexedProperty):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241228 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241457] by
-
- 4 edits in branches/safari-607-branch/Source/JavaScriptCore
Cherry-pick r241210. rdar://problem/47971573
Fix DFG's doesGC() for CheckTierUp*, GetByVal, PutByVal*, and StringCharAt nodes.
https://bugs.webkit.org/show_bug.cgi?id=194446
<rdar://problem/47926792>
Reviewed by Saam Barati.
Fix doesGC() for the following nodes:
CheckTierUpAtReturn:
Calls triggerTierUpNow(), which calls triggerFTLReplacementCompile(),
which calls Worklist::completeAllReadyPlansForVM(), which uses DeferGC.
CheckTierUpInLoop:
Calls triggerTierUpNowInLoop(), which calls tierUpCommon(), which calls
Worklist::completeAllReadyPlansForVM(), which uses DeferGC.
CheckTierUpAndOSREnter:
Calls triggerOSREntryNow(), which calls tierUpCommon(), which calls
Worklist::completeAllReadyPlansForVM(), which uses DeferGC.
GetByVal:
case Array::String calls operationSingleCharacterString(), which calls
jsSingleCharacterString(), which can allocate a string.
PutByValDirect:
PutByVal:
PutByValAlias:
For the DFG only, the integer TypeArrays calls compilePutByValForIntTypedArray(),
which may call slow paths operationPutByValDirectStrict(), operationPutByValDirectNonStrict(),
operationPutByValStrict(), or operationPutByValNonStrict(). All of these
slow paths call putByValInternal(), which may create exception objects, or
call the generic JSValue::put() which may execute arbitrary code.
StringCharAt:
Can call operationSingleCharacterString(), which calls jsSingleCharacterString(),
which can allocate a string.
Also fix DFG::SpeculativeJIT::compileGetByValOnString() and FTL's compileStringCharAt()
to use the maxSingleCharacterString constant instead of a literal constant.
- dfg/DFGDoesGC.cpp: (JSC::DFG::doesGC):
- dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::compileGetByValOnString):
- dfg/DFGSpeculativeJIT64.cpp: (JSC::DFG::SpeculativeJIT::compile):
- ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileGetByVal): (JSC::FTL::DFG::LowerDFGToB3::compilePutByVal): (JSC::FTL::DFG::LowerDFGToB3::compileStringCharAt):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241210 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241456] by
-
- 5 edits in branches/safari-607-branch
Cherry-pick r241203. rdar://problem/47971610
[WebVTT] Inline WebVTT styles should start with '::cue'
https://bugs.webkit.org/show_bug.cgi?id=194227
<rdar://problem/47791087>
Reviewed by Eric Carlson.
Source/WebCore:
Check that the CSS string starts with '::cue' and is successfully parsed before adding it
to the CSS stylesheet list. Also, the caption preferences CSS string should start with
'::cue', since it is added inside the video shadow root element.
Test: media/track/track-cue-css.html
- html/track/WebVTTParser.cpp: (WebCore::WebVTTParser::checkAndStoreStyleSheet):
- page/CaptionUserPreferencesMediaAF.cpp: (WebCore::CaptionUserPreferencesMediaAF::captionsStyleSheetOverride const):
LayoutTests:
- media/track/captions-webvtt/css-styling.vtt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241203 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241455] by
-
- 10 edits in branches/safari-607-branch
Cherry-pick r241200. rdar://problem/47971541
Running RTCRtpSender.getCapabilities("video") before initial offer breaks VP8
https://bugs.webkit.org/show_bug.cgi?id=194380
<rdar://problem/47916514>
Reviewed by Eric Carlson.
Source/WebCore:
Set whether VP8 is supported at creation of the page.
This ensures that any call creating a peer connection factory will end up supporting the runtime flag configuration.
Add internal API to enable resetting the factory to enable proper testing.
Covered by updated test.
- Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp: (WebCore::createLibWebRTCPeerConnectionBackend):
- page/Page.cpp: (WebCore::m_applicationManifest):
- platform/mediastream/libwebrtc/LibWebRTCProvider.h:
- testing/Internals.cpp: (WebCore::Internals::clearPeerConnectionFactory):
- testing/Internals.h:
- testing/Internals.idl:
LayoutTests:
- webrtc/video-mute-vp8-expected.txt:
- webrtc/video-mute-vp8.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241200 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:11 PM Changeset in webkit [241454] by
-
- 6 edits in branches/safari-607-branch
Cherry-pick r241198. rdar://problem/47971587
[WebIDL] Support serializing sequences and FrozenArrays of non-interfaces
https://bugs.webkit.org/show_bug.cgi?id=190997
<rdar://problem/35983035>
Reviewed by Brent Fulgham.
Source/WebCore:
Support serializing sequences and FrozenArrays of types that aren't interfaces. This is
needed to properly serialize PaymentAddress, which has a FrozenArray of DOMStrings.
We should support serializing sequences of interfaces too, but that's slightly more
complicated since it involves iterating the sequence and serializing each of its items. I
left that as a follow-up task, since I don't see any IDLs that currently need this.
We also don't support serializing sequences with the CachedAttribute or CustomGetter
extended attributes, because WebIDL specifies that a new array should be created when
converting an IDL sequence into an ECMAScript value.
Added bindings test cases to TestSerialization.idl and PaymentAddress test cases to
http/tests/paymentrequest/payment-address-attributes-and-toJSON-method.https.html.
- bindings/scripts/CodeGenerator.pm: (GetInterfaceForType): Renamed from GetInterfaceForAttribute. (IsSerializableType): Modified to allow sequences and FrozenArrays of non-interface types. (hasCachedAttributeOrCustomGetterExtendedAttribute): Added a helper to determine if an attribute has the CachedAttribute or CustomGetter extended attributes. (IsSerializableAttribute): Checked for sequences with the CachedAttribute or CustomGetter extended attributes before calling IsSerializableType. (GetInterfaceForAttribute): Renamed to GetInterfaceForType.
- bindings/scripts/test/JS/JSTestSerialization.cpp:
- bindings/scripts/test/TestSerialization.idl:
LayoutTests:
- http/tests/paymentrequest/payment-address-attributes-and-toJSON-method.https.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241198 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:10 PM Changeset in webkit [241453] by
-
- 2 edits in trunk/Source/WebKit
Fix -Wformat warning from r241401
https://bugs.webkit.org/show_bug.cgi?id=194584
<rdar://problem/47761293>
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::setActivityState):
- 12:49 PM Changeset in webkit [241452] by
-
- 2 edits in trunk/Source/WebKit
Make WebRTCUnifiedPlanEnabled true by default
https://bugs.webkit.org/show_bug.cgi?id=194595
Reviewed by Eric Carlson.
- Shared/WebPreferences.yaml:
- 12:47 PM Changeset in webkit [241451] by
-
- 37 edits1 copy3 adds in trunk
Store Ad Click Attribution requests in the network process
https://bugs.webkit.org/show_bug.cgi?id=194510
<rdar://problem/47650118>
Reviewed by Alex Christensen and Daniel Bates.
Source/WebCore:
Test: http/tests/adClickAttribution/store-ad-click-attribution.html
This patch adds support functions for validation and storage of
WebCore::AdClickAttribution objects. It also adds WTF::HashTraits so that
WebCore::AdClickAttribution::Source and WebCore::AdClickAttribution::Destination
can be used in a HashMap.
- loader/AdClickAttribution.cpp:
(WebCore::AdClickAttribution::toString const):
- loader/AdClickAttribution.h:
(WebCore::AdClickAttribution::Source::operator== const):
(WebCore::AdClickAttribution::Source::deletedValue):
(WebCore::AdClickAttribution::Source::constructDeletedValue):
(WebCore::AdClickAttribution::Source::deleteValue):
(WebCore::AdClickAttribution::Source::isDeletedValue const):
(WebCore::AdClickAttribution::SourceHash::hash):
(WebCore::AdClickAttribution::SourceHash::equal):
(WebCore::AdClickAttribution::Destination::operator== const):
(WebCore::AdClickAttribution::Destination::matches const):
This convenience function allows matching of a WTF::URL object.
(WebCore::AdClickAttribution::Destination::deletedValue):
(WebCore::AdClickAttribution::Destination::constructDeletedValue):
(WebCore::AdClickAttribution::Destination::deleteValue):
(WebCore::AdClickAttribution::Destination::isDeletedValue const):
(WebCore::AdClickAttribution::DestinationHash::hash):
(WebCore::AdClickAttribution::DestinationHash::equal):
(WebCore::AdClickAttribution::source const):
(WebCore::AdClickAttribution::destination const):
Getters added to support mapped storage based on source and destination.
(WTF::HashTraits<WebCore::AdClickAttribution::Source>::emptyValue):
(WTF::HashTraits<WebCore::AdClickAttribution::Source>::constructDeletedValue):
(WTF::HashTraits<WebCore::AdClickAttribution::Source>::isDeletedValue):
(WTF::HashTraits<WebCore::AdClickAttribution::Destination>::emptyValue):
(WTF::HashTraits<WebCore::AdClickAttribution::Destination>::constructDeletedValue):
(WTF::HashTraits<WebCore::AdClickAttribution::Destination>::isDeletedValue):
- loader/NavigationAction.h:
(WebCore::NavigationAction::adClickAttribution const):
(WebCore::NavigationAction::adClickAttribution): Deleted.
Corrected the constness of this function.
Source/WebKit:
With this patch, WebPageProxy::didCommitLoadForFrame() now looks for
an AdClickAttribution object in its navigation state. If there is an
attribution, it sends it to the network process where the
WebKit::NetworkSession stores it in an object of a new class,
WebKit::NetworkAdClickAttribution.
This patch also covers test infrastructure to support two new
TestRunner functions:
- dumpAdClickAttribution()
- clearAdClickAttribution()
- NetworkProcess/Cookies/WebCookieManager.cpp:
Added missing header include.
- NetworkProcess/Downloads/DownloadManager.cpp:
Added missing header include.
- NetworkProcess/NetworkAdClickAttribution.cpp: Added.
(WebKit::NetworkAdClickAttribution::ensureDestinationMapForSource):
(WebKit::NetworkAdClickAttribution::store):
(WebKit::NetworkAdClickAttribution::clear):
(WebKit::NetworkAdClickAttribution::toString const):
- NetworkProcess/NetworkAdClickAttribution.h: Added.
Stores WebCore::AdClickAttribution objects in a map structure.
- NetworkProcess/NetworkLoad.cpp:
Added missing header includes.
- NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::storeAdClickAttribution):
(WebKit::NetworkProcess::dumpAdClickAttribution):
(WebKit::NetworkProcess::clearAdClickAttribution):
- NetworkProcess/NetworkProcess.h:
- NetworkProcess/NetworkProcess.messages.in:
- NetworkProcess/NetworkSession.cpp:
(WebKit::NetworkSession::NetworkSession):
(WebKit::NetworkSession::storeAdClickAttribution):
(WebKit::NetworkSession::dumpAdClickAttribution):
(WebKit::NetworkSession::clearAdClickAttribution):
- NetworkProcess/NetworkSession.h:
- NetworkProcess/soup/RemoteNetworkingContextSoup.cpp:
Added missing header include.
- Sources.txt:
Added NetworkProcess/NetworkAdClickAttribution.cpp.
- UIProcess/API/APINavigation.h:
(API::Navigation::adClickAttribution const):
- UIProcess/API/C/WKPage.cpp:
(WKPageDumpAdClickAttribution):
(WKPageClearAdClickAttribution):
Test infrastructure.
- UIProcess/API/C/WKPagePrivate.h:
- UIProcess/Network/NetworkProcessProxy.cpp:
(WebKit::NetworkProcessProxy::dumpAdClickAttribution):
(WebKit::NetworkProcessProxy::clearAdClickAttribution):
Test infrastructure.
- UIProcess/Network/NetworkProcessProxy.h:
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didFinishDocumentLoadForFrame):
This is where pending Ad Click Attributions are forwarded to the
network process.
(WebKit::WebPageProxy::dumpAdClickAttribution):
(WebKit::WebPageProxy::clearAdClickAttribution):
Test infrastructure.
- UIProcess/WebPageProxy.h:
- UIProcess/WebProcessPool.cpp:
(WebKit::WebProcessPool::dumpAdClickAttribution):
(WebKit::WebProcessPool::clearAdClickAttribution):
Test infrastructure.
- UIProcess/WebProcessPool.h:
- WebKit.xcodeproj/project.pbxproj:
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
Added missing data copying from navigationAction to navigationActionData.
Tools:
This patch adds two TestRunner functions:
- dumpAdClickAttribution()
- clearAdClickAttribution()
They call into the network process to dump and clear Ad Click
Attribution state, respectively.
- WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
- WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::dumpAdClickAttribution):
(WTR::TestRunner::clearAdClickAttribution):
- WebKitTestRunner/InjectedBundle/TestRunner.h:
- WebKitTestRunner/TestController.cpp:
(WTR::TestController::resetStateToConsistentValues):
(WTR::AdClickAttributionStringResultCallbackContext::AdClickAttributionStringResultCallbackContext):
(WTR::adClickAttributionStringResultCallback):
(WTR::TestController::dumpAdClickAttribution):
(WTR::AdClickAttributionVoidCallbackContext::AdClickAttributionVoidCallbackContext):
(WTR::adClickAttributionVoidCallback):
(WTR::TestController::clearAdClickAttribution):
- WebKitTestRunner/TestController.h:
- WebKitTestRunner/TestInvocation.cpp:
(WTR::TestInvocation::dumpResults):
(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
(WTR::TestInvocation::dumpAdClickAttribution):
- WebKitTestRunner/TestInvocation.h:
LayoutTests:
Marked "Skip" because the feature is not applicable to WK1.
- http/tests/adClickAttribution/store-ad-click-attribution-expected.txt: Added.
- http/tests/adClickAttribution/store-ad-click-attribution.html: Added.
- platform/wk2/TestExpectations:
Marked "Pass."
- 12:34 PM Changeset in webkit [241450] by
-
- 3 edits in trunk/Source/WebCore
Revert r240434
https://bugs.webkit.org/show_bug.cgi?id=194600
<rdar://problem/48044566>
Reviewed by Brent Fulgham.
- html/HTMLMediaElement.cpp:
(WebCore::HTMLMediaElement::setVolume):
(WebCore::HTMLMediaElement::mediaPlayerVolumeChanged):
(WebCore::HTMLMediaElement::updateVolume):
- platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::MediaPlayerPrivateAVFoundationObjC::setVolume):
- 12:34 PM Changeset in webkit [241449] by
-
- 3 edits in trunk/Source/JavaScriptCore
Create a randomized free list for new StructureIDs on StructureIDTable resize.
https://bugs.webkit.org/show_bug.cgi?id=194566
<rdar://problem/47975502>
Reviewed by Michael Saboff.
Also isolate 32-bit implementation of StructureIDTable out more so the 64-bit
implementation is a little easier to read.
This patch appears to be perf neutral on JetStream2 (as run from the command line).
- runtime/StructureIDTable.cpp:
(JSC::StructureIDTable::StructureIDTable):
(JSC::StructureIDTable::makeFreeListFromRange):
(JSC::StructureIDTable::resize):
(JSC::StructureIDTable::allocateID):
(JSC::StructureIDTable::deallocateID):
- runtime/StructureIDTable.h:
(JSC::StructureIDTable::get):
(JSC::StructureIDTable::deallocateID):
(JSC::StructureIDTable::allocateID):
(JSC::StructureIDTable::flushOldTables):
- 11:24 AM Changeset in webkit [241448] by
-
- 2 edits in trunk/Source/WebKit
Crash in WebKit::CacheStorage::Engine::cachesRootPath
https://bugs.webkit.org/show_bug.cgi?id=194588
<rdar://problem/46363997>
Reviewed by Youenn Fablet.
- NetworkProcess/cache/CacheStorageEngine.cpp:
(WebKit::CacheStorage::Engine::cachesRootPath):
Salt may have not been initialized yet when the Engine is destroyed.
- 11:16 AM Changeset in webkit [241447] by
-
- 2 edits in trunk/Source/JavaScriptCore
VariableLengthObject::allocate<T> should initialize objects
https://bugs.webkit.org/show_bug.cgi?id=194534
Reviewed by Michael Saboff.
buffer()
should not be called for empty VariableLengthObjects, but
these cases were not being caught due to the objects not being properly
initialized. Fix it so that allocate calls the constructor and fix the
assertion failues.
- runtime/CachedTypes.cpp:
(JSC::CachedObject::operator new):
(JSC::VariableLengthObject::allocate):
(JSC::CachedVector::encode):
(JSC::CachedVector::decode const):
(JSC::CachedUniquedStringImpl::decode const):
(JSC::CachedBitVector::encode):
(JSC::CachedBitVector::decode const):
(JSC::CachedArray::encode):
(JSC::CachedArray::decode const):
(JSC::CachedImmutableButterfly::CachedImmutableButterfly):
(JSC::CachedBigInt::decode const):
- 11:11 AM Changeset in webkit [241446] by
-
- 7 edits in trunk/Source
Versioning.
- 11:05 AM Changeset in webkit [241445] by
-
- 1 copy in tags/Safari-608.1.6
Tag Safari-608.1.6.
- 11:00 AM Changeset in webkit [241444] by
-
- 6 edits in trunk/Source/WebCore
Stop using setDefersLoading from WebCore
https://bugs.webkit.org/show_bug.cgi?id=194315
Reviewed by Jer Noble.
That is what CompletionHandlers are for.
- loader/MediaResourceLoader.cpp:
(WebCore::MediaResource::responseReceived):
(WebCore::MediaResource::setDefersLoading): Deleted.
- loader/MediaResourceLoader.h:
- platform/graphics/PlatformMediaResourceLoader.h:
(WebCore::PlatformMediaResourceClient::responseReceived):
(WebCore::PlatformMediaResource::stop):
(WebCore::PlatformMediaResource::setDefersLoading): Deleted.
- platform/network/cocoa/WebCoreNSURLSession.mm:
(WebCore::WebCoreNSURLSessionDataTaskClient::responseReceived):
(-[WebCoreNSURLSessionDataTask resource:receivedResponse:completionHandler:]):
(-[WebCoreNSURLSessionDataTask _setDefersLoading:]): Deleted.
(-[WebCoreNSURLSessionDataTask resource:receivedResponse:]): Deleted.
- 10:54 AM Changeset in webkit [241443] by
-
- 2 edits in trunk/Tools
[ews-app] Generate status-bubble
https://bugs.webkit.org/show_bug.cgi?id=194572
Reviewed by Lucas Forschler.
- BuildSlaveSupport/ews-app/ews/views/statusbubble.py:
(StatusBubble._build_bubble):
(StatusBubble._should_show_bubble_for):
(StatusBubble._build_bubbles_for_patch):
- 10:50 AM Changeset in webkit [241442] by
-
- 3 edits in trunk/Source/JavaScriptCore
CodeBlocks read from disk should not be re-written
https://bugs.webkit.org/show_bug.cgi?id=194535
Reviewed by Michael Saboff.
Keep track of which CodeBlocks have been read from disk or have already
been serialized in CodeCache.
- runtime/CodeCache.cpp:
(JSC::CodeCache::write):
- runtime/CodeCache.h:
(JSC::SourceCodeValue::SourceCodeValue):
(JSC::CodeCacheMap::fetchFromDiskImpl):
- 10:35 AM Changeset in webkit [241441] by
-
- 13 edits in trunk/Source/WebKit
Remove legacy sync messaging in some IPC code
https://bugs.webkit.org/show_bug.cgi?id=194561
Reviewed by Geoffrey Garen.
Changing some LegacySync messages to Delayed messages. We should probably rename Delayed to Sync.
There are too many ways to send messages. Let's work to get rid of the old one.
- NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::setAllowsAnySSLCertificateForWebSocket):
(WebKit::NetworkProcess::processWillSuspendImminently):
- NetworkProcess/NetworkProcess.h:
- NetworkProcess/NetworkProcess.messages.in:
- PluginProcess/PluginControllerProxy.cpp:
(WebKit::PluginControllerProxy::handleWheelEvent):
(WebKit::PluginControllerProxy::handleMouseEnterEvent):
(WebKit::PluginControllerProxy::handleMouseLeaveEvent):
(WebKit::PluginControllerProxy::handleKeyboardEvent):
(WebKit::PluginControllerProxy::handleEditingCommand):
(WebKit::PluginControllerProxy::isEditingCommandEnabled):
(WebKit::PluginControllerProxy::handlesPageScaleFactor):
(WebKit::PluginControllerProxy::requiresUnifiedScaleFactor):
(WebKit::PluginControllerProxy::paintEntirePlugin):
(WebKit::PluginControllerProxy::supportsSnapshotting):
(WebKit::PluginControllerProxy::snapshot):
(WebKit::PluginControllerProxy::getPluginScriptableNPObject):
(WebKit::PluginControllerProxy::getFormValue):
- PluginProcess/PluginControllerProxy.h:
- PluginProcess/PluginControllerProxy.messages.in:
- Shared/Plugins/NPObjectMessageReceiver.cpp:
(WebKit::NPObjectMessageReceiver::deallocate):
(WebKit::NPObjectMessageReceiver::hasMethod):
(WebKit::NPObjectMessageReceiver::invoke):
(WebKit::NPObjectMessageReceiver::invokeDefault):
(WebKit::NPObjectMessageReceiver::hasProperty):
(WebKit::NPObjectMessageReceiver::getProperty):
(WebKit::NPObjectMessageReceiver::setProperty):
(WebKit::NPObjectMessageReceiver::removeProperty):
(WebKit::NPObjectMessageReceiver::enumerate):
(WebKit::NPObjectMessageReceiver::construct):
- Shared/Plugins/NPObjectMessageReceiver.h:
- Shared/Plugins/NPObjectMessageReceiver.messages.in:
- UIProcess/mac/SecItemShimProxy.cpp:
(WebKit::SecItemShimProxy::secItemRequest):
- UIProcess/mac/SecItemShimProxy.h:
- UIProcess/mac/SecItemShimProxy.messages.in:
- 10:30 AM Changeset in webkit [241440] by
-
- 1 edit1 copy1 add in trunk/Tools
[ews-app] Add status bubble html template
https://bugs.webkit.org/show_bug.cgi?id=194571
Reviewed by Lucas Forschler.
- BuildSlaveSupport/ews-app/ews/templates: Added.
- BuildSlaveSupport/ews-app/ews/templates/statusbubble.html: Copied from QueueStatusServer/templates/statusbubble.html.
- 10:06 AM Changeset in webkit [241439] by
-
- 7 edits in branches/safari-607-branch/Source
Versioning.
- 10:02 AM Changeset in webkit [241438] by
-
- 4 edits in branches/safari-607-branch/Source
Cherry-pick r241352. rdar://problem/48038900
Release assert in PolicyCheckIdentifier::isValidFor via WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction
https://bugs.webkit.org/show_bug.cgi?id=194582
Reviewed by Antti Koivisto.
Source/WebCore:
Check the zero-ness of m_policyCheck first so that we can differentiate process ID being wrong
from the non-generated identifier being sent to us as it was the case in this failure.
- loader/PolicyChecker.cpp: (WebCore::PolicyCheckIdentifier::isValidFor):
Source/WebKit:
The bug was caused by WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction invoking the callback
with responseIdentifier even when we had failed to send the policy check IPC. Clearly, responseIdentifier
is invalid in that case, and we should be using requestIdentifier instead.
Unfortunately no new tests since I'm not aware of a way to make sendSync fail in this case.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 9:45 AM Changeset in webkit [241437] by
-
- 4 edits in trunk/Source/WebCore
[Cocoa] Switch to CVPixelBufferGetBytesPerRow() for calculating CVPixelBuffer base address size.
https://bugs.webkit.org/show_bug.cgi?id=194580
<rdar://problem/42727739>
Reviewed by Eric Carlson.
- platform/cocoa/CoreVideoSoftLink.cpp:
- platform/cocoa/CoreVideoSoftLink.h:
- platform/graphics/cv/PixelBufferConformerCV.cpp:
(WebCore::CVPixelBufferGetBytePointerCallback):
(WebCore::PixelBufferConformerCV::createImageFromPixelBuffer):
- 9:12 AM Changeset in webkit [241436] by
-
- 3 edits6 adds in trunk/LayoutTests
Add two regression tests for reference cycle in IndexedDB
https://bugs.webkit.org/show_bug.cgi?id=194527
Reviewed by Geoffrey Garen.
- fast/dom/reference-cycle-leaks.html:
- platform/win/TestExpectations:
The added tests are failing on win bots for unknown reasons, propably related to webkit.org/b/193540. Skip them
on win.
- storage/indexeddb/resources/result-request-cycle.js: Added.
(prepareDatabase):
- storage/indexeddb/resources/value-cursor-cycle.js: Added.
(prepareDatabase):
(onOpen.cursorRequest.onsuccess):
- storage/indexeddb/result-request-cycle-expected.txt: Added.
- storage/indexeddb/result-request-cycle.html: Added.
- storage/indexeddb/value-cursor-cycle-expected.txt: Added.
- storage/indexeddb/value-cursor-cycle.html: Added.
- 8:55 AM Changeset in webkit [241435] by
-
- 3 edits in trunk/Source/WebKit
Unreviewed, rolling out r241433.
Broke internal builds.
Reverted changeset:
"Move
UIWebTouchEventsGestureRecognizer.activeTouchesByIdentifier to
SPI"
https://bugs.webkit.org/show_bug.cgi?id=194531
https://trac.webkit.org/changeset/241433
- 8:40 AM Changeset in webkit [241434] by
-
- 4 edits in branches/safari-608.1.5.1-branch/Source
Cherry-pick r241352. rdar://problem/47941089
Release assert in PolicyCheckIdentifier::isValidFor via WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction
https://bugs.webkit.org/show_bug.cgi?id=194582
Reviewed by Antti Koivisto.
Source/WebCore:
Check the zero-ness of m_policyCheck first so that we can differentiate process ID being wrong
from the non-generated identifier being sent to us as it was the case in this failure.
- loader/PolicyChecker.cpp: (WebCore::PolicyCheckIdentifier::isValidFor):
Source/WebKit:
The bug was caused by WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction invoking the callback
with responseIdentifier even when we had failed to send the policy check IPC. Clearly, responseIdentifier
is invalid in that case, and we should be using requestIdentifier instead.
Unfortunately no new tests since I'm not aware of a way to make sendSync fail in this case.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp: (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 5:46 AM Changeset in webkit [241433] by
-
- 3 edits in trunk/Source/WebKit
Move UIWebTouchEventsGestureRecognizer.activeTouchesByIdentifier to SPI
https://bugs.webkit.org/show_bug.cgi?id=194531
<rdar://problem/47714562>
Reviewed by Dean Jackson.
- Platform/spi/ios/UIKitSPI.h:
- UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView cancelPointersForGestureRecognizer:]): We update the referenced Radar since we need to keep the call
to respondsToSelector until the SPI has shipped for OpenSource builds to work.
- 5:34 AM Changeset in webkit [241432] by
-
- 18 edits3 adds in trunk
Support simulated mouse events on iOS based on a PlatformTouchEvent
https://bugs.webkit.org/show_bug.cgi?id=194501
<rdar://problem/46910790>
Reviewed by Dean Jackson.
Source/WebCore:
Add support for two new internal runtime flags to control whether simulated mouse events should be dipatched along with touch events and
whether simulated mousemove events dispatched should automatically trigger the behavior preventDefault() would also trigger. To facilitate
that, we allow for a MouseEvent to be created, much like a PointerEvent, based on a PlatformTouchEvent. Then, we set a flag on Event within
EventTarget::innerInvokeEventListeners() to see whether any page code has been evaluated as a result of a mousemove event being dispatched.
Finally, we also track mouse events when invalidating touch regions provided the required internal runtime flag is on.
Test: fast/events/touch/ios/mouse-events-dispatch-with-touch.html
- SourcesCocoa.txt:
- WebCore.xcodeproj/project.pbxproj:
- dom/Event.cpp:
- dom/Event.h:
(WebCore::Event::hasEncounteredListener const):
(WebCore::Event::setHasEncounteredListener):
- dom/EventNames.h:
(WebCore::EventNames::isTouchRelatedEventType const):
(WebCore::EventNames::touchRelatedEventNames const):
(WebCore::EventNames::extendedTouchRelatedEventNames const):
(WebCore::EventNames::isTouchEventType const): Deleted.
(WebCore::EventNames::touchAndPointerEventNames const): Deleted.
- dom/EventTarget.cpp:
(WebCore::EventTarget::innerInvokeEventListeners):
- dom/MouseEvent.h:
- dom/Node.cpp:
(WebCore::Node::moveNodeToNewDocument):
(WebCore::tryAddEventListener):
(WebCore::tryRemoveEventListener):
(WebCore::Node::defaultEventHandler):
- dom/ios/MouseEventIOS.cpp: Added.
(WebCore::mouseEventType):
(WebCore::MouseEvent::create):
- dom/ios/PointerEventIOS.cpp:
(WebCore::pointerEventType):
(WebCore::PointerEvent::create):
(WebCore::eventType): Deleted.
- page/DOMWindow.cpp:
(WebCore::DOMWindow::addEventListener):
(WebCore::DOMWindow::removeEventListener):
- page/EventHandler.h:
- page/RuntimeEnabledFeatures.h:
(WebCore::RuntimeEnabledFeatures::mouseEventsSimulationEnabled const):
(WebCore::RuntimeEnabledFeatures::setMouseEventsSimulationEnabled):
(WebCore::RuntimeEnabledFeatures::mousemoveEventHandlingPreventsDefaultEnabled const):
(WebCore::RuntimeEnabledFeatures::setMousemoveEventHandlingPreventsDefaultEnabled):
Source/WebKit:
Add two new internal runtime flags to control whether simulated mouse events should be dipatched along with touch events and whether
simulated mousemove events dispatched should automatically trigger the behavior preventDefault() would also trigger. We also ensure
that we correctly create touch tracking regions for mouse events.
- Shared/WebPreferences.yaml:
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::updateTouchEventTracking):
LayoutTests:
Add a new test to check that we correctly dispatch mouse events as touches occur.
- fast/events/touch/ios/mouse-events-dispatch-with-touch-expected.txt: Added.
- fast/events/touch/ios/mouse-events-dispatch-with-touch.html: Added.
- pointerevents/utils.js:
(prototype.handleEvent):
(prototype._handlePointerEvent):
(prototype._handleMouseEvent):
- 4:21 AM Changeset in webkit [241431] by
-
- 2 edits in trunk/Source/JavaScriptCore
SourceCode should be copied when generating bytecode for functions
https://bugs.webkit.org/show_bug.cgi?id=194536
Reviewed by Saam Barati.
The FunctionExecutable might be collected while generating the bytecode
for nested functions, in which case the SourceCode reference would no
longer be valid.
- runtime/CodeCache.cpp:
(JSC::generateUnlinkedCodeBlockForFunctions):
- 2:12 AM Changeset in webkit [241430] by
-
- 3 edits in trunk/LayoutTests
[GTK][WPE] Don't use DumpJSConsoleLogInStdErr expectation in platform TestExpectations
https://bugs.webkit.org/show_bug.cgi?id=194587
Unreviewed gardening.
- platform/gtk/TestExpectations: Removed DumpJSConsoleLogInStdErr markers which are marked in top TestExpectations.
- platform/wpe/TestExpectations: Ditto.
- 1:58 AM Changeset in webkit [241429] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241402 - [FreeType] Unable to render some Hebrew characters
https://bugs.webkit.org/show_bug.cgi?id=194498
Reviewed by Michael Catanzaro.
We are failing to find a font for some of the combining character sequences because normalization is failing due
to overflow error. In case of overflow, normalize returns the required length for the normalized characters, so
we should handle that case to resize the output buffer and try again.
- platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
(WebCore::FontCascade::fontForCombiningCharacterSequence const):
- 1:58 AM Changeset in webkit [241428] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241401 - Crash in Page::setActivityState because m_page is null
https://bugs.webkit.org/show_bug.cgi?id=194584
Reviewed by Antti Koivisto.
Add a null check to avoid the crash. Also add a debug assertion to help diagnose this in the future.
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::setActivityState):
- 1:57 AM Changeset in webkit [241427] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24/Source
Merge r241352 - Release assert in PolicyCheckIdentifier::isValidFor via WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction
https://bugs.webkit.org/show_bug.cgi?id=194582
Reviewed by Antti Koivisto.
Source/WebCore:
Check the zero-ness of m_policyCheck first so that we can differentiate process ID being wrong
from the non-generated identifier being sent to us as it was the case in this failure.
- loader/PolicyChecker.cpp:
(WebCore::PolicyCheckIdentifier::isValidFor):
Source/WebKit:
The bug was caused by WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction invoking the callback
with responseIdentifier even when we had failed to send the policy check IPC. Clearly, responseIdentifier
is invalid in that case, and we should be using requestIdentifier instead.
Unfortunately no new tests since I'm not aware of a way to make sendSync fail in this case.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
- 1:57 AM Changeset in webkit [241426] by
-
- 6 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241351 - Responsiveness timers are too expensive for frequent events
https://bugs.webkit.org/show_bug.cgi?id=194003
Reviewed by Geoffrey Garen.
With each event, we set a responsivness timer to check if the WebProcess
is responsive, and reset the timer when the WebProcess sends an answer.
For frequent events (e.g. wheel events, mouse force events, etc),
we are spamming the kernel with hundreds of timers per second.
That is a bit inefficient.
Another source of inefficiency comes from the timer implementation
itself. Stopping a RunLoop::Timer removes the timer from every mode
and invalidate the timer. It becomes costly since we do it a lot.
With this patch, I tweak ResponsivenessTimer and its use to minimize
how often we schedule system timers.
The first change is to not stop the timer when we get the stop()
calls if we expect more events to come in. Instead, we keep track
if we care about the timeout or not in the attribute "m_waitingForTimer".
When the next event starts, we can reschedule the timer without ever
having told the kernel about the stop.
If there are no next events, the timeout fires but m_waitingForTimer
is false. To avoid idle wake up, the lazy stop is only used when having
following events is common.
The second improvements comes from not even rescheduling the timer
when restarted. Instead of changing the timer, we let the original timer
fire and re-shedule a new one with the missing time.
For more context, also see patches r240759 and r240944.
- UIProcess/ResponsivenessTimer.cpp:
(WebKit::ResponsivenessTimer::ResponsivenessTimer):
(WebKit::ResponsivenessTimer::invalidate):
(WebKit::ResponsivenessTimer::timerFired):
(WebKit::ResponsivenessTimer::start):
(WebKit::ResponsivenessTimer::startWithLazyStop):
(WebKit::ResponsivenessTimer::stop):
(WebKit::ResponsivenessTimer::processTerminated):
(WebKit::ResponsivenessTimer::~ResponsivenessTimer): Deleted.
- UIProcess/ResponsivenessTimer.h:
(WebKit::ResponsivenessTimer::hasActiveTimer const):
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::processNextQueuedMouseEvent):
(WebKit::WebPageProxy::sendWheelEvent):
(WebKit::WebPageProxy::handleKeyboardEvent):
(WebKit::WebPageProxy::handleGestureEvent):
- UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::isResponsiveWithLazyStop):
- UIProcess/WebProcessProxy.h:
- 1:57 AM Changeset in webkit [241425] by
-
- 6 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241350 - Unreviewed, rolling out r241273.
https://bugs.webkit.org/show_bug.cgi?id=194579
This change is causing a flaky assertion failure crash in High
Sierra Debug (Requested by ShawnRoberts on #webkit).
Reverted changeset:
"Stop using setDefersLoading from WebCore"
https://bugs.webkit.org/show_bug.cgi?id=194315
https://trac.webkit.org/changeset/241273
- 1:57 AM Changeset in webkit [241424] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merge r241338 - WebServiceWorkerProvider::handleFetch no longer needs a CachedResource parameter
https://bugs.webkit.org/show_bug.cgi?id=194548
Reviewed by Alex Christensen.
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoad):
- WebProcess/Storage/WebServiceWorkerProvider.cpp:
(WebKit::WebServiceWorkerProvider::handleFetch):
- WebProcess/Storage/WebServiceWorkerProvider.h:
- 1:57 AM Changeset in webkit [241423] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
Merge r241335 - Make B3Value::returnsBool() more precise
https://bugs.webkit.org/show_bug.cgi?id=194457
Reviewed by Saam Barati.
It is currently used repeatedly in B3ReduceStrength, as well as once in B3LowerToAir.
It has a needlessly complex rule for BitAnd, and has no rule for other easy cases such as BitOr or Select.
No new tests added as this should be indirectly tested by the already existing tests.
- b3/B3Value.cpp:
(JSC::B3::Value::returnsBool const):
- 1:57 AM Changeset in webkit [241422] by
-
- 5 edits in releases/WebKitGTK/webkit-2.24
Merge r241333 - Align with Fetch on data: URLs
https://bugs.webkit.org/show_bug.cgi?id=182325
Patch by Rob Buis <rbuis@igalia.com> on 2019-02-12
Reviewed by Alex Christensen.
LayoutTests/imported/w3c:
Update improved test expectations.
- web-platform-tests/fetch/data-urls/processing.any-expected.txt:
- web-platform-tests/fetch/data-urls/processing.any.worker-expected.txt:
Source/WebCore:
The MIME type part of the data url should be serialized as
specified in step 3 under "data" [1].
Test: web-platform-tests/fetch/data-urls/processing.any.js
[1] https://fetch.spec.whatwg.org/#concept-scheme-fetch
- platform/network/DataURLDecoder.cpp:
(WebCore::DataURLDecoder::parseMediaType):
- 1:57 AM Changeset in webkit [241421] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebKit
Merege r241330 - Remove firing assertion after r241317
https://bugs.webkit.org/show_bug.cgi?id=194506
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::setDefersLoading):
The creation of a PageGroupLoadDeferrer in Chrome.cpp tries to defer loading.
See comments in Chrome::runJavaScriptAlert et al.
This was necessary with WebKitLegacy, so keep it, but it doesn't need to do anything in modern WebKit.
- 1:57 AM Changeset in webkit [241420] by
-
- 3 edits2 adds in releases/WebKitGTK/webkit-2.24
Merger r241319 - Remove setDefersLoading infrastructure from WebKit2
https://bugs.webkit.org/show_bug.cgi?id=194506
Patch by Alex Christensen <achristensen@webkit.org> on 2019-02-12
Reviewed by Brady Eidson.
setDefersLoading is inherently racy from WebCore to the NetworkProcess,
it adds unwanted complexity to the initialization and use of network objects,
and it has led to many unrecoverable hang bugs over the years.
We needed to force it into WebKit2 to transition some existing clients who relied on it,
but we have recently finished transitioning those clients to other solutions, mostly
completion handlers.
- inspector/PageScriptDebugServer.cpp:
(WebCore::PageScriptDebugServer::setJavaScriptPaused):
LayoutTests:
BitmapRenderer should handle existing ImageBuffers
https://bugs.webkit.org/show_bug.cgi?id=194555
<rdar://problem/47857150>
Reviewed by Tim Horton.
Test that creates a canvas, triggers an ImageBuffer to be created, then
creates the bitmaprenderer context.
- fast/canvas/bitmaprenderer-created-after-toBlob-expected.txt: Added.
- fast/canvas/bitmaprenderer-created-after-toBlob.html: Added.
- 1:57 AM Changeset in webkit [241419] by
-
- 28 edits in releases/WebKitGTK/webkit-2.24
Merge r241317 - Remove setDefersLoading infrastructure from WebKit2
https://bugs.webkit.org/show_bug.cgi?id=194506
Reviewed by Brady Eidson.
Source/WebCore:
setDefersLoading is inherently racy from WebCore to the NetworkProcess,
it adds unwanted complexity to the initialization and use of network objects,
and it has led to many unrecoverable hang bugs over the years.
We needed to force it into WebKit2 to transition some existing clients who relied on it,
but we have recently finished transitioning those clients to other solutions, mostly
completion handlers.
- inspector/PageScriptDebugServer.cpp:
(WebCore::PageScriptDebugServer::setJavaScriptPaused):
Source/WebKit:
- NetworkProcess/NetworkConnectionToWebProcess.cpp:
(WebKit::NetworkConnectionToWebProcess::setDefersLoading): Deleted.
- NetworkProcess/NetworkConnectionToWebProcess.h:
- NetworkProcess/NetworkConnectionToWebProcess.messages.in:
- NetworkProcess/NetworkDataTask.h:
- NetworkProcess/NetworkDataTaskBlob.cpp:
(WebKit::NetworkDataTaskBlob::suspend): Deleted.
- NetworkProcess/NetworkDataTaskBlob.h:
- NetworkProcess/NetworkLoad.cpp:
(WebKit::NetworkLoad::initialize):
(WebKit::NetworkLoad::setDefersLoading): Deleted.
- NetworkProcess/NetworkLoad.h:
- NetworkProcess/NetworkLoadParameters.h:
- NetworkProcess/NetworkResourceLoadParameters.cpp:
(WebKit::NetworkResourceLoadParameters::encode const):
(WebKit::NetworkResourceLoadParameters::decode):
- NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::start):
(WebKit::NetworkResourceLoader::startNetworkLoad):
(WebKit::NetworkResourceLoader::setDefersLoading): Deleted.
- NetworkProcess/NetworkResourceLoader.h:
- NetworkProcess/cocoa/NetworkDataTaskCocoa.h:
- NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
(WebKit::NetworkDataTaskCocoa::suspend): Deleted.
- NetworkProcess/curl/NetworkDataTaskCurl.cpp:
(WebKit::NetworkDataTaskCurl::suspend): Deleted.
- NetworkProcess/curl/NetworkDataTaskCurl.h:
- NetworkProcess/soup/NetworkDataTaskSoup.cpp:
(WebKit::NetworkDataTaskSoup::suspend): Deleted.
- NetworkProcess/soup/NetworkDataTaskSoup.h:
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
(WebKit::WebLoaderStrategy::setDefersLoading):
Tools:
- WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
- WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::setDefersLoading): Deleted.
- WebKitTestRunner/InjectedBundle/TestRunner.h:
LayoutTests:
- platform/wk2/TestExpectations:
- 1:57 AM Changeset in webkit [241418] by
-
- 6 edits in releases/WebKitGTK/webkit-2.24/Source
Merge r241316 - Unreviewed, fix build warnings after content extensions enablement
https://bugs.webkit.org/show_bug.cgi?id=193622
<rdar://problem/47982850>
Source/WebCore:
- contentextensions/DFABytecode.h:
(WebCore::ContentExtensions::instructionSizeWithArguments):
- contentextensions/DFABytecodeCompiler.h:
- contentextensions/URLFilterParser.cpp:
(WebCore::ContentExtensions::URLFilterParser::statusString):
Source/WebKit:
- UIProcess/API/C/WKUserContentExtensionStoreRef.cpp:
(toResult):
- 1:57 AM Changeset in webkit [241417] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebInspectorUI
Merge r241315 - Web Inspector: Timeline.prototype.recordsInTimeRange uses a property most records do not have
https://bugs.webkit.org/show_bug.cgi?id=194549
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-12
Reviewed by Devin Rousso.
- UserInterface/Models/Timeline.js:
(WI.Timeline.prototype.recordsInTimeRange):
- 1:56 AM Changeset in webkit [241416] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/JavaScriptCore
MNerge r241314 - Unreviewed, fix -Wimplicit-fallthrough warning after r241140
https://bugs.webkit.org/show_bug.cgi?id=194399
<rdar://problem/47889777>
- dfg/DFGDoesGC.cpp:
(JSC::DFG::doesGC):
- 1:56 AM Changeset in webkit [241415] by
-
- 5 edits in releases/WebKitGTK/webkit-2.24/Source
Merge r241308 - Make use of is<SubresourceLoader>
https://bugs.webkit.org/show_bug.cgi?id=194541
Reviewed by Alex Christensen.
Source/WebCore:
No change of behavior.
- inspector/agents/InspectorNetworkAgent.cpp:
(WebCore::InspectorNetworkAgent::didReceiveResponse):
- loader/SubresourceLoader.h:
(isType):
Source/WebKit:
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
- 1:56 AM Changeset in webkit [241414] by
-
- 3 edits in releases/WebKitGTK/webkit-2.24/LayoutTests
Merge r241307 - AX: Fix flaky accessibility/loading-iframe-sends-notification.html
https://bugs.webkit.org/show_bug.cgi?id=194546
Reviewed by Zalan Bujtas.
This test was relying on timing between load events being sent and accessibility events being sent.
We don't need to do that, we can more directly test this interplay.
- accessibility/loading-iframe-sends-notification-expected.txt:
- accessibility/loading-iframe-sends-notification.html:
- 1:56 AM Changeset in webkit [241413] by
-
- 7 edits1 add in releases/WebKitGTK/webkit-2.24
Merge r241306 - WebPage::close needs to remove all message receivers associated with that WebPage, not WebPage::~WebPage
https://bugs.webkit.org/show_bug.cgi?id=194522
<rdar://problem/47789393>
Reviewed by Chris Dumez.
Source/WebKit:
The InjectedBundle SPI can retain the WebPage or wrapping objects (WKWebProcessPlugInBrowserContextController/WKBundlePageRef).
This can make it so WebPage::close is called before WebPage::~WebPage, and if the SuspendedPageProxy is reused for a subsequent
navigation to the same domain, the WebProcess is reused with a different WebPage instance with the same PageID, which causes problems
when another WebPage registers message handlers and then the previous WebPage is destroyed, which removes both message handlers.
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::~WebPage):
(WebKit::WebPage::close):
(WebKit::WebPage::mainFrameDidLayout):
- WebProcess/WebPage/WebPage.h:
- WebProcess/WebProcess.h:
(WebKit::WebProcess::eventDispatcher):
Tools:
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/WebKitCocoa/BundleRetainPagePlugIn.mm: Added.
(-[BundleRetainPagePlugIn webProcessPlugIn:didCreateBrowserContextController:]):
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
- 1:56 AM Changeset in webkit [241412] by
-
- 5 edits in releases/WebKitGTK/webkit-2.24/Source/bmalloc
Merge r241305 - Unreviewed, rolling out r241182.
https://bugs.webkit.org/show_bug.cgi?id=194547
causes a 2-3% Speedometer2 regression. (Requested by
keith_miller on #webkit).
Reverted changeset:
"bmalloc uses more memory on iOS compared to macOS due to
physical page size differences"
https://bugs.webkit.org/show_bug.cgi?id=192389
https://trac.webkit.org/changeset/241182
- 1:56 AM Changeset in webkit [241411] by
-
- 6 edits in releases/WebKitGTK/webkit-2.24/Source
Merge r241304 - [WPE][GTK] Unsafe g_unsetenv() use in WebProcessPool::platformInitialize
https://bugs.webkit.org/show_bug.cgi?id=194370
Reviewed by Darin Adler.
Source/JavaScriptCore:
Change a couple WTFLogAlways to use g_warning, for good measure. Of course this isn't
necessary, but it will make errors more visible.
- inspector/remote/glib/RemoteInspectorGlib.cpp:
(Inspector::RemoteInspector::start):
(Inspector::dbusConnectionCallAsyncReadyCallback):
- inspector/remote/glib/RemoteInspectorServer.cpp:
(Inspector::RemoteInspectorServer::start):
Source/WebKit:
It is incorrect to use g_unsetenv() here because it is MT-Unsafe. We know that it is
impossible and unreasonable to expect the application has not started other threads at this
point, and threads will be calling getenv(). WebKit itself has probably already started
threads of its own.
Fortunately, the remote inspector in the web process is already prepared to deal with
failure to connect to the inspector server, so we don't need to do anything except stop
messing with the environment.
Note these files are copies of each other. I'll merge them together in a follow-up patch.
- UIProcess/gtk/WebProcessPoolGtk.cpp:
(WebKit::initializeRemoteInspectorServer):
(WebKit::WebProcessPool::platformInitialize):
- UIProcess/wpe/WebProcessPoolWPE.cpp:
(WebKit::initializeRemoteInspectorServer):
(WebKit::WebProcessPool::platformInitialize):
- 1:56 AM Changeset in webkit [241410] by
-
- 5 edits in releases/WebKitGTK/webkit-2.24/Source/WebInspectorUI
Merge r241302 - Web Inspector: Timelines: clicking on an empty space in the overview should deselect any selected record bar
https://bugs.webkit.org/show_bug.cgi?id=194365
<rdar://problem/47868426>
Reviewed by Joseph Pecoraro.
- UserInterface/Views/TimelineRecordBar.js:
(WI.TimelineRecordBar.prototype._handleClick):
Mark the "click" event so that later listeners know it was handled byWI.TimelineRecordBar
.
- UserInterface/Views/TimelineOverview.js:
(WI.TimelineOverview):
(WI.TimelineOverview.prototype._instrumentAdded):
(WI.TimelineOverview.prototype._instrumentRemoved):
(WI.TimelineOverview.prototype._handleGraphsContainerClick): Added.
(WI.TimelineOverview.prototype._handleOverviewGraphRecordSelected): Added.
(WI.TimelineOverview.prototype._recordSelected):
Listen for "click" on the graph container and deselect all records when fired, unless the
click was marked by aWI.TimelineRecordBar
.
- UserInterface/Views/TimelineRecordingContentView.js:
(WI.TimelineRecordingContentView.prototype._recordSelected):
Ensure that allWI.TimelineView
update their selected record whenever it changes for any
otherWI.TimelineView
(or if there is no selected record).
- UserInterface/Views/TimelineOverviewGraph.js:
(WI.TimelineOverviewGraph.prototype.didLayoutSubtree): Added.
Drive-by: sinceWI.TimelineRecordBar
are reused when combining, we need to re-determine
which one holds the currently selected record.
- 1:56 AM Changeset in webkit [241409] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebInspectorUI
Merge r241301 - Web Inspector: Remove unused maxUsage in CPUTimelineView
https://bugs.webkit.org/show_bug.cgi?id=194526
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-12
Reviewed by Devin Rousso.
- UserInterface/Views/CPUTimelineView.js:
(WI.CPUTimelineView):
(WI.CPUTimelineView.prototype.shown):
- 1:56 AM Changeset in webkit [241408] by
-
- 4 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241300 - Add some null checks in JSNodeCustom.h's root() and generated isReachableFromOpaqueRoots() functions.
https://bugs.webkit.org/show_bug.cgi?id=194530
<rdar://problem/47973274>
Reviewed by Chris Dumez.
This is needed to fix a null pointer dereference that arises from the following scenario:
- a Document detaches from its StyleSheetList.
- the JSStyleSheetList that is associated with the detached StyleSheetList has yet to be scanned and collected by the GC.
- the GC eventually looks for the opaque root of the StyleSheetList's owner, and discovers a null owner pointer.
This patch fixes this issue by applying the following null checks:
- Add a null check in JSNodeCustom.h's root().
root() is called from a isReachableFromOpaqueRoots() generated by CodeGeneratorJS.pm.
isReachableFromOpaqueRoots() calls a ownerNode() method and passes its result
to root(). However, depending on which class the ownerNode() method belongs to,
it can either return a pointer or a reference. The null check only makes sense
in the pointer case.
To accommodate the 2 forms, root() itself is has an overload that takes a
reference instead of a pointer.
Since CodeGeneratorJS.pm can't tell what the generated class' ownerNode()
returns, it can't discern when the result is a pointer and apply the null check.
Instead, we just add the null check to the version of root() that takes a
pointer. If the node pointer is null, we'll return a null opaque root.
- Fix CodeGeneratorJS.pm to null check the opaque root before using it.
- bindings/js/JSNodeCustom.h:
(WebCore::root):
- bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):
- bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
(WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
- 1:56 AM Changeset in webkit [241407] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/LayoutTests
Merge r241298 - Unreviewed WPE gardening. Unskip content extensions tests after r241283
- platform/wpe/TestExpectations: Unskip content extensions tests, and list
as failing those known to not pass due to missing expectaions or timeouts.
- 1:56 AM Changeset in webkit [241406] by
-
- 2 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241296 - Crash in WebCore::ScrollingTree::updateTreeFromStateNode
https://bugs.webkit.org/show_bug.cgi?id=194538
<rdar://problem/47841926>
Reviewed by Zalan Bujtas.
- page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::updateTreeFromStateNode):
Make sure we don't leave node entry behind in m_nodeMap in case we failed to add it to the parent.
- 1:56 AM Changeset in webkit [241405] by
-
- 5 edits in releases/WebKitGTK/webkit-2.24/Source/WebCore
Merge r241295 - [LFC] Remove redundant InlineFormattingContext::computeBorderAndPadding
https://bugs.webkit.org/show_bug.cgi?id=194540
Reviewed by Antti Koivisto.
Use FormattingContext::computeBorderAndPadding instead.
- layout/FormattingContext.cpp:
(WebCore::Layout::FormattingContext::computeBorderAndPadding const):
- layout/FormattingContext.h:
- layout/inlineformatting/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::computeBorderAndPadding const): Deleted.
- layout/inlineformatting/InlineFormattingContext.h:
- 1:56 AM Changeset in webkit [241404] by
-
- 5 edits in releases/WebKitGTK/webkit-2.24
Merge r241294 - [LFC][IFC] Add intrinsic width support for float boxes.
https://bugs.webkit.org/show_bug.cgi?id=194528
Reviewed by Antti Koivisto.
Source/WebCore:
This patch implements a very simple float box support for intrinsic width.
- layout/inlineformatting/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthConstraints const):
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthForFloatBox const):
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthForInlineBlock const):
(WebCore::Layout::InlineFormattingContext::computeMargin const):
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthForFormattingContextRoot const): Deleted.
- layout/inlineformatting/InlineFormattingContext.h:
Tools:
Expand tests coverage (2 new tests -> 800).
(This is the correct test ordering --runs-singly --child-processes=1)
- LayoutReloaded/misc/LFC-passing-tests.txt:
- 1:12 AM Changeset in webkit [241403] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241131. rdar://problem/47627599
Print backgrounds preference should be honored instead of WKWebViewConfiguration value
https://bugs.webkit.org/show_bug.cgi?id=194364
<rdar://problem/47627599>
Reviewed by Tim Horton.
Without this patch, changing the preference for printing the background has no effect.
This patch fixes that, and I verified it manually by checking "Print backgrounds" in Safari's print menu.
Unfortunately, the only way to test this is actually printing because only values from WebPageProxy::preferences
or WebPageProxy::configuration's preferences are exposed to the API, but values from WebPageProxy::preferencesStore
are used when printing. Actually printing verifies this change fixes the bug.
- UIProcess/API/Cocoa/WKWebView.mm: (-[WKWebView _initializeWithConfiguration:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241131 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:10 AM Changeset in webkit [241402] by
-
- 2 edits in trunk/Source/WebCore
[FreeType] Unable to render some Hebrew characters
https://bugs.webkit.org/show_bug.cgi?id=194498
Reviewed by Michael Catanzaro.
We are failing to find a font for some of the combining character sequences because normalization is failing due
to overflow error. In case of overflow, normalize returns the required length for the normalized characters, so
we should handle that case to resize the output buffer and try again.
- platform/graphics/cairo/FontCairoHarfbuzzNG.cpp:
(WebCore::FontCascade::fontForCombiningCharacterSequence const):
- 1:07 AM Changeset in webkit [241401] by
-
- 2 edits in trunk/Source/WebKit
Crash in Page::setActivityState because m_page is null
https://bugs.webkit.org/show_bug.cgi?id=194584
Reviewed by Antti Koivisto.
Add a null check to avoid the crash. Also add a debug assertion to help diagnose this in the future.
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::setActivityState):
- 1:05 AM Changeset in webkit [241400] by
-
- 32 edits7 adds in branches/safari-608.1.5.1-branch
Cherry-pick r241282. rdar://problem/45929460
[iOS] Mouse/Touch/Pointer events are missing modifier keys
https://bugs.webkit.org/show_bug.cgi?id=191446
<rdar://problem/45929460>
Reviewed by Tim Horton.
Source/WebCore:
Extract the modifier flags from the WebEvent. This code is only used by Legacy WebKit
on iOS and we will need to fix <rdar://problem/47929759> in order for modifier flags
to be passed to WebKit.
Tests: fast/events/touch/ios/mouse-events-with-modifiers.html
fast/events/touch/ios/pointer-events-with-modifiers.html
fast/events/touch/ios/touch-events-with-modifiers.html
- platform/ios/PlatformEventFactoryIOS.mm: (WebCore::PlatformMouseEventBuilder::PlatformMouseEventBuilder):
- platform/ios/WebEvent.h:
- platform/ios/WebEvent.mm: (-[WebEvent initWithMouseEventType:timeStamp:location:]): (-[WebEvent initWithMouseEventType:timeStamp:location:modifiers:]):
Source/WebKit:
Make use of UIKit SPI to retreive the modifier flags when dispatching mouse and touch events.
Add new WebKit SPI for iOS, -[WKNavigationAction modifierFlags], to retrieve the the modifier
flags held when a navigation action was initiated.
- Platform/spi/ios/UIKitSPI.h: Expose SPI.
- Shared/NativeWebTouchEvent.h: Re-arrange macro guards so that we can expose the helper function WebKit::webEventModifierFlags(). This is a bit more involved that usual since this header is included from both C++ and Objective-C source files. It only makes sense to expose this function when compiling as part of an Objective-C source file.
- Shared/ios/NativeWebTouchEventIOS.mm: (WebKit::NativeWebTouchEvent::NativeWebTouchEvent): Modified to take the modifier flags held down when the platform touch event was received and pass them through to the base constructor. (WebKit::webEventModifierFlags): Added. Converts from the platform-speciifc UIKeyModifierFlags to OptionSet<WebKit::WebEvent::Modifier>.
- Shared/ios/WebIOSEventFactory.h:
- Shared/ios/WebIOSEventFactory.mm: (WebIOSEventFactory::toUIKeyModifierFlags): Added. Converts from OptionSet<WebKit::WebEvent::Modifier> to the platform-specific UIKeyModifierFlags.
- UIProcess/API/Cocoa/WKNavigationAction.mm: (-[WKNavigationAction modifierFlags]): Added.
- UIProcess/API/Cocoa/WKNavigationActionPrivate.h:
- UIProcess/WebPageProxy.h:
- UIProcess/ios/WKContentViewInteraction.h:
- UIProcess/ios/WKContentViewInteraction.mm: (gestureRecognizerModifierFlags): Added.
(-[WKContentView _webTouchEventsRecognized:]):
(-[WKContentView _highlightLongPressRecognized:]):
(-[WKContentView _twoFingerSingleTapGestureRecognized:]):
(-[WKContentView _singleTapCommited:]):
Pass modifier flags through.
(-[WKContentView _attemptClickAtLocation:modifierFlags:]): Added.
(-[WKContentView actionSheetAssistant:openElementAtLocation:]): This is invoked when a person opens a link
via the action sheet. We don't have access to the modifier flags to pass. It also seems like an implementation
detail that this action is implemented via mouse click and we should re-evaluate this decision in light of
the fact tht the action sheet is browser UI and we tend to be very reserved on what UI actions are visible
to the page. On Mac, opening a link via the context menu is not visible to the page, at least from a mouse
event perspective.
(webEventFlagsForUIKeyModifierFlags): Added.
(-[WKContentView _hoverGestureRecognizerChanged:]): Pass modifier flags through.
(-[WKContentView _attemptClickAtLocation:]): Deleted.
- UIProcess/ios/WebPageProxyIOS.mm: (WebKit::WebPageProxy::handleTwoFingerTapAtPoint): (WebKit::WebPageProxy::commitPotentialTap): (WebKit::WebPageProxy::handleTap):
- WebProcess/WebPage/WebPage.h:
- WebProcess/WebPage/WebPage.messages.in:
- WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::handleSyntheticClick): (WebKit::WebPage::completePendingSyntheticClickForContentChangeObserver): (WebKit::WebPage::completeSyntheticClick): (WebKit::WebPage::handleTap): (WebKit::WebPage::handleTwoFingerTapAtPoint): (WebKit::WebPage::commitPotentialTap): Pass modifier flags through.
Tools:
Add support infrastructure for testing touch and stylus taps when holding modifier keys.
- DumpRenderTree/ios/UIScriptControllerIOS.mm: (WTR::UIScriptController::singleTapAtPointWithModifiers): Added. (WTR::UIScriptController::stylusTapAtPointWithModifiers): Added.
- TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
- TestRunnerShared/UIScriptContext/UIScriptController.cpp: (WTR::UIScriptController::singleTapAtPointWithModifiers): Added. (WTR::UIScriptController::stylusTapAtPointWithModifiers): Added.
- TestRunnerShared/UIScriptContext/UIScriptController.h:
- WebKitTestRunner/ios/UIScriptControllerIOS.mm: (WTR::arrayLength): (WTR::parseModifierArray): (WTR::UIScriptController::singleTapAtPoint): Implemented in terms of singleTapAtPointWithModifiers(). (WTR::UIScriptController::singleTapAtPointWithModifiers): Added. (WTR::UIScriptController::stylusTapAtPoint): Implemented in terms of stylusTapAtPointWithModifiers(). (WTR::UIScriptController::stylusTapAtPointWithModifiers): Added.
LayoutTests:
Refactor existing iOS key events tests to share code. Add new tests to ensure touch and mouse events
have accurate modifier key details.
- fast/events/ios/key-events-meta-alt-combinations.html:
- fast/events/ios/resources/key-tester.js: (computeSubsets.compareByModifierOrder): Deleted.
- fast/events/resources/compute-subsets.js: Added. (computeSubsets.compareByOriginalArrayOrder): (computeSubsets):
- fast/events/touch/ios/mouse-events-with-modifiers-expected.txt: Added.
- fast/events/touch/ios/mouse-events-with-modifiers.html: Added.
- fast/events/touch/ios/pointer-events-with-modifiers-expected.txt: Added.
- fast/events/touch/ios/pointer-events-with-modifiers.html: Added.
- fast/events/touch/ios/touch-events-with-modifiers-expected.txt: Added.
- fast/events/touch/ios/touch-events-with-modifiers.html: Added.
- http/tests/adClickAttribution/anchor-tag-attributes-validation-expected.txt: Update expected result due to changes to ui-helper.js.
- http/tests/security/anchor-download-block-crossorigin-expected.txt: Ditto.
- platform/ios/TestExpectations:
- resources/ui-helper.js: (window.UIHelper.tapAt.return.new.Promise): (window.UIHelper.tapAt): (window.UIHelper.stylusTapAt.return.new.Promise): (window.UIHelper.stylusTapAt):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241282 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:05 AM Changeset in webkit [241399] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241007. rdar://problem/47836218
Fix a typo in r241006. Substitute Modifier for Modifiers.
- Shared/mac/NativeWebGestureEventMac.mm: (WebKit::NativeWebGestureEvent::NativeWebGestureEvent):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241007 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:05 AM Changeset in webkit [241398] by
-
- 3 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241006. rdar://problem/47836218
Attempt to fix the build following r241000
(https://bugs.webkit.org/show_bug.cgi?id=194241)
Substitute OptionSet<WebEvent::Modifier> for Modifiers.
- Shared/mac/NativeWebGestureEventMac.mm: (WebKit::NativeWebGestureEvent::NativeWebGestureEvent):
- Shared/mac/WebGestureEvent.h: (WebKit::WebGestureEvent::WebGestureEvent):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241006 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241397] by
-
- 8 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241001. rdar://problem/47836218
Attempt to fix the build following r241000
(https://bugs.webkit.org/show_bug.cgi?id=194241)
Substitute WebEvent::Modifier::CapsLockKey for WebEvent::CapsLockKey.
- Shared/gtk/WebEventFactory.cpp: (WebKit::modifiersForEvent):
- Shared/mac/WebEventFactory.mm: (WebKit::modifiersForEvent):
- UIProcess/API/Cocoa/WKNavigationAction.mm: (toNSEventModifierFlags):
- UIProcess/Automation/WebAutomationSession.cpp: (WebKit::protocolModifierToWebEventModifier):
- UIProcess/Automation/gtk/WebAutomationSessionGtk.cpp: (WebKit::modifiersToEventState):
- UIProcess/Automation/mac/WebAutomationSessionMac.mm: (WebKit::WebAutomationSession::platformSimulateMouseInteraction):
- UIProcess/Cocoa/UIDelegate.mm: (WebKit::toNSEventModifierFlags):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241001 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241396] by
-
- 43 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241000. rdar://problem/47836218
Make WebEvent::Modifiers an OptionSet
https://bugs.webkit.org/show_bug.cgi?id=194241
Reviewed by Simon Fraser.
Use an OptionSet to represent the bitmask of keyboard modifier flags. This improves type safety
and makes debugging more enjoyable because our LLDB pretty-printers have built-in support for
OptionSet.
While I am at it, make WebEvent::Modifier an enum class. It is currently an enum. This makes
this enum more closely match WebCore::PlatformEvent::Modifier.
- Shared/API/c/WKSharedAPICast.h: (WebKit::toAPI):
- Shared/NavigationActionData.cpp: (WebKit::NavigationActionData::encode const): (WebKit::NavigationActionData::decode):
- Shared/NavigationActionData.h:
- Shared/WebEvent.cpp: (WebKit::WebEvent::WebEvent):
- Shared/WebEvent.h: (WebKit::WebEvent::shiftKey const): (WebKit::WebEvent::controlKey const): (WebKit::WebEvent::altKey const): (WebKit::WebEvent::metaKey const): (WebKit::WebEvent::capsLockKey const): (WebKit::WebEvent::modifiers const): (WebKit::WebTouchEvent::WebTouchEvent):
- Shared/WebEventConversion.cpp: (WebKit::WebKit2PlatformMouseEvent::WebKit2PlatformMouseEvent):
- Shared/WebKeyboardEvent.cpp: (WebKit::WebKeyboardEvent::WebKeyboardEvent):
- Shared/WebMouseEvent.cpp: (WebKit::WebMouseEvent::WebMouseEvent):
- Shared/WebTouchEvent.cpp: (WebKit::WebTouchEvent::WebTouchEvent):
- Shared/WebWheelEvent.cpp: (WebKit::WebWheelEvent::WebWheelEvent):
- Shared/gtk/WebEventFactory.cpp: (WebKit::modifiersForEvent):
- Shared/ios/NativeWebTouchEventIOS.mm: (WebKit::NativeWebTouchEvent::NativeWebTouchEvent):
- Shared/ios/WebIOSEventFactory.mm: (modifiersForEvent): (WebIOSEventFactory::createWebKeyboardEvent): (WebIOSEventFactory::createWebMouseEvent):
- Shared/libwpe/WebEventFactory.cpp: (WebKit::modifiersForEventModifiers): (WebKit::WebEventFactory::createWebWheelEvent): (WebKit::WebEventFactory::createWebTouchEvent):
- Shared/mac/WebEventFactory.mm: (WebKit::modifiersForEvent): (WebKit::WebEventFactory::createWebMouseEvent): (WebKit::WebEventFactory::createWebWheelEvent): (WebKit::WebEventFactory::createWebKeyboardEvent):
- Shared/win/WebEventFactory.cpp: (WebKit::modifiersForEvent): (WebKit::modifiersForCurrentKeyState): (WebKit::WebEventFactory::createWebMouseEvent): (WebKit::WebEventFactory::createWebWheelEvent): (WebKit::WebEventFactory::createWebKeyboardEvent):
- UIProcess/API/APINavigationAction.h:
- UIProcess/API/APIUIClient.h: (API::UIClient::mouseDidMoveOverElement):
- UIProcess/API/C/WKPage.cpp: (WKPageSetPageUIClient):
- UIProcess/API/Cocoa/WKNavigationAction.mm: (toNSEventModifierFlags):
- UIProcess/API/glib/WebKitPrivate.cpp: (toPlatformModifiers):
- UIProcess/API/glib/WebKitPrivate.h:
- UIProcess/API/glib/WebKitUIClient.cpp:
- UIProcess/API/glib/WebKitWebView.cpp: (webkitWebViewMouseTargetChanged):
- UIProcess/API/glib/WebKitWebViewPrivate.h:
- UIProcess/Automation/WebAutomationSession.cpp: (WebKit::WebAutomationSession::simulateMouseInteraction): (WebKit::protocolModifierToWebEventModifier): (WebKit::WebAutomationSession::performMouseInteraction):
- UIProcess/Automation/WebAutomationSession.h:
- UIProcess/Automation/gtk/WebAutomationSessionGtk.cpp: (WebKit::modifiersToEventState): (WebKit::WebAutomationSession::platformSimulateMouseInteraction):
- UIProcess/Automation/mac/WebAutomationSessionMac.mm: (WebKit::WebAutomationSession::platformSimulateMouseInteraction):
- UIProcess/Automation/wpe/WebAutomationSessionWPE.cpp: (WebKit::modifiersToEventState): (WebKit::WebAutomationSession::platformSimulateMouseInteraction):
- UIProcess/Cocoa/UIDelegate.h:
- UIProcess/Cocoa/UIDelegate.mm: (WebKit::toNSEventModifierFlags): (WebKit::UIDelegate::UIClient::mouseDidMoveOverElement):
- UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::mouseDidMoveOverElement):
- WebProcess/InjectedBundle/API/APIInjectedBundlePageUIClient.h: (API::InjectedBundle::PageUIClient::mouseDidMoveOverElement):
- WebProcess/InjectedBundle/InjectedBundleNavigationAction.cpp: (WebKit::InjectedBundleNavigationAction::modifiersForNavigationAction):
- WebProcess/InjectedBundle/InjectedBundleNavigationAction.h: (WebKit::InjectedBundleNavigationAction::modifiers const):
- WebProcess/InjectedBundle/InjectedBundlePageUIClient.cpp: (WebKit::InjectedBundlePageUIClient::mouseDidMoveOverElement):
- WebProcess/InjectedBundle/InjectedBundlePageUIClient.h:
- WebProcess/Plugins/PDF/PDFPlugin.mm: (WebKit::PDFPlugin::showContextMenuAtPoint):
- WebProcess/Plugins/PluginView.cpp: (WebKit::PluginView::createWebEvent const):
- WebProcess/WebCoreSupport/WebChromeClient.cpp: (WebKit::WebChromeClient::mouseDidMoveOverElement):
- WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::simulateMouseDown): (WebKit::WebPage::simulateMouseUp): (WebKit::WebPage::simulateMouseMotion):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241000 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241395] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241332. rdar://problem/47974770
[iOS] Youtube fails to play.
https://bugs.webkit.org/show_bug.cgi?id=194565
<rdar://problem/47974770>
Reviewed by Geoffrey Garen.
This is caused by sandbox violations and was introduced in r240500.
- Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241332 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241394] by
-
- 5 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241323. rdar://problem/42087017
Find on Page shouldn't zoom in on matches
https://bugs.webkit.org/show_bug.cgi?id=194557
<rdar://problem/42087017>
Reviewed by Wenson Hsieh.
- UIProcess/ios/SmartMagnificationController.h:
- UIProcess/ios/SmartMagnificationController.messages.in:
- UIProcess/ios/SmartMagnificationController.mm: (WebKit::SmartMagnificationController::scrollToRect):
- WebProcess/WebPage/ios/FindControllerIOS.mm: (WebKit::FindController::updateFindIndicator): Only scroll to reveal the find result, do not zoom in.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241323 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241393] by
-
- 3 edits2 adds in branches/safari-608.1.5.1-branch
Cherry-pick r241319. rdar://problem/47857150
Source/WebCore:
Remove setDefersLoading infrastructure from WebKit2
https://bugs.webkit.org/show_bug.cgi?id=194506
Patch by Alex Christensen <achristensen@webkit.org> on 2019-02-12
Reviewed by Brady Eidson.
setDefersLoading is inherently racy from WebCore to the NetworkProcess,
it adds unwanted complexity to the initialization and use of network objects,
and it has led to many unrecoverable hang bugs over the years.
We needed to force it into WebKit2 to transition some existing clients who relied on it,
but we have recently finished transitioning those clients to other solutions, mostly
completion handlers.
- inspector/PageScriptDebugServer.cpp: (WebCore::PageScriptDebugServer::setJavaScriptPaused):
LayoutTests:
BitmapRenderer should handle existing ImageBuffers
https://bugs.webkit.org/show_bug.cgi?id=194555
<rdar://problem/47857150>
Reviewed by Tim Horton.
Test that creates a canvas, triggers an ImageBuffer to be created, then
creates the bitmaprenderer context.
- fast/canvas/bitmaprenderer-created-after-toBlob-expected.txt: Added.
- fast/canvas/bitmaprenderer-created-after-toBlob.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241319 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241392] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/JavaScriptCore
Cherry-pick r241314. rdar://problem/47889777
Unreviewed, fix -Wimplicit-fallthrough warning after r241140
https://bugs.webkit.org/show_bug.cgi?id=194399
<rdar://problem/47889777>
- dfg/DFGDoesGC.cpp: (JSC::DFG::doesGC):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241314 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241391] by
-
- 7 edits in branches/safari-608.1.5.1-branch/Source
Cherry-pick r241309. rdar://problem/47924449
REGRESSION (r238955, r240494): Soft-linking optional Lookup.framework triggers release assertion when missing
<https://webkit.org/b/194529>
<rdar://problem/47924449>
Reviewed by Eric Carlson.
Source/WebCore:
- SourcesCocoa.txt:
- Do not include DataDetectorsCoreSoftLink.mm in unified sources.
- WebCore.xcodeproj/project.pbxproj:
- Add DataDetectorsCoreSoftLink.mm to the WebCore target now that it isn't part of the unifed sources.
- platform/cocoa/DataDetectorsCoreSoftLink.mm:
- Switch from using SOFT_LINK_PRIVATE_FRAMEWORK_OPTIONAL() to SOFT_LINK_PRIVATE_FRAMEWORK_FOR_SOURCE() when linking DataDetectorsCore.framework. None of the other macros assume this framework is optional, and it was likely made optional originally because the framework was new to iOS and thus didn't exist on older versions.
- platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
- Change use of SOFT_LINK_CLASS_FOR_SOURCE() macros to SOFT_LINK_CLASS() since the latter can only be used with SOFT_LINK_FRAMEWORK_OPTIONAL(AVFoundation). This broke after the fix for <wtf/SoftLinking.h> was applied.
Source/WTF:
- wtf/cocoa/SoftLinking.h:
(SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT_AND_IS_OPTIONAL): Rename
SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT_AND_ASSERTION() to this
and change
assertion
argument toisOptional
. PassisOptional
to framework##Library() method to control assertion behavior. Only check RELEASE_ASSERT() if!isOptional
, else that code should be optimized out by the compiler. This fixes the crash. (NO_ASSERT): Remove macro since it's no longer used. (SOFT_LINK_IS_OPTIONAL): Add macro to use for soft-linking optional classes. (SOFT_LINK_IS_NOT_OPTIONAL): Add macro to use for soft-linking non-optional classes. (SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT): Update to use new SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT_AND_IS_OPTIONAL() macro. (SOFT_LINK_CLASS_FOR_SOURCE_OPTIONAL_WITH_EXPORT): Ditto. (SOFT_LINK_CLASS_FOR_SOURCE): Ditto. (SOFT_LINK_CLASS_FOR_SOURCE_OPTIONAL): Ditto.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241309 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241390] by
-
- 4 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241300. rdar://problem/47973274
Add some null checks in JSNodeCustom.h's root() and generated isReachableFromOpaqueRoots() functions.
https://bugs.webkit.org/show_bug.cgi?id=194530
<rdar://problem/47973274>
Reviewed by Chris Dumez.
This is needed to fix a null pointer dereference that arises from the following scenario:
- a Document detaches from its StyleSheetList.
- the JSStyleSheetList that is associated with the detached StyleSheetList has yet to be scanned and collected by the GC.
- the GC eventually looks for the opaque root of the StyleSheetList's owner, and discovers a null owner pointer.
This patch fixes this issue by applying the following null checks:
- Add a null check in JSNodeCustom.h's root().
root() is called from a isReachableFromOpaqueRoots() generated by CodeGeneratorJS.pm.
isReachableFromOpaqueRoots() calls a ownerNode() method and passes its result
to root(). However, depending on which class the ownerNode() method belongs to,
it can either return a pointer or a reference. The null check only makes sense
in the pointer case.
To accommodate the 2 forms, root() itself is has an overload that takes a
reference instead of a pointer.
Since CodeGeneratorJS.pm can't tell what the generated class' ownerNode()
returns, it can't discern when the result is a pointer and apply the null check.
Instead, we just add the null check to the version of root() that takes a
pointer. If the node pointer is null, we'll return a null opaque root.
- Fix CodeGeneratorJS.pm to null check the opaque root before using it.
- bindings/js/JSNodeCustom.h: (WebCore::root):
- bindings/scripts/CodeGeneratorJS.pm: (GenerateImplementation):
- bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp: (WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241300 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241389] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241296. rdar://problem/47841926
Crash in WebCore::ScrollingTree::updateTreeFromStateNode
https://bugs.webkit.org/show_bug.cgi?id=194538
<rdar://problem/47841926>
Reviewed by Zalan Bujtas.
- page/scrolling/ScrollingTree.cpp: (WebCore::ScrollingTree::updateTreeFromStateNode):
Make sure we don't leave node entry behind in m_nodeMap in case we failed to add it to the parent.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241296 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241388] by
-
- 11 edits in branches/safari-608.1.5.1-branch
Cherry-pick r241289. rdar://problem/37018386
AXObjectCache::childrenChanged shouldn't update layout or style during another style recalc
https://bugs.webkit.org/show_bug.cgi?id=182280
<rdar://problem/37018386>
Reviewed by Alan Bujtas.
Source/WebCore:
Remove the possibility that changing children calls back into updating layout by
handling children changes in a deferred manner.
This follows the same architecture as many other deferred changes, but also requires us to check deferred changes
in updateBackingStore, because things like aria-hidden changes won't trigger a layout, but will require us to update children.
A few tests had to be modified to no longer change the tree and then check the children immediately.
- accessibility/AXObjectCache.cpp: (WebCore::AXObjectCache::remove): (WebCore::AXObjectCache::childrenChanged): (WebCore::AXObjectCache::prepareForDocumentDestruction): (WebCore::AXObjectCache::performDeferredCacheUpdate):
- accessibility/AXObjectCache.h:
- accessibility/AccessibilityObject.cpp: (WebCore::AccessibilityObject::updateBackingStore):
- accessibility/mac/WebAccessibilityObjectWrapperBase.mm: (convertToNSArray): (-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
LayoutTests:
- accessibility/aria-hidden-update.html:
- accessibility/aria-hidden-updates-alldescendants.html:
- accessibility/image-load-on-delay.html:
- accessibility/mac/aria-hidden-changes-for-non-ignored-elements.html:
- accessibility/removed-anonymous-block-child-causes-crash.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241289 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241387] by
-
- 25 edits2 adds2 deletes in branches/safari-608.1.5.1-branch
Cherry-pick r241288. rdar://problem/41892438
[Cocoa] Ask platform for generic font family mappings
https://bugs.webkit.org/show_bug.cgi?id=187723
<rdar://problem/41892438>
Reviewed by Brent Fulgham.
Source/WebCore:
WebKit API allows setting the generic font families for the USCRIPT_COMMON script.
When trying to style a character with a generic font family, we first look to see if
we have a mapping for the particular script the character is rendered with, and if we
don't find a match, we then check USCRIPT_COMMON.
In the Cocoa ports, the only way families get set for non-USCRIPT_COMMON scripts (aka
the only scripts which won't use the API families) is in
SettingsBase::initializeDefaultFontFamilies(). That function only sets the families
for the CJK scripts.
The mappings inside SettingsBase are incorrect and conflict with our policy regarding
user-installed fonts. Instead, we should be consulting with the platform for some of
these mappings, by calling CTFontDescriptorCreateForCSSFamily(). However, the WebKit
API still has to work to set the mappings for untagged content. Therefore, we use the
system mappings for language-tagged content, and the API mappings for non-language-tagged
content. This is a good balance that makes sure we always have a good mapping for every
language, but API clients can still set the mappings, too.
Test: fast/text/ja-sans-serif.html
- css/CSSComputedStyleDeclaration.cpp:
- css/CSSFontSelector.cpp: (WebCore::resolveGenericFamily):
- css/parser/CSSPropertyParser.cpp: (WebCore::consumeFontFamily):
- page/cocoa/SettingsBaseCocoa.mm: (WebCore::SettingsBase::initializeDefaultFontFamilies): (WebCore::osakaMonoIsInstalled): Deleted.
- platform/graphics/FontDescription.cpp: (WebCore::FontDescription::platformResolveGenericFamily):
- platform/graphics/FontDescription.h:
- platform/graphics/cocoa/FontDescriptionCocoa.cpp: (WebCore::computeSpecializedChineseLocale): (WebCore::cachedSpecializedChineseLocale): (WebCore::languageChanged): (WebCore::FontDescription::platformResolveGenericFamily):
- platform/graphics/cocoa/SystemFontDatabaseCoreText.cpp: (WebCore::SystemFontDatabaseCoreText::clear): (WebCore::genericFamily): (WebCore::SystemFontDatabaseCoreText::serifFamily): (WebCore::SystemFontDatabaseCoreText::sansSerifFamily): (WebCore::SystemFontDatabaseCoreText::cursiveFamily): (WebCore::SystemFontDatabaseCoreText::fantasyFamily): (WebCore::SystemFontDatabaseCoreText::monospaceFamily):
- platform/graphics/cocoa/SystemFontDatabaseCoreText.h:
Source/WebCore/PAL:
- pal/spi/cocoa/CoreTextSPI.h:
Source/WTF:
Add an ENABLE in Platform.
- wtf/Platform.h:
Tools:
Allow testing infrastructure to use fonts that are returned from CTFontDescriptorCreateForCSSFamily().
- DumpRenderTree/mac/DumpRenderTree.mm: (allowedFontFamilySet):
- WebKitTestRunner/mac/TestControllerMac.mm: (WTR::allowedFontFamilySet):
LayoutTests:
Update the tests to work with this new model.
- fast/text/international/font-fallback-to-common-script-expected.html: Removed.
- fast/text/international/font-fallback-to-common-script.html: Removed.
- fast/text/international/lang-sensitive-fonts-expected.html:
- fast/text/international/lang-sensitive-fonts-xml-expected.html:
- fast/text/international/lang-sensitive-fonts-xml.xhtml:
- fast/text/international/lang-sensitive-fonts.html:
- fast/text/international/locale-sensitive-fonts-expected.html:
- fast/text/international/locale-sensitive-fonts.html:
- fast/text/ja-sans-serif-expected-mismatch.html: Added.
- fast/text/ja-sans-serif.html: Added.
- platform/ios/fast/block/float/016-expected.txt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241288 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241386] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/JavaScriptCore
Cherry-pick r241267. rdar://problem/36380852
Remove the RELEASE_ASSERT check for duplicate cases in the BinarySwitch constructor.
https://bugs.webkit.org/show_bug.cgi?id=194493
<rdar://problem/36380852>
Reviewed by Yusuke Suzuki.
Having duplicate cases in the BinarySwitch is not a correctness issue. It is
however not good for performance and memory usage. As such, a debug ASSERT will
do. We'll also do an audit of the clients of BinarySwitch to see if it's
possible to be instantiated with duplicate cases in
https://bugs.webkit.org/show_bug.cgi?id=194492 later.
Also added some value dumps to the RELEASE_ASSERT to help debug the issue when we
see duplicate cases.
- jit/BinarySwitch.cpp: (JSC::BinarySwitch::BinarySwitch):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241267 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241385] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241231. rdar://problem/42423999
[Cocoa] CTLineGetGlyphRuns() might return nullptr
https://bugs.webkit.org/show_bug.cgi?id=194467
<rdar://problem/42423999>
Reviewed by Simon Fraser.
Be somewhat defensive to try to make sure this sort of thing doesn't happen in the future.
Covered by find/text/find-backwards.html
- platform/graphics/mac/ComplexTextControllerCoreText.mm: (WebCore::ComplexTextController::collectComplexTextRunsForCharacters):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241231 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241384] by
-
- 14 edits1 add in branches/safari-608.1.5.1-branch
Cherry-pick r241228. rdar://problem/47844327
Nodes that rely on being dominated by CheckInBounds should have a child edge to it
https://bugs.webkit.org/show_bug.cgi?id=194334
<rdar://problem/47844327>
Reviewed by Mark Lam.
JSTests:
- stress/check-in-bounds-should-be-a-child-use.js: Added. (func):
Source/JavaScriptCore:
- dfg/DFGAbstractInterpreterInlines.h: (JSC::DFG::AbstractInterpreter<AbstractStateType>::executeEffects):
- dfg/DFGArgumentsEliminationPhase.cpp:
- dfg/DFGByteCodeParser.cpp: (JSC::DFG::ByteCodeParser::parseBlock):
- dfg/DFGClobberize.h: (JSC::DFG::clobberize):
- dfg/DFGConstantFoldingPhase.cpp: (JSC::DFG::ConstantFoldingPhase::foldConstants):
- dfg/DFGFixupPhase.cpp: (JSC::DFG::FixupPhase::fixupNode): (JSC::DFG::FixupPhase::convertToHasIndexedProperty):
- dfg/DFGIntegerCheckCombiningPhase.cpp: (JSC::DFG::IntegerCheckCombiningPhase::handleBlock):
- dfg/DFGIntegerRangeOptimizationPhase.cpp:
- dfg/DFGNodeType.h:
- dfg/DFGSSALoweringPhase.cpp: (JSC::DFG::SSALoweringPhase::lowerBoundsCheck):
- dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::compileHasIndexedProperty):
- ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileCheckInBounds): (JSC::FTL::DFG::LowerDFGToB3::compileHasIndexedProperty):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241228 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:04 AM Changeset in webkit [241383] by
-
- 4 edits in branches/safari-608.1.5.1-branch/Source/JavaScriptCore
Cherry-pick r241210. rdar://problem/47926792
Fix DFG's doesGC() for CheckTierUp*, GetByVal, PutByVal*, and StringCharAt nodes.
https://bugs.webkit.org/show_bug.cgi?id=194446
<rdar://problem/47926792>
Reviewed by Saam Barati.
Fix doesGC() for the following nodes:
CheckTierUpAtReturn:
Calls triggerTierUpNow(), which calls triggerFTLReplacementCompile(),
which calls Worklist::completeAllReadyPlansForVM(), which uses DeferGC.
CheckTierUpInLoop:
Calls triggerTierUpNowInLoop(), which calls tierUpCommon(), which calls
Worklist::completeAllReadyPlansForVM(), which uses DeferGC.
CheckTierUpAndOSREnter:
Calls triggerOSREntryNow(), which calls tierUpCommon(), which calls
Worklist::completeAllReadyPlansForVM(), which uses DeferGC.
GetByVal:
case Array::String calls operationSingleCharacterString(), which calls
jsSingleCharacterString(), which can allocate a string.
PutByValDirect:
PutByVal:
PutByValAlias:
For the DFG only, the integer TypeArrays calls compilePutByValForIntTypedArray(),
which may call slow paths operationPutByValDirectStrict(), operationPutByValDirectNonStrict(),
operationPutByValStrict(), or operationPutByValNonStrict(). All of these
slow paths call putByValInternal(), which may create exception objects, or
call the generic JSValue::put() which may execute arbitrary code.
StringCharAt:
Can call operationSingleCharacterString(), which calls jsSingleCharacterString(),
which can allocate a string.
Also fix DFG::SpeculativeJIT::compileGetByValOnString() and FTL's compileStringCharAt()
to use the maxSingleCharacterString constant instead of a literal constant.
- dfg/DFGDoesGC.cpp: (JSC::DFG::doesGC):
- dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::compileGetByValOnString):
- dfg/DFGSpeculativeJIT64.cpp: (JSC::DFG::SpeculativeJIT::compile):
- ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileGetByVal): (JSC::FTL::DFG::LowerDFGToB3::compilePutByVal): (JSC::FTL::DFG::LowerDFGToB3::compileStringCharAt):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241210 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241382] by
-
- 5 edits in branches/safari-608.1.5.1-branch
Cherry-pick r241203. rdar://problem/47791087
[WebVTT] Inline WebVTT styles should start with '::cue'
https://bugs.webkit.org/show_bug.cgi?id=194227
<rdar://problem/47791087>
Reviewed by Eric Carlson.
Source/WebCore:
Check that the CSS string starts with '::cue' and is successfully parsed before adding it
to the CSS stylesheet list. Also, the caption preferences CSS string should start with
'::cue', since it is added inside the video shadow root element.
Test: media/track/track-cue-css.html
- html/track/WebVTTParser.cpp: (WebCore::WebVTTParser::checkAndStoreStyleSheet):
- page/CaptionUserPreferencesMediaAF.cpp: (WebCore::CaptionUserPreferencesMediaAF::captionsStyleSheetOverride const):
LayoutTests:
- media/track/captions-webvtt/css-styling.vtt:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241203 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241381] by
-
- 10 edits in branches/safari-608.1.5.1-branch
Cherry-pick r241200. rdar://problem/47916514
Running RTCRtpSender.getCapabilities("video") before initial offer breaks VP8
https://bugs.webkit.org/show_bug.cgi?id=194380
<rdar://problem/47916514>
Reviewed by Eric Carlson.
Source/WebCore:
Set whether VP8 is supported at creation of the page.
This ensures that any call creating a peer connection factory will end up supporting the runtime flag configuration.
Add internal API to enable resetting the factory to enable proper testing.
Covered by updated test.
- Modules/mediastream/libwebrtc/LibWebRTCPeerConnectionBackend.cpp: (WebCore::createLibWebRTCPeerConnectionBackend):
- page/Page.cpp: (WebCore::m_applicationManifest):
- platform/mediastream/libwebrtc/LibWebRTCProvider.h:
- testing/Internals.cpp: (WebCore::Internals::clearPeerConnectionFactory):
- testing/Internals.h:
- testing/Internals.idl:
LayoutTests:
- webrtc/video-mute-vp8-expected.txt:
- webrtc/video-mute-vp8.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241200 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241380] by
-
- 6 edits in branches/safari-608.1.5.1-branch
Cherry-pick r241198. rdar://problem/35983035
[WebIDL] Support serializing sequences and FrozenArrays of non-interfaces
https://bugs.webkit.org/show_bug.cgi?id=190997
<rdar://problem/35983035>
Reviewed by Brent Fulgham.
Source/WebCore:
Support serializing sequences and FrozenArrays of types that aren't interfaces. This is
needed to properly serialize PaymentAddress, which has a FrozenArray of DOMStrings.
We should support serializing sequences of interfaces too, but that's slightly more
complicated since it involves iterating the sequence and serializing each of its items. I
left that as a follow-up task, since I don't see any IDLs that currently need this.
We also don't support serializing sequences with the CachedAttribute or CustomGetter
extended attributes, because WebIDL specifies that a new array should be created when
converting an IDL sequence into an ECMAScript value.
Added bindings test cases to TestSerialization.idl and PaymentAddress test cases to
http/tests/paymentrequest/payment-address-attributes-and-toJSON-method.https.html.
- bindings/scripts/CodeGenerator.pm: (GetInterfaceForType): Renamed from GetInterfaceForAttribute. (IsSerializableType): Modified to allow sequences and FrozenArrays of non-interface types. (hasCachedAttributeOrCustomGetterExtendedAttribute): Added a helper to determine if an attribute has the CachedAttribute or CustomGetter extended attributes. (IsSerializableAttribute): Checked for sequences with the CachedAttribute or CustomGetter extended attributes before calling IsSerializableType. (GetInterfaceForAttribute): Renamed to GetInterfaceForType.
- bindings/scripts/test/JS/JSTestSerialization.cpp:
- bindings/scripts/test/TestSerialization.idl:
LayoutTests:
- http/tests/paymentrequest/payment-address-attributes-and-toJSON-method.https.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241198 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241379] by
-
- 3 edits2 adds in branches/safari-608.1.5.1-branch
Cherry-pick r241171. rdar://problem/47550281
[iOS] Clicking links in Safari using Apple Pencil is much more difficult after r238475
https://bugs.webkit.org/show_bug.cgi?id=194415
<rdar://problem/47550281>
Reviewed by Tim Horton.
Source/WebKit:
Fix the bug by not firing the Apple-pencil-exclusive tap gesture recognizer in the case where editable images
are disabled. This gesture recognizer is only used for inserting editable images, and currently conflicts with
the synthetic click gesture recognizer used to recognize clicks from generic digitizer inputs.
- UIProcess/ios/WKContentViewInteraction.mm: (-[WKContentView gestureRecognizerShouldBegin:]): (-[WKContentView _stylusSingleTapRecognized:]):
LayoutTests:
Add a layout test to verify that a stylus tap dispatches clicks.
- fast/events/touch/ios/pencil-tap-dispatches-click-expected.txt: Added.
- fast/events/touch/ios/pencil-tap-dispatches-click.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241171 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241378] by
-
- 3 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241170. rdar://problem/47858241
REGRESSION(r239887): Crash under IDBConnectionToClient::didDeleteDatabase(WebCore::IDBResultData const&)
https://bugs.webkit.org/show_bug.cgi?id=194402
<rdar://problem/47858241>
Reviewed by Geoffrey Garen.
r239887 removed a reference cycle of IDBConnectionToClient so that IDBConnectionToClient would no longer be
around forever. Therefore, ServerOpenRequest should keep a reference to IDBConnectionToClient to make sure it
is valid during access.
- Modules/indexeddb/server/ServerOpenDBRequest.cpp: (WebCore::IDBServer::ServerOpenDBRequest::maybeNotifyRequestBlocked): (WebCore::IDBServer::ServerOpenDBRequest::notifyDidDeleteDatabase):
- Modules/indexeddb/server/ServerOpenDBRequest.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241170 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241377] by
-
- 11 edits in branches/safari-608.1.5.1-branch
Cherry-pick r241150. rdar://problem/45991585
Overflow element scrollbar is light for dark mode content.
https://bugs.webkit.org/show_bug.cgi?id=194407
rdar://problem/45991585
Reviewed by Beth Dakin.
Source/WebCore:
Tested by css-dark-mode/supported-color-schemes-scrollbar.html.
- page/ChromeClient.h: (WebCore::FrameView::preferredScrollbarOverlayStyle): Return WTF::nullopt by default to avoid short-circuiting auto detection in recalculateScrollbarOverlayStyle() for clients, like WK1, that do not implement preferredScrollbarOverlayStyle().
- page/FrameView.cpp: (WebCore::FrameView::recalculateScrollbarOverlayStyle): Use WTF::nullopt in the false case to auto detect overlay style when page() is null.
- rendering/RenderLayer.cpp: (WebCore::RenderLayer::useDarkAppearance const): Added.
- rendering/RenderLayer.h:
- testing/Internals.cpp: (WebCore::Internals::scrollbarOverlayStyle const): Added Node argument. (WebCore::Internals::scrollbarUsingDarkAppearance const): Added.
- testing/Internals.h:
- testing/Internals.idl:
LayoutTests:
Updated tests to look at overflow elements and if dark apearance
is used by the scrollbar directly.
- css-dark-mode/supported-color-schemes-scrollbar-expected.txt:
- css-dark-mode/supported-color-schemes-scrollbar.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241150 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241376] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241143. rdar://problem/47820615
Permit additional IOKit Properties needed by Media PlugIns on older Mac Hardware
https://bugs.webkit.org/show_bug.cgi?id=194412
<rdar://problem/47820615>
Reviewed by Per Arne Vollan.
- PluginProcess/mac/com.apple.WebKit.plugin-common.sb.in:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241143 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241375] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241142. rdar://problem/47820620
Permit additional IOKit Properties needed by older Mac Hardware
https://bugs.webkit.org/show_bug.cgi?id=194410
<rdar://problem/47820620>
Reviewed by Per Arne Vollan.
- WebProcess/com.apple.WebProcess.sb.in:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241142 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241374] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/JavaScriptCore
Cherry-pick r241140. rdar://problem/47889777
Fix more doesGC() for CheckTraps, GetMapBucket, and Switch nodes.
https://bugs.webkit.org/show_bug.cgi?id=194399
<rdar://problem/47889777>
Reviewed by Yusuke Suzuki.
Fix doesGC() for the following nodes:
CheckTraps:
We normally will not emit this node because Options::usePollingTraps() is
false by default. However, as it is implemented now, CheckTraps can GC
because it can allocate a TerminatedExecutionException. If we make the
TerminatedExecutionException a singleton allocated at initialization time,
doesGC() can return false for CheckTraps.
https://bugs.webkit.org/show_bug.cgi?id=194323
GetMapBucket:
Can call operationJSMapFindBucket() or operationJSSetFindBucket(),
which calls HashMapImpl::findBucket(), which calls jsMapHash(), which
can resolve a rope.
Switch:
If switchData kind is SwitchChar, can call operationResolveRope() .
If switchData kind is SwitchString and the child use kind is not StringIdentUse,
can call operationSwitchString() which resolves ropes.
DirectTailCall:
ForceOSRExit:
Return:
TailCallForwardVarargs:
TailCallVarargs:
Throw:
These are terminal nodes. It shouldn't really matter what doesGC() returns
for them, but following our conservative practice, unless we have a good
reason for doesGC() to return false, we should just return true.
- dfg/DFGDoesGC.cpp: (JSC::DFG::doesGC):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241140 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241373] by
-
- 5 edits2 adds in branches/safari-608.1.5.1-branch
Cherry-pick r241137. rdar://problem/47259025
Unable to sign in leetcode.
https://bugs.webkit.org/show_bug.cgi?id=194366
rdar://problem/47259025.
Reviewed by Chris Dumez.
Source/WebCore:
In case a signal is passed as part of a FetchRequestInit,
the IDL binding code is throwing an exception in case signal is not an AbortSignal object.
This breaks an AbortSignal shim used in some web sites.
Relaxed the IDL binding rule by marking signal as any and doing the conversion in FetchRequest.
Test: http/wpt/fetch/request-abort.html
Also covered by manually signing in to leetcode.
- Modules/fetch/FetchRequest.cpp: (WebCore::FetchRequest::initializeWith):
- Modules/fetch/FetchRequestInit.h: (WebCore::FetchRequestInit::hasMembers const):
- Modules/fetch/FetchRequestInit.idl:
LayoutTests:
- http/wpt/fetch/request-abort-expected.txt: Added.
- http/wpt/fetch/request-abort.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241137 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241372] by
-
- 17 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241130. rdar://problem/47801392
HTMLMediaElement registers wrong ScriptExecutionContext with its ActiveDOMObject parent class
https://bugs.webkit.org/show_bug.cgi?id=194360
HTMLMediaElement registers the Document used to create it with ActiveDOMObject, when it should
really use that Document's contextDocument(). Rather than just fix this in HTMLMediaElement,
make sure that the correct document is used everywhere by adding a new ActiveDOMObject constructor
taking a Document&, and making an explicitly deleted Document* constructor to catch any new cases.
Reviewed by Geoffrey Garen.
- Modules/applepay/ApplePaySession.cpp: (WebCore::ApplePaySession::ApplePaySession):
- Modules/mediarecorder/MediaRecorder.cpp: (WebCore::MediaRecorder::MediaRecorder):
- Modules/mediastream/MediaDevices.cpp: (WebCore::MediaDevices::MediaDevices):
- Modules/mediastream/UserMediaRequest.cpp: (WebCore::UserMediaRequest::UserMediaRequest):
- Modules/notifications/Notification.cpp: (WebCore::Notification::Notification):
- Modules/paymentrequest/PaymentRequest.cpp: (WebCore::PaymentRequest::PaymentRequest):
- Modules/webaudio/AudioContext.cpp: (WebCore::AudioContext::AudioContext):
- animation/WebAnimation.cpp: (WebCore::WebAnimation::WebAnimation):
- css/FontFaceSet.cpp: (WebCore::FontFaceSet::FontFaceSet):
- dom/ActiveDOMObject.cpp: (WebCore::ActiveDOMObject::ActiveDOMObject):
- dom/ActiveDOMObject.h:
- dom/Document.h: (WebCore::ActiveDOMObject::ActiveDOMObject):
- html/HTMLMarqueeElement.cpp: (WebCore::HTMLMarqueeElement::HTMLMarqueeElement):
- html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::HTMLMediaElement):
- html/HTMLSourceElement.cpp: (WebCore::HTMLSourceElement::HTMLSourceElement):
- page/IntersectionObserver.cpp: (WebCore::IntersectionObserver::IntersectionObserver):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241130 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241371] by
-
- 5 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241128. rdar://problem/46664625
[macOS] API test times out after r241026
https://bugs.webkit.org/show_bug.cgi?id=194372
Reviewed by Alex Christensen.
The API test TestWebKitAPI.RenderingProgress.FirstMeaningfulPaint times out after r241026.
A new function pointer, layoutMilestones, is added to WKBundlePageLoaderClient, in order
for clients to decide which milestones they would like to listen for.
- WebProcess/InjectedBundle/API/c/WKBundlePageLoaderClient.h:
- WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm: (layoutMilestones): (setUpPageLoaderClient):
- WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp: (WebKit::InjectedBundlePageLoaderClient::layoutMilestones const):
- WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241128 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241370] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241124. rdar://problem/47466549
Shrink and hyphenate safe browsing warning text on watchOS
https://bugs.webkit.org/show_bug.cgi?id=194361
<rdar://problem/47466549>
Reviewed by Geoffrey Garen.
Some internationalizations use long words that didn't fit on small watches.
- UIProcess/Cocoa/WKSafeBrowsingWarning.mm: (fontOfSize): (-[WKSafeBrowsingWarning addContent]): (-[WKSafeBrowsingTextView initWithAttributedString:forWarning:]):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241124 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241369] by
-
- 6 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241121. rdar://problem/42023295
Infinite recursion via CachedResource::~CachedResource
https://bugs.webkit.org/show_bug.cgi?id=194378
<rdar://problem/42023295>
Reviewed by Daniel Bates.
I don't know the exact steps to trigger this but the mechanism seems clear.
1) An existing resource is removed from or replaced in CachedResourceLoader::m_documentResources map.
2) This decrements the handle count of resource and causes it be deleted.
3) CachedResource::~CachedResource calls m_owningCachedResourceLoader->removeCachedResource(*this). This only happens with
resources that are "owned" by CachedResourceLoader which is a rare special case (used by image document and if memory cache is disabled).
4) CachedResourceLoader::removeCachedResource looks up the resource from the map which causes a temporary CachedResourceHandle to be created.
This increments the handle count of the resource from 0 back to 1.
5) When the temporary dies, CachedResource::~CachedResource is called again and we cycle back to 3).
The fix here is simply to remove CachedResourceLoader::removeCachedResource call from ~CachedResource.
It is a leftover from when the map contained raw pointers instead of owning CachedResourceHandles.
Since m_documentResources map has a handle to the resource, the only way we are in the destructor is that the resource
has been removed from the map already (or is in process of being removed like in this crash). Any call that does anything
other than bail out is going to crash.
CachedResource::n_owningCachedResourceLoader member and CachedResourceLoader::removeCachedResource function only exist to
support this erranous call so they are removed as well.
- loader/ImageLoader.cpp: (WebCore::ImageLoader::updateFromElement):
- loader/cache/CachedResource.cpp: (WebCore::CachedResource::~CachedResource):
This is the substantive change. The rest just removes now-dead code.
- loader/cache/CachedResource.h: (WebCore::CachedResource::setOwningCachedResourceLoader): Deleted.
- loader/cache/CachedResourceLoader.cpp: (WebCore::CachedResourceLoader::~CachedResourceLoader): (WebCore::CachedResourceLoader::requestUserCSSStyleSheet): (WebCore::CachedResourceLoader::requestResource): (WebCore::CachedResourceLoader::loadResource): (WebCore::CachedResourceLoader::garbageCollectDocumentResources): (WebCore::CachedResourceLoader::removeCachedResource): Deleted.
- loader/cache/CachedResourceLoader.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241121 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:03 AM Changeset in webkit [241368] by
-
- 29 edits3 copies in branches/safari-608.1.5.1-branch
Cherry-pick r241105. rdar://problem/46733045
[Payment Request] It should be possible to require a phonetic name for shipping contacts
https://bugs.webkit.org/show_bug.cgi?id=194311
<rdar://46733045>
Reviewed by Alex Christensen.
Source/WebCore:
It should be possible to require that a shipping contact has a phonetic name in Payment Request.
To accomplish this, move requiredShippingContactFields from ApplePayPaymentRequest to
ApplePayRequestBase so that it can be used as part of an Apple Pay payment method data.
Since required shipping contact fields can now be specified both in
requiredShippingContactFields and PaymentOptions, we merge the required fields from these
two sources such that, e.g., email is required if it is specified in either place.
So that clients can detect this new feature, the API version number is bumped from 5 to 6.
Added test cases to ApplePayRequestShippingContact.https.html and ApplePayRequestShippingContactV3.https.html.
- DerivedSources.make:
- Modules/applepay/ApplePayPaymentRequest.h:
- Modules/applepay/ApplePayPaymentRequest.idl:
- Modules/applepay/ApplePayRequestBase.cpp: (WebCore::convertAndValidate):
- Modules/applepay/ApplePayRequestBase.h:
- Modules/applepay/ApplePayRequestBase.idl:
- Modules/applepay/ApplePaySession.cpp: (WebCore::convertAndValidate):
- Modules/applepay/PaymentCoordinatorClient.cpp: Added. (WebCore::PaymentCoordinatorClient::supportsVersion):
- Modules/applepay/PaymentCoordinatorClient.h:
- Modules/applepay/paymentrequest/ApplePayPaymentHandler.cpp: (WebCore::mergePaymentOptions): (WebCore::ApplePayPaymentHandler::show):
- SourcesCocoa.txt:
- WebCore.xcodeproj/project.pbxproj:
- loader/EmptyClients.cpp:
- testing/MockPaymentContactFields.h: Added. (WebCore::MockPaymentContactFields::MockPaymentContactFields):
- testing/MockPaymentContactFields.idl: Added.
- testing/MockPaymentCoordinator.cpp: (WebCore::MockPaymentCoordinator::showPaymentUI): (WebCore::MockPaymentCoordinator::supportsVersion): Deleted.
- testing/MockPaymentCoordinator.h:
- testing/MockPaymentCoordinator.idl:
Source/WebKit:
- WebProcess/ApplePay/WebPaymentCoordinator.cpp: (WebKit::WebPaymentCoordinator::supportsVersion): Deleted.
- WebProcess/ApplePay/WebPaymentCoordinator.h:
Source/WebKitLegacy/mac:
- WebCoreSupport/WebPaymentCoordinatorClient.h:
- WebCoreSupport/WebPaymentCoordinatorClient.mm: (WebPaymentCoordinatorClient::supportsVersion): Deleted.
LayoutTests:
- http/tests/ssl/applepay/ApplePayRequestShippingContact.https-expected.txt:
- http/tests/ssl/applepay/ApplePayRequestShippingContact.https.html:
- http/tests/ssl/applepay/ApplePayRequestShippingContactV3.https-expected.txt:
- http/tests/ssl/applepay/ApplePayRequestShippingContactV3.https.html:
- http/tests/ssl/applepay/PaymentRequest.https-expected.txt:
- http/tests/ssl/applepay/PaymentRequest.https.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241105 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241367] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241026. rdar://problem/46664625
Roll out parts of r238819 since it is a PLT performance regression.
https://bugs.webkit.org/show_bug.cgi?id=194346
Unreviewed performance fix.
- WebProcess/InjectedBundle/API/mac/WKWebProcessPlugInBrowserContextController.mm: (didStartProvisionalLoadForFrame): (didReceiveServerRedirectForProvisionalLoadForFrame): (didFinishLoadForFrame): (globalObjectIsAvailableForFrame): (didRemoveFrameFromHierarchy): (didCommitLoadForFrame): (didFinishDocumentLoadForFrame): (didFailProvisionalLoadWithErrorForFrame): (didFailLoadWithErrorForFrame): (didSameDocumentNavigationForFrame): (didLayoutForFrame): (didReachLayoutMilestone): (didFirstVisuallyNonEmptyLayoutForFrame): (didHandleOnloadEventsForFrame): (userAgentForURL): (setUpPageLoaderClient): (willSendRequestForFrame): (didInitiateLoadForResource): (didFinishLoadForResource): (didFailLoadForResource): (setUpResourceLoadClient): (-[WKWebProcessPlugInBrowserContextController setLoadDelegate:]): (ResourceLoadClient::ResourceLoadClient): Deleted. (ResourceLoadClient::loadDelegate const): Deleted. (ResourceLoadClient::pluginContextController const): Deleted. (PageLoaderClient::PageLoaderClient): Deleted. (PageLoaderClient::loadDelegate const): Deleted. (PageLoaderClient::pluginContextController const): Deleted. (PageLoaderClient::didStartProvisionalLoadForFrame): Deleted. (PageLoaderClient::didReceiveServerRedirectForProvisionalLoadForFrame): Deleted. (PageLoaderClient::didFinishLoadForFrame): Deleted. (PageLoaderClient::globalObjectIsAvailableForFrame): Deleted. (PageLoaderClient::didRemoveFrameFromHierarchy): Deleted. (PageLoaderClient::didCommitLoadForFrame): Deleted. (PageLoaderClient::didFinishDocumentLoadForFrame): Deleted. (PageLoaderClient::didFailProvisionalLoadWithErrorForFrame): Deleted. (PageLoaderClient::didFailLoadWithErrorForFrame): Deleted. (PageLoaderClient::didSameDocumentNavigationForFrame): Deleted. (PageLoaderClient::didLayoutForFrame): Deleted. (PageLoaderClient::didReachLayoutMilestone): Deleted. (PageLoaderClient::didFirstVisuallyNonEmptyLayoutForFrame): Deleted. (PageLoaderClient::layoutMilestones const): Deleted. (PageLoaderClient::didHandleOnloadEventsForFrame): Deleted. (PageLoaderClient::userAgentForURL const): Deleted. (ResourceLoadClient::willSendRequestForFrame): Deleted. (ResourceLoadClient::didInitiateLoadForResource): Deleted. (ResourceLoadClient::didFinishLoadForResource): Deleted. (ResourceLoadClient::didFailLoadForResource): Deleted.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241026 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241366] by
-
- 3 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241022. rdar://problem/47833940
CoreAudioCaptureSource should not configure its audio unit until it starts producing data
https://bugs.webkit.org/show_bug.cgi?id=194310
Reviewed by Eric Carlson.
Delay the configuration of the audio unit until the source is instructed to start producing data.
This allows the UIProcess to not start changing the audio unit when
checking for constraints during getUserMedia call before the prompt.
Covered by manual testing.
- platform/mediastream/mac/CoreAudioCaptureSource.cpp: (WebCore::CoreAudioCaptureSource::CoreAudioCaptureSource): (WebCore::CoreAudioCaptureSource::initializeToStartProducingData): (WebCore::CoreAudioCaptureSource::startProducingData):
- platform/mediastream/mac/CoreAudioCaptureSource.h:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241022 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241365] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r241021. rdar://problem/45354090
Disable audio ducking at Audio Unit setup time
https://bugs.webkit.org/show_bug.cgi?id=194303
Reviewed by Eric Carlson.
When creating a CoreAudioCaptureSource, the audio unit might be
reconfigured if a past audio capture was done.
This might trigger audio ducking which is undone in startInternal.
In some cases, startInternal will never call start.
In that case, the audio unit will continue ducking the other processing.
To ensure ducking is disabled, unduck in setupAudioUnit as well as startInternal.
In addition to that, once a shared unit is created, it stays alive until the UIProcess exits.
This might affect all applications.
Instead, whenever the shared unit is stopped, clean it so as to restore the state as if no capture ever happened.
This has noticeable effects in the quality of audio being played on bluetooth devices.
Covered by manual tests.
- platform/mediastream/mac/CoreAudioCaptureSource.cpp: (WebCore::CoreAudioSharedUnit::setupAudioUnit): (WebCore::CoreAudioSharedUnit::unduck): (WebCore::CoreAudioSharedUnit::startInternal): (WebCore::CoreAudioSharedUnit::captureFailed): (WebCore::CoreAudioSharedUnit::stopProducingData):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241021 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241364] by
-
- 3 edits3 adds in branches/safari-608.1.5.1-branch
Cherry-pick r241018. rdar://problem/47822929
RELEASE_ASSERT(!m_document.isResolvingTreeStyle()) in com.apple.WebKit.WebContent at WebCore: WebCore::StyleResolver::~StyleResolver
https://bugs.webkit.org/show_bug.cgi?id=194333
<rdar://problem/47822929>
Reviewed by Zalan Bujtas.
Source/WebCore:
Content extensions may mutate the extension stylesheet in the middle of a style resolution as a result of
the legacy animation code triggering a resource load.
Test: http/tests/contentextensions/css-display-none-keyframe.html
- style/StyleScope.cpp: (WebCore::Style::Scope::scheduleUpdate):
Avoid clearing the style resolver if we are in the middle of a style resolution.
A better fix that avoid doing this in the first place is tracked by https://bugs.webkit.org/show_bug.cgi?id=194335.
LayoutTests:
- http/tests/contentextensions/css-display-none-keyframe-expected.txt: Added.
- http/tests/contentextensions/css-display-none-keyframe.html: Added.
- http/tests/contentextensions/css-display-none-keyframe.html.json: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241018 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241363] by
-
- 6 edits in branches/safari-608.1.5.1-branch
Cherry-pick r241011. rdar://problem/47827420
Web Inspector: Styles: PropertiesChanged shouldn't fire when old and new text are both empty
https://bugs.webkit.org/show_bug.cgi?id=194318
Reviewed by Devin Rousso.
Source/WebInspectorUI:
Previously, WI.CSSStyleDeclaration.Event.PropertiesChanged fired when
old text and new text were empty strings.
- UserInterface/Models/CSSStyleDeclaration.js:
LayoutTests:
Fix the flaky test on Debug.
- inspector/css/modify-css-property-race-expected.txt:
- inspector/css/modify-css-property-race.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241011 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241362] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebInspectorUI
Cherry-pick r241003. rdar://problem/47829275
Web Inspector: Elements tab: selection is broken after deleting the selected node
https://bugs.webkit.org/show_bug.cgi?id=194300
<rdar://problem/47829275>
Reviewed by Devin Rousso.
Deleting a TreeElement can cause an IndexSet including indexes
outside the deleted range to be passed to SelectionController,
corrupting the internal selection state.
- UserInterface/Views/TreeOutline.js:
(WI.TreeOutline.prototype._indexesForSubtree.numberOfElementsInSubtree): Added.
(WI.TreeOutline.prototype._indexesForSubtree):
Finding the last (rightmost leaf) TreeElement in the subtree used
TreeElement.prototype.traverseNextElement to do a depth first traversal.
This method did not stay within the subtree rooted at
treeElement
.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241003 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241361] by
-
- 4 edits in branches/safari-608.1.5.1-branch/Source/JavaScriptCore
Cherry-pick r240998. rdar://problem/47832956
Fix DFG's doesGC() for a few more nodes.
https://bugs.webkit.org/show_bug.cgi?id=194307
<rdar://problem/47832956>
Reviewed by Yusuke Suzuki.
Fix doesGC() for the following nodes:
NumberToStringWithValidRadixConstant:
Calls operationInt32ToStringWithValidRadix(), which calls int32ToString(),
which can allocate a string.
Calls operationInt52ToStringWithValidRadix(), which calls int52ToString(),
which can allocate a string.
Calls operationDoubleToStringWithValidRadix(), which calls numberToString(),
which can allocate a string.
RegExpExecNonGlobalOrSticky: calls createRegExpMatchesArray() which allocates
memory for all kinds of objects.
RegExpMatchFast: calls operationRegExpMatchFastString(), which calls
RegExpObject::execInline() and RegExpObject::matchGlobal(). Both of
these allocates memory for the match result.
RegExpMatchFastGlobal: calls operationRegExpMatchFastGlobalString(), which
calls RegExpObject's collectMatches(), which allocates an array amongst
other objects.
StringFromCharCode:
If the uint32 code to convert is greater than maxSingleCharacterString,
we'll call operationStringFromCharCode(), which calls jsSingleCharacterString(),
which allocates a new string if the code is greater than maxSingleCharacterString.
Also fix SpeculativeJIT::compileFromCharCode() and FTL's compileStringFromCharCode()
to use maxSingleCharacterString instead of a literal constant.
- dfg/DFGDoesGC.cpp: (JSC::DFG::doesGC):
- dfg/DFGSpeculativeJIT.cpp: (JSC::DFG::SpeculativeJIT::compileFromCharCode):
- ftl/FTLLowerDFGToB3.cpp: (JSC::FTL::DFG::LowerDFGToB3::compileStringFromCharCode):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240998 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241360] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebInspectorUI
Cherry-pick r240997. rdar://problem/47805023
Web Inspector: REGRESSION (r240947): Resources tab: can't select main frame after refreshing page
https://bugs.webkit.org/show_bug.cgi?id=194254
<rdar://problem/47805023>
Reviewed by Devin Rousso.
- UserInterface/Views/TreeOutline.js:
(WI.TreeOutline.prototype.selectionControllerSelectionDidChange):
TreeOutline should always call the TreeElement
select
anddeselect
methods while processing selection changes. Having notifications suppressed bythis._suppressNextSelectionDidChangeEvent
should only affect the dispatching of TreeOutline events.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240997 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241359] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r240995. rdar://problem/47719379
Reproducible crash under WKShareSheet presentWithParameters when cancelling a share
https://bugs.webkit.org/show_bug.cgi?id=194301
<rdar://problem/47719379>
Reviewed by Beth Dakin.
- UIProcess/Cocoa/WKShareSheet.mm: (-[WKShareSheet presentWithParameters:completionHandler:]): NSSharingServicePicker's delegate callbacks can be called synchronously. We release the WKShareSheet (which holds our reference to the NSSharingServicePicker) under sharingServicePicker:didChooseSharingService:. On older versions of macOS, there was nothing keeping the NSSharingServicePicker alive inside showRelativeToRect:ofView:preferredEdge:, thus the whole chain of references would fall and result in sending a message to a released NSSharingServicePicker. To resolve this, keep an extra reference to the WKShareSheet until presentation is complete.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240995 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241358] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/JavaScriptCore
Cherry-pick r240991. rdar://problem/47827589
Move DFG nodes that clobberize() says will write(Heap) to the doesGC() list that returns true.
https://bugs.webkit.org/show_bug.cgi?id=194298
<rdar://problem/47827555>
Reviewed by Saam Barati.
We do this for 3 reasons:
- It's clearer when reading doesGC()'s code that these nodes will return true.
- If things change in the future where clobberize() no longer reports these nodes as write(Heap), each node should be vetted first to make sure that it can never GC before being moved back to the doesGC() list that returns false.
- This reduces the list of nodes that we need to audit to make sure doesGC() is correct in its claims about the nodes' GCing possibility.
The list of nodes moved are:
ArrayPush
ArrayPop
Call
CallEval
CallForwardVarargs
CallVarargs
Construct
ConstructForwardVarargs
ConstructVarargs
DefineDataProperty
DefineAccessorProperty
DeleteById
DeleteByVal
DirectCall
DirectConstruct
DirectTailCallInlinedCaller
GetById
GetByIdDirect
GetByIdDirectFlush
GetByIdFlush
GetByIdWithThis
GetByValWithThis
GetDirectPname
GetDynamicVar
HasGenericProperty
HasOwnProperty
HasStructureProperty
InById
InByVal
InstanceOf
InstanceOfCustom
LoadVarargs
NumberToStringWithRadix
PutById
PutByIdDirect
PutByIdFlush
PutByIdWithThis
PutByOffset
PutByValWithThis
PutDynamicVar
PutGetterById
PutGetterByVal
PutGetterSetterById
PutSetterById
PutSetterByVal
PutStack
PutToArguments
RegExpExec
RegExpTest
ResolveScope
ResolveScopeForHoistingFuncDeclInEval
TailCall
TailCallForwardVarargsInlinedCaller
TailCallInlinedCaller
TailCallVarargsInlinedCaller
ToNumber
ToPrimitive
ValueNegate
- dfg/DFGDoesGC.cpp: (JSC::DFG::doesGC):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240991 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241357] by
-
- 3 edits in branches/safari-608.1.5.1-branch/LayoutTests
Cherry-pick r240989. rdar://problem/47827420
Web Inspector: Fix modify-css-property-race.html test failures
https://bugs.webkit.org/show_bug.cgi?id=194282
Reviewed by Matt Baker.
Fix test failures introduced by r240946 by providing a message for expectGreaterThan assert,
so it doesn't log the actual values.
- inspector/css/modify-css-property-race-expected.txt:
- inspector/css/modify-css-property-race.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240989 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241356] by
-
- 16 edits in branches/safari-608.1.5.1-branch
Cherry-pick r240983. rdar://problem/47756320
Unreviewed, rolling out r240742.
Causes crashes on iOS simulator.
Reverted changeset:
"[iOS] Keyups for non-modifier keys identified as "Dead" when
not focused in a content-editable element"
https://bugs.webkit.org/show_bug.cgi?id=192824
https://trac.webkit.org/changeset/240742
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240983 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241355] by
-
- 3 edits in branches/safari-608.1.5.1-branch/Source/WebInspectorUI
Cherry-pick r240952. rdar://problem/47559021
Web Inspector: Resources: missing resource data for document on reload
https://bugs.webkit.org/show_bug.cgi?id=194243
<rdar://problem/47559021>
Reviewed by Joseph Pecoraro.
- UserInterface/Views/ResourceDetailsSidebarPanel.js: (WI.ResourceDetailsSidebarPanel.prototype.set resource): (WI.ResourceDetailsSidebarPanel.prototype._applyResourceEventListeners):
- UserInterface/Base/Object.js:
(WI.Object.removeEventListener):
Drive-by: there's no need to iterate over the entire table to check if
thisObject
exists, as that is handled for us byListMultimap
, which we later call anyways.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240952 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241354] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebInspectorUI
Cherry-pick r240947. rdar://problem/47743864
Web Inspector: REGRESSION: clicking a selected call frame doesn't re-scroll
https://bugs.webkit.org/show_bug.cgi?id=194169
<rdar://problem/47743864>
Reviewed by Devin Rousso.
- UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._handleMouseDown): Add a special case for a single-selection TreeOutline with allowsRepeatSelection enabled. Since the element is already selected, bypass the SelectionCongroller and dispatch an event with event.data.selectedByUser set to true.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240947 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:02 AM Changeset in webkit [241353] by
-
- 8 edits2 adds in branches/safari-608.1.5.1-branch
Cherry-pick r240946. rdar://problem/47827420
Web Inspector: Styles: fix race conditions when editing
https://bugs.webkit.org/show_bug.cgi?id=192739
<rdar://problem/46752925>
Reviewed by Devin Rousso.
Source/WebInspectorUI:
Editing CSS property in the style editor syncronously updates CSSStyleDeclaration on the front-end
and asyncronously updates the backend by calling CSSAgent.setStyleText. After the new style text is applied
on the backend, CSSStyleDeclaration (on the front-end) gets updated.
Unsure there's no race conditions by introducing
_updatesInProgressCount
:
- Increment it before calling CSSAgent.setStyleText.
- Decrement it after CSSAgent.setStyleText is finished.
Prevent updates of CSSStyleDeclaration when _updatesInProgressCount isn't 0.
- UserInterface/Models/CSSProperty.js: (WI.CSSProperty.prototype._updateOwnerStyleText):
- UserInterface/Models/CSSStyleDeclaration.js: (WI.CSSStyleDeclaration): (WI.CSSStyleDeclaration.prototype.set text): Removed. (WI.CSSStyleDeclaration.prototype.setText): Added. Change the setter to a method since it has side effects including an asynchronous backend call.
- UserInterface/Models/DOMNodeStyles.js: (WI.DOMNodeStyles.prototype.changeStyleText):
- UserInterface/Views/SpreadsheetStyleProperty.js: (WI.SpreadsheetStyleProperty.prototype.get nameTextField): Removed. (WI.SpreadsheetStyleProperty.prototype.get valueTextField): Removed. Drive-by: remove unused code.
LayoutTests:
- inspector/css/modify-css-property-expected.txt:
- inspector/css/modify-css-property-race-expected.txt: Added.
- inspector/css/modify-css-property-race.html: Added.
- inspector/css/modify-css-property.html:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240946 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 1:01 AM Changeset in webkit [241352] by
-
- 4 edits in trunk/Source
Release assert in PolicyCheckIdentifier::isValidFor via WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction
https://bugs.webkit.org/show_bug.cgi?id=194582
Reviewed by Antti Koivisto.
Source/WebCore:
Check the zero-ness of m_policyCheck first so that we can differentiate process ID being wrong
from the non-generated identifier being sent to us as it was the case in this failure.
- loader/PolicyChecker.cpp:
(WebCore::PolicyCheckIdentifier::isValidFor):
Source/WebKit:
The bug was caused by WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction invoking the callback
with responseIdentifier even when we had failed to send the policy check IPC. Clearly, responseIdentifier
is invalid in that case, and we should be using requestIdentifier instead.
Unfortunately no new tests since I'm not aware of a way to make sendSync fail in this case.
- WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForNavigationAction):
- 12:41 AM Changeset in webkit [241351] by
-
- 6 edits in trunk/Source/WebKit
Responsiveness timers are too expensive for frequent events
https://bugs.webkit.org/show_bug.cgi?id=194003
Reviewed by Geoffrey Garen.
With each event, we set a responsivness timer to check if the WebProcess
is responsive, and reset the timer when the WebProcess sends an answer.
For frequent events (e.g. wheel events, mouse force events, etc),
we are spamming the kernel with hundreds of timers per second.
That is a bit inefficient.
Another source of inefficiency comes from the timer implementation
itself. Stopping a RunLoop::Timer removes the timer from every mode
and invalidate the timer. It becomes costly since we do it a lot.
With this patch, I tweak ResponsivenessTimer and its use to minimize
how often we schedule system timers.
The first change is to not stop the timer when we get the stop()
calls if we expect more events to come in. Instead, we keep track
if we care about the timeout or not in the attribute "m_waitingForTimer".
When the next event starts, we can reschedule the timer without ever
having told the kernel about the stop.
If there are no next events, the timeout fires but m_waitingForTimer
is false. To avoid idle wake up, the lazy stop is only used when having
following events is common.
The second improvements comes from not even rescheduling the timer
when restarted. Instead of changing the timer, we let the original timer
fire and re-shedule a new one with the missing time.
For more context, also see patches r240759 and r240944.
- UIProcess/ResponsivenessTimer.cpp:
(WebKit::ResponsivenessTimer::ResponsivenessTimer):
(WebKit::ResponsivenessTimer::invalidate):
(WebKit::ResponsivenessTimer::timerFired):
(WebKit::ResponsivenessTimer::start):
(WebKit::ResponsivenessTimer::startWithLazyStop):
(WebKit::ResponsivenessTimer::stop):
(WebKit::ResponsivenessTimer::processTerminated):
(WebKit::ResponsivenessTimer::~ResponsivenessTimer): Deleted.
- UIProcess/ResponsivenessTimer.h:
(WebKit::ResponsivenessTimer::hasActiveTimer const):
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::processNextQueuedMouseEvent):
(WebKit::WebPageProxy::sendWheelEvent):
(WebKit::WebPageProxy::handleKeyboardEvent):
(WebKit::WebPageProxy::handleGestureEvent):
- UIProcess/WebProcessProxy.cpp:
(WebKit::WebProcessProxy::isResponsiveWithLazyStop):
- UIProcess/WebProcessProxy.h:
- 12:26 AM Changeset in webkit [241350] by
-
- 6 edits in trunk/Source/WebCore
Unreviewed, rolling out r241273.
https://bugs.webkit.org/show_bug.cgi?id=194579
This change is causing a flaky assertion failure crash in High
Sierra Debug (Requested by ShawnRoberts on #webkit).
Reverted changeset:
"Stop using setDefersLoading from WebCore"
https://bugs.webkit.org/show_bug.cgi?id=194315
https://trac.webkit.org/changeset/241273
Feb 12, 2019:
- 11:36 PM Changeset in webkit [241349] by
-
- 2 edits in trunk/Source/WebKit
Null deref in userInterfaceLayoutDirection under ViewGestureController::handleSwipeGesture
https://bugs.webkit.org/show_bug.cgi?id=194569
<rdar://problem/46711049>
Reviewed by Wenson Hsieh.
- UIProcess/mac/ViewGestureControllerMac.mm:
(WebKit::ViewGestureController::handleSwipeGesture):
It is conceivable that we could get here if the client closes the page
e.g. in the callback from willEndSwipeGesture. We already guarded against
this ... one line too late! Rearrange the lines so we don't call into
WebPageProxy at all if we don't have a drawing area (which is a strict subset
of the time that isValid would return true). This is a speculative fix,
since I can no longer reproduce the crash on demand.
- 11:13 PM Changeset in webkit [241348] by
-
- 3 edits in trunk/Source/WebCore
Remove unnecessary null check in bindings.
https://bugs.webkit.org/show_bug.cgi?id=194581
Reviewed by Yusuke Suzuki.
It is always safe to call visitor.containsOpaqueRoot(root) with a null root pointer.
It will just return false. Since we don't expect the root pointer to be null in
the common case, having a null check here is also not optimal. We'll remove this
unneeded null check.
- bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):
- bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
(WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
- 10:43 PM Changeset in webkit [241347] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r240738. rdar://problem/47686640
Ensure ENABLE_MEDIA_SOURCE is defined inside DerivedSources.make
https://bugs.webkit.org/show_bug.cgi?id=194063
Reviewed by Jon Lee.
- DerivedSources.make:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240738 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:36 PM Changeset in webkit [241346] by
-
- 7 edits1 add in branches/safari-608.1.5.1-branch
Cherry-pick r241306. rdar://problem/47789393
WebPage::close needs to remove all message receivers associated with that WebPage, not WebPage::~WebPage
https://bugs.webkit.org/show_bug.cgi?id=194522
<rdar://problem/47789393>
Reviewed by Chris Dumez.
Source/WebKit:
The InjectedBundle SPI can retain the WebPage or wrapping objects (WKWebProcessPlugInBrowserContextController/WKBundlePageRef).
This can make it so WebPage::close is called before WebPage::~WebPage, and if the SuspendedPageProxy is reused for a subsequent
navigation to the same domain, the WebProcess is reused with a different WebPage instance with the same PageID, which causes problems
when another WebPage registers message handlers and then the previous WebPage is destroyed, which removes both message handlers.
- WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::~WebPage): (WebKit::WebPage::close): (WebKit::WebPage::mainFrameDidLayout):
- WebProcess/WebPage/WebPage.h:
- WebProcess/WebProcess.h: (WebKit::WebProcess::eventDispatcher):
Tools:
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/WebKitCocoa/BundleRetainPagePlugIn.mm: Added. (-[BundleRetainPagePlugIn webProcessPlugIn:didCreateBrowserContextController:]):
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241306 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:36 PM Changeset in webkit [241345] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r241112. rdar://problem/47764549
AX: com.apple.WebKit.WebContent at WebKit: -[WKAccessibilityWebPageObjectBase axObjectCache]
https://bugs.webkit.org/show_bug.cgi?id=194306
<rdar://problem/47764549>
Reviewed by Zalan Bujtas.
Check the page reference is still valid.
Modernize code in this area.
- WebProcess/WebPage/mac/WKAccessibilityWebPageObjectBase.mm:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241112 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:36 PM Changeset in webkit [241344] by
-
- 2 edits in branches/safari-608.1.5.1-branch/LayoutTests
Cherry-pick r241031. rdar://problem/47830193
Revert part of r241015 that skipped all WebGL tests
- TestExpectations: Revert unintended change to skip all WebGL tests.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241031 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:35 PM Changeset in webkit [241343] by
-
- 4 edits2 adds in branches/safari-608.1.5.1-branch
Cherry-pick r241015. rdar://problem/47830193
REGRESSION (r240909): Release assert in FrameLoader::loadURL when navigating with a non-existent target name
https://bugs.webkit.org/show_bug.cgi?id=194329
Reviewed by Geoffrey Garen.
Source/WebCore:
The bug was caused by the code path for when navigating with a specific target frame name that does not exist
never setting the load type of PolicyChecker. As a result, we would use whatever load type used in the previous
navigation, resulting in this release assertion.
Updating the load type here should in theory fix the underlying bug r240909 was meant to catch & fix.
Test: fast/loader/navigate-with-new-target-after-back-forward-navigation.html
- loader/FrameLoader.cpp: (WebCore::FrameLoader::loadURL):
LayoutTests:
Added a regression test.
- fast/loader/navigate-with-new-target-after-back-forward-navigation-expected.txt: Added.
- fast/loader/navigate-with-new-target-after-back-forward-navigation.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@241015 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:35 PM Changeset in webkit [241342] by
-
- 2 edits in branches/safari-608.1.5.1-branch/Source/WebKit
Cherry-pick r240974. rdar://problem/47581081
Protect globalWebSocketStreamMap with a Lock
https://bugs.webkit.org/show_bug.cgi?id=194224
<rdar://problem/47581081>
Reviewed by Ryosuke Niwa.
- WebProcess/Network/WebSocketStream.cpp: (WebKit::WebSocketStream::streamWithIdentifier): (WebKit::WebSocketStream::networkProcessCrashed): (WebKit::WebSocketStream::WebSocketStream): (WebKit::WebSocketStream::~WebSocketStream):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240974 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:35 PM Changeset in webkit [241341] by
-
- 3 edits in branches/safari-608.1.5.1-branch/Source/WebCore
Cherry-pick r240971. rdar://problem/47774298
REGRESSION (r240579): com.apple.WebKit.WebContent at WebCore: WebCore::Document::absoluteEventRegionForNode
https://bugs.webkit.org/show_bug.cgi?id=194284
<rdar://problem/47774298>
Patch by Antoine Quint <Antoine Quint> on 2019-02-05
Reviewed by Antti Koivisto.
The m_touchActionElements list needs to be HashSet<RefPtr<Element>> instead of HashSet<Element*>. It was initially storing raw pointers based on m_touchEventTargets
which is an EventTargetSet (typedef’d to HashCountedSet<Node*>), but that's because these nodes have an event listener registered for them and as such are kept alive,
whereas elements with a touch-action property aren’t. Elements are removed from this list from Document::nodeWillBeRemoved() and from Document::updateTouchActionElements(),
the latter being called from Style::TreeResolver::resolveElement().
- dom/Document.cpp: (WebCore::Document::updateTouchActionElements):
- dom/Document.h: (WebCore::Document::touchActionElements const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240971 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- 10:34 PM Changeset in webkit [241340] by
-
- 2 edits in trunk/Source/JavaScriptCore
JSScript needs to retain its cache path NSURL*
https://bugs.webkit.org/show_bug.cgi?id=194577
Reviewed by Tim Horton.
- API/JSScript.mm:
(+[JSScript scriptFromASCIIFile:inVirtualMachine:withCodeSigning:andBytecodeCache:]):
(-[JSScript dealloc]):
- 10:01 PM Changeset in webkit [241339] by
-
- 7 edits in branches/safari-608.1.5.1-branch/Source
Versioning.
- 9:24 PM Changeset in webkit [241338] by
-
- 4 edits in trunk/Source/WebKit
WebServiceWorkerProvider::handleFetch no longer needs a CachedResource parameter
https://bugs.webkit.org/show_bug.cgi?id=194548
Reviewed by Alex Christensen.
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoad):
- WebProcess/Storage/WebServiceWorkerProvider.cpp:
(WebKit::WebServiceWorkerProvider::handleFetch):
- WebProcess/Storage/WebServiceWorkerProvider.h:
- 9:04 PM Changeset in webkit [241337] by
-
- 7 edits3 deletes in trunk/Source
Remove WKLegacyPDFView
https://bugs.webkit.org/show_bug.cgi?id=194559
Reviewed by Andy Estes.
Source/WebKit:
- Platform/spi/ios/CorePDFSPI.h: Removed.
- SourcesCocoa.txt:
- UIProcess/Cocoa/WKWebViewContentProviderRegistry.mm:
(-[WKWebViewContentProviderRegistry initWithConfiguration:]):
- UIProcess/ios/WKLegacyPDFView.h: Removed.
- UIProcess/ios/WKLegacyPDFView.mm: Removed.
- WebKit.xcodeproj/project.pbxproj:
Source/WTF:
- wtf/FeatureDefines.h:
- 6:32 PM Changeset in webkit [241336] by
-
- 6 edits in trunk
Regression(PSON) MESSAGE_CHECK() hit under WebPageProxy::didFailProvisionalLoadForFrameShared()
https://bugs.webkit.org/show_bug.cgi?id=194568
<rdar://problem/47944490>
Reviewed by Ryosuke Niwa.
Source/WebKit:
When the provisional process crashes, it is unsafe to call ProvisionalPageProxy::cancel() because
the WebProcessProxy clears its frame map as soon as the process crashes. Calling cancel() after
that would call WebPageProxy::didFailProvisionalLoadForFrameShared(), which would try to look up
the frame by ID and MESSAGE_CHECK() that the frame is not null. We would fail this check since
the frame has been removed from the WebProcessProxy at this point.
- UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _provisionalWebProcessIdentifier]):
- UIProcess/API/Cocoa/WKWebViewPrivate.h:
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::didFailProvisionalLoadForFrameShared):
(WebKit::WebPageProxy::provisionalProcessDidTerminate):
Tools:
Add API test coverage.
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
(-[PSONNavigationDelegate webView:didStartProvisionalNavigation:]):
- 6:30 PM Changeset in webkit [241335] by
-
- 2 edits in trunk/Source/JavaScriptCore
Make B3Value::returnsBool() more precise
https://bugs.webkit.org/show_bug.cgi?id=194457
Reviewed by Saam Barati.
It is currently used repeatedly in B3ReduceStrength, as well as once in B3LowerToAir.
It has a needlessly complex rule for BitAnd, and has no rule for other easy cases such as BitOr or Select.
No new tests added as this should be indirectly tested by the already existing tests.
- b3/B3Value.cpp:
(JSC::B3::Value::returnsBool const):
- 5:34 PM Changeset in webkit [241334] by
-
- 1 copy in tags/Safari-607.1.35
Tag Safari-607.1.35.
- 5:33 PM Changeset in webkit [241333] by
-
- 5 edits in trunk
Align with Fetch on data: URLs
https://bugs.webkit.org/show_bug.cgi?id=182325
Patch by Rob Buis <rbuis@igalia.com> on 2019-02-12
Reviewed by Alex Christensen.
LayoutTests/imported/w3c:
Update improved test expectations.
- web-platform-tests/fetch/data-urls/processing.any-expected.txt:
- web-platform-tests/fetch/data-urls/processing.any.worker-expected.txt:
Source/WebCore:
The MIME type part of the data url should be serialized as
specified in step 3 under "data" [1].
Test: web-platform-tests/fetch/data-urls/processing.any.js
[1] https://fetch.spec.whatwg.org/#concept-scheme-fetch
- platform/network/DataURLDecoder.cpp:
(WebCore::DataURLDecoder::parseMediaType):
- 5:32 PM Changeset in webkit [241332] by
-
- 2 edits in trunk/Source/WebKit
[iOS] Youtube fails to play.
https://bugs.webkit.org/show_bug.cgi?id=194565
<rdar://problem/47974770>
Reviewed by Geoffrey Garen.
This is caused by sandbox violations and was introduced in r240500.
- Resources/SandboxProfiles/ios/com.apple.WebKit.WebContent.sb:
- 5:05 PM Changeset in webkit [241331] by
-
- 2 edits in trunk/Source/WebCore
Build fix after r241320
https://bugs.webkit.org/show_bug.cgi?id=194271
- page/Frame.cpp:
(WebCore::Frame::requestDOMPasteAccess):
- 5:01 PM Changeset in webkit [241330] by
-
- 2 edits in trunk/Source/WebKit
Remove firing assertion after r241317
https://bugs.webkit.org/show_bug.cgi?id=194506
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::setDefersLoading):
The creation of a PageGroupLoadDeferrer in Chrome.cpp tries to defer loading.
See comments in Chrome::runJavaScriptAlert et al.
This was necessary with WebKitLegacy, so keep it, but it doesn't need to do anything in modern WebKit.
- 4:45 PM Changeset in webkit [241329] by
-
- 3 edits in trunk/Tools
webkitpy: Remove bug_dummy from parsed test expectations
https://bugs.webkit.org/show_bug.cgi?id=194562
<rdar://problem/47853999>
Reviewed by Lucas Forschler.
- Scripts/webkitpy/layout_tests/models/test_expectations.py:
(TestExpectationParser):
(TestExpectationParser.expectation_for_skipped_test): Remove DUMMY_BUG_MODIFIER from
skipped tests.
- Scripts/webkitpy/layout_tests/models/test_expectations_unittest.py:
- 4:23 PM Changeset in webkit [241328] by
-
- 18 edits3 moves1 delete in trunk
[WebGPU] Remove WebGPUBufferDescriptor/Usage and use GPU versions
https://bugs.webkit.org/show_bug.cgi?id=194552
Reviewed by Dean Jackson.
WebGPUBufferDescriptor/Usage have been renamed to GPUBufferDescriptor/Usage in the Web GPU API.
Source/WebCore:
Consolidate the two versions of these classes in our implementation.
Affected layout tests updated with new names. No change in behavior.
- CMakeLists.txt:
- DerivedSources-input.xcfilelist:
- DerivedSources-output.xcfilelist:
- DerivedSources.make:
- Modules/webgpu/GPUBufferDescriptor.idl: Renamed from Source/WebCore/Modules/webgpu/WebGPUBufferDescriptor.idl.
- Modules/webgpu/GPUBufferUsage.idl: Renamed from Source/WebCore/Modules/webgpu/WebGPUBufferUsage.idl.
- Modules/webgpu/WebGPUBufferUsage.h: Removed.
- Modules/webgpu/WebGPUDevice.cpp:
(WebCore::WebGPUDevice::createBuffer const):
- Modules/webgpu/WebGPUDevice.h:
- Modules/webgpu/WebGPUDevice.idl:
- Sources.txt:
- WebCore.xcodeproj/project.pbxproj:
- bindings/js/WebCoreBuiltinNames.h:
- platform/graphics/gpu/GPUBufferDescriptor.h: Moved out GPUBufferUsage.
- platform/graphics/gpu/GPUBufferUsage.h: Moved from GPUBufferDescriptor.h.
LayoutTests:
Update affected tests to match.
- webgpu/bind-groups.html:
- webgpu/buffer-resource-triangles.html:
- webgpu/buffers.html:
- webgpu/depth-enabled-triangle-strip.html:
- webgpu/vertex-buffer-triangle-strip.html:
- 4:19 PM Changeset in webkit [241327] by
-
- 2 edits in trunk/Source/WebCore
Unreviewed, try to fix the internal iOS build after r241321
- accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
- 4:02 PM Changeset in webkit [241326] by
-
- 2 edits in trunk/Tools
[ews-app] Add method to fetch patch
https://bugs.webkit.org/show_bug.cgi?id=194518
Reviewed by Lucas Forschler.
- BuildSlaveSupport/ews-app/ews/models/patch.py:
(Patch.get_patch):
- 4:00 PM Changeset in webkit [241325] by
-
- 5 edits2 adds in trunk/Source/WebInspectorUI
Web Inspector: Experimental setting for CPU Usage Timeline improvements
https://bugs.webkit.org/show_bug.cgi?id=194556
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-12
Reviewed by Matt Baker.
- UserInterface/Main.html:
- UserInterface/Views/LegacyCPUTimelineView.css: Added.
- UserInterface/Views/LegacyCPUTimelineView.js: Added.
Copy of CPUTimelineView.js/css to be used when the setting is not set.
- UserInterface/Views/ContentView.js:
(WI.ContentView.createFromRepresentedObject):
ContentView to create based on the setting.
- UserInterface/Base/Setting.js:
- UserInterface/Views/SettingsTabContentView.js:
(WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
Experimental switch.
- 3:59 PM Changeset in webkit [241324] by
-
- 2 edits in trunk/Tools
[LFC] Expand tests coverage (60 new tests -> 860)
Unreviewed test gardening (run-singly, --child-processes=1).
- LayoutReloaded/misc/LFC-passing-tests.txt:
- 3:33 PM Changeset in webkit [241323] by
-
- 5 edits in trunk/Source/WebKit
Find on Page shouldn't zoom in on matches
https://bugs.webkit.org/show_bug.cgi?id=194557
<rdar://problem/42087017>
Reviewed by Wenson Hsieh.
- UIProcess/ios/SmartMagnificationController.h:
- UIProcess/ios/SmartMagnificationController.messages.in:
- UIProcess/ios/SmartMagnificationController.mm:
(WebKit::SmartMagnificationController::scrollToRect):
- WebProcess/WebPage/ios/FindControllerIOS.mm:
(WebKit::FindController::updateFindIndicator):
Only scroll to reveal the find result, do not zoom in.
- 3:18 PM Changeset in webkit [241322] by
-
- 24 edits11 adds in trunk
Allow pages to trigger programmatic paste from script on iOS
https://bugs.webkit.org/show_bug.cgi?id=194271
<rdar://problem/47808810>
Reviewed by Tim Horton.
Source/WebCore:
Tests: editing/pasteboard/ios/dom-paste-confirmation.html
editing/pasteboard/ios/dom-paste-consecutive-confirmations.html
editing/pasteboard/ios/dom-paste-rejection.html
editing/pasteboard/ios/dom-paste-requires-user-gesture.html
- dom/UserGestureIndicator.cpp:
(WebCore::UserGestureIndicator::~UserGestureIndicator):
Reset a gesture token's DOM paste access when exiting the scope of a user gesture. This prevents DOM paste
access permissions from leaking intosetTimeout()
callbacks when we forward user gesture tokens.
- dom/UserGestureIndicator.h:
(WebCore::UserGestureToken::resetDOMPasteAccess):
Source/WebKit:
Cancel the pending DOM paste access handler when the menu is about to hide, rather than when the hiding
animation has completed. This ensures that if the page (on behalf of the user) requests DOM paste again during
user interaction before the callout bar has finished fading after the previous DOM paste, we won't automatically
cancel the incoming DOM paste access request because the callout bar animation finished.
This scenario is exercised in the layout test editing/pasteboard/ios/dom-paste-consecutive-confirmations.html.
- Platform/spi/ios/UIKitSPI.h:
- UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView setupInteraction]):
(-[WKContentView _willHideMenu:]):
(-[WKContentView _didHideMenu:]):
Tools:
Add support for interacting with the callout bar on iOS during layout tests. See below for more detail.
- DumpRenderTree/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptController::platformSetDidShowMenuCallback):
(WTR::UIScriptController::platformSetDidHideMenuCallback):
(WTR::UIScriptController::rectForMenuAction const):
Add new mechanisms to make it possible to interact with and query the state of the callout menu on iOS. This
includes determining the rect (in content view coordinates) of the menu's controls, and callbacks to register
for when the menu is shown or hidden.
- TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
- TestRunnerShared/UIScriptContext/UIScriptContext.h:
- TestRunnerShared/UIScriptContext/UIScriptController.cpp:
(WTR::UIScriptController::setDidShowMenuCallback):
(WTR::UIScriptController::didShowMenuCallback const):
(WTR::UIScriptController::setDidHideMenuCallback):
(WTR::UIScriptController::didHideMenuCallback const):
(WTR::UIScriptController::platformSetDidShowMenuCallback):
(WTR::UIScriptController::platformSetDidHideMenuCallback):
(WTR::UIScriptController::rectForMenuAction const):
- TestRunnerShared/UIScriptContext/UIScriptController.h:
- WebKitTestRunner/TestController.cpp:
(WTR::TestController::resetPreferencesToConsistentValues):
(WTR::updateTestOptionsFromTestHeader):
- WebKitTestRunner/TestOptions.h:
Add a new test option to determine whether DOM paste is enabled. DOM paste is currently enabled everywhere by
default, but these new programmatic paste tests require it to be disabled in order for confirmation UI to show.
(WTR::TestOptions::hasSameInitializationOptions const):
- WebKitTestRunner/UIScriptControllerCocoa.mm:
(WTR::UIScriptController::calendarType const):
(WTR::UIScriptController::platformUndoManager const):
- WebKitTestRunner/cocoa/TestRunnerWKWebView.h:
- WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
(-[TestRunnerWKWebView initWithFrame:configuration:]):
(-[TestRunnerWKWebView dealloc]):
(-[TestRunnerWKWebView _didShowMenu]):
(-[TestRunnerWKWebView _didHideMenu]):
Listen to when the callout bar is presented and dismissed, and invoke testing callbacks as needed.
- WebKitTestRunner/ios/TestControllerIOS.mm:
(WTR::handleMenuWillHideNotification):
(WTR::handleMenuDidHideNotification):
(WTR::TestController::platformInitialize):
(WTR::TestController::platformDestroy):
(WTR::TestController::platformResetStateToConsistentValues):
Additionally ensure that any callout menu presented by a previous layout test is dismissed before running the
next test by hiding the callout bar if necessary, and then waiting for the "DidHide" notification.
- WebKitTestRunner/ios/UIScriptControllerIOS.mm:
(WTR::forEachViewInHierarchy):
(WTR::findViewInHierarchyOfType):
Move
forEachViewInHierarchy
so that we can use it throughout the file, and then add some additional helper
functions that dig through a given view's hierarchy in search of a view of a given class.
(WTR::UIScriptController::selectionStartGrabberViewRect const):
(WTR::UIScriptController::selectionEndGrabberViewRect const):
(WTR::UIScriptController::selectionCaretViewRect const):
(WTR::UIScriptController::selectionRangeViewRects const):
(WTR::UIScriptController::platformSetDidShowMenuCallback):
(WTR::UIScriptController::platformSetDidHideMenuCallback):
Tweak these to use
platformContentView
instead of grabbing the content view from WKWebView directly.
(WTR::UIScriptController::rectForMenuAction const):
Add a new UIScriptController method to get the rect of the action in the contextual menu (on iOS, this is the
callout bar) whose label matches the given string.
(WTR::UIScriptController::platformContentView const):
Add a
platformContentView()
helper on UIScriptController so that we can stop grabbing the value for key
"_currentContentView" from various places in this file. Additionally, rewriteplatformUndoManager()
in terms
of this new helper, and move the code out from iOS/macOS-specific files into UIScriptControllerCocoa.
(WTR::UIScriptController::platformUndoManager const): Deleted.
- WebKitTestRunner/mac/UIScriptControllerMac.mm:
(WTR::UIScriptController::platformContentView const):
(WTR::UIScriptController::platformUndoManager const): Deleted.
LayoutTests:
Add new tests to exercise programmatic pasting.
- TestExpectations:
- editing/pasteboard/ios/dom-paste-confirmation-expected.txt: Added.
- editing/pasteboard/ios/dom-paste-confirmation.html: Added.
Verify that the user can tap "Paste" to allow programmatic pasting.
- editing/pasteboard/ios/dom-paste-consecutive-confirmations-expected.txt: Added.
- editing/pasteboard/ios/dom-paste-consecutive-confirmations.html: Added.
Verify that DOM paste access isn't carried over when using
setTimeout
in a user gesture event handler.
- editing/pasteboard/ios/dom-paste-rejection-expected.txt: Added.
- editing/pasteboard/ios/dom-paste-rejection.html: Added.
Verify that resigning first responder dismisses the callout bar and does not allow programmatic pasting.
- editing/pasteboard/ios/dom-paste-requires-user-gesture-expected.txt: Added.
- editing/pasteboard/ios/dom-paste-requires-user-gesture.html: Added.
Verify that user gesture is required to present the callout menu for a programmatic paste request.
- editing/pasteboard/ios/resources/dom-paste-helper.js: Added.
(return.new.Promise.):
(async._waitForOrTriggerPasteMenu):
(async.triggerPasteMenuAfterTapAt):
(async.waitForPasteMenu):
Add helpers to summon, wait for, and interact with the callout bar when the page attempts to trigger a paste.
- platform/ios-wk2/TestExpectations:
- platform/win/TestExpectations:
Skip editing/pasteboard/ios by default, and enable it only in the modern WebKit port of iOS.
- 2:55 PM Changeset in webkit [241321] by
-
- 67 edits1 copy1 add in trunk/Source
AX: IsolatedTree: Implement more attributes
https://bugs.webkit.org/show_bug.cgi?id=193911
<rdar://problem/47599217>
Reviewed by Daniel Bates.
Source/WebCore:
Make use of new HIServices SPI to use a secondary AX thread.
Store root node/focused node status in IsolatedTree rather than on the element.
Implement the following attributes: children, parent, isIgnored, isTree, isTreeItem, relativeFrame, speechHint, title, description.
Implement hit-testing using relative-frames.
Ensure that WKAccessibilityWebPageObject queries happen on main thread when they need to.
- SourcesCocoa.txt:
- WebCore.xcodeproj/project.pbxproj:
- accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::generateIsolatedAccessibilityTree):
- accessibility/AXObjectCache.h:
(WebCore::AXObjectCache::focusedUIElementForPage):
- accessibility/AccessibilityAttachment.cpp:
(WebCore::AccessibilityAttachment::accessibilityText const):
(WebCore::AccessibilityAttachment::accessibilityText): Deleted.
- accessibility/AccessibilityAttachment.h:
- accessibility/AccessibilityImageMapLink.cpp:
(WebCore::AccessibilityImageMapLink::accessibilityText const):
(WebCore::AccessibilityImageMapLink::accessibilityText): Deleted.
- accessibility/AccessibilityImageMapLink.h:
- accessibility/AccessibilityMediaControls.cpp:
(WebCore::AccessibilityMediaControl::accessibilityText const):
(WebCore::AccessibilityMediaControl::accessibilityText): Deleted.
- accessibility/AccessibilityMediaControls.h:
- accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::accessibilityText const):
(WebCore::AccessibilityNodeObject::accessibilityText): Deleted.
- accessibility/AccessibilityNodeObject.h:
- accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::convertFrameToSpace const):
(WebCore::AccessibilityObject::relativeFrame const):
(WebCore::AccessibilityObject::elementAccessibilityHitTest const):
(WebCore::AccessibilityObject::focusedUIElement const):
- accessibility/AccessibilityObject.h:
(WebCore::AccessibilityObject::accessibilityText const):
(WebCore::AccessibilityObject::isLink const): Deleted.
(WebCore::AccessibilityObject::isImage const): Deleted.
(WebCore::AccessibilityObject::isAttachment const): Deleted.
(WebCore::AccessibilityObject::isFileUploadButton const): Deleted.
(WebCore::AccessibilityObject::isImageMapLink const): Deleted.
(WebCore::AccessibilityObject::isMediaControlLabel const): Deleted.
(WebCore::AccessibilityObject::isTree const): Deleted.
(WebCore::AccessibilityObject::isTreeItem const): Deleted.
(WebCore::AccessibilityObject::isScrollbar const): Deleted.
(WebCore::AccessibilityObject::accessibilityHitTest const): Deleted.
(WebCore::AccessibilityObject::accessibilityText): Deleted.
(WebCore::AccessibilityObject::roleValue const): Deleted.
(WebCore::AccessibilityObject::wrapper const): Deleted.
- accessibility/AccessibilityObjectInterface.h: Replaced.
- accessibility/AccessibilityRenderObject.cpp:
(WebCore::AccessibilityRenderObject::isTabItemSelected const):
(WebCore::AccessibilityRenderObject::remoteSVGElementHitTest const):
(WebCore::AccessibilityRenderObject::elementAccessibilityHitTest const):
(WebCore::AccessibilityRenderObject::accessibilityHitTest const):
(WebCore::AccessibilityRenderObject::selectedChildren):
- accessibility/AccessibilityRenderObject.h:
- accessibility/AccessibilitySVGElement.cpp:
(WebCore::AccessibilitySVGElement::accessibilityText const):
(WebCore::AccessibilitySVGElement::accessibilityText): Deleted.
- accessibility/AccessibilitySVGElement.h:
- accessibility/AccessibilityScrollView.cpp:
(WebCore::AccessibilityScrollView::accessibilityHitTest const):
- accessibility/AccessibilityScrollView.h:
- accessibility/ios/AccessibilityObjectIOS.mm:
(WebCore::AccessibilityObject::fileUploadButtonReturnsValueInTitle const):
- accessibility/ios/WebAccessibilityObjectWrapperIOS.mm:
(-[WebAccessibilityObjectWrapper fileUploadButtonReturnsValueInTitle]): Deleted.
- accessibility/isolatedtree: Replaced.
- accessibility/isolatedtree/AXIsolatedTree.cpp: Added.
(WebCore::AXIsolatedTree::treePageCache):
(WebCore::AXIsolatedTree::AXIsolatedTree):
(WebCore::AXIsolatedTree::nodeInTreeForID):
(WebCore::AXIsolatedTree::nodeForID const):
(WebCore::AXIsolatedTree::focusedUIElement):
(WebCore::AXIsolatedTree::setRootNodeID):
(WebCore::AXIsolatedTree::setFocusedNodeID):
(WebCore::AXIsolatedTree::setInitialRequestInProgress):
(WebCore::AXIsolatedTree::applyPendingChanges):
- accessibility/isolatedtree/AXIsolatedTree.h: Added.
- accessibility/isolatedtree/AXIsolatedTreeNode.cpp: Added.
(WebCore::AXIsolatedTreeNode::AXIsolatedTreeNode):
(WebCore::AXIsolatedTreeNode::~AXIsolatedTreeNode):
(WebCore::AXIsolatedTreeNode::initializeAttributeData):
(WebCore::AXIsolatedTreeNode::setProperty):
(WebCore::AXIsolatedTreeNode::setParent):
(WebCore::AXIsolatedTreeNode::setTreeIdentifier):
(WebCore::AXIsolatedTreeNode::focusedUIElement const):
(WebCore::AXIsolatedTreeNode::parentObjectInterfaceUnignored const):
(WebCore::AXIsolatedTreeNode::accessibilityHitTest const):
(WebCore::AXIsolatedTreeNode::tree const):
(WebCore::AXIsolatedTreeNode::rectAttributeValue const):
(WebCore::AXIsolatedTreeNode::stringAttributeValue const):
- accessibility/isolatedtree/AXIsolatedTreeNode.h: Added.
- accessibility/mac/AXObjectCacheMac.mm:
(WebCore::AXObjectCache::associateIsolatedTreeNode):
- accessibility/mac/AccessibilityObjectBase.mm: Added.
(WebCore::AccessibilityObject::speechHintAttributeValue const):
(WebCore::AccessibilityObject::descriptionAttributeValue const):
(WebCore::AccessibilityObject::titleAttributeValue const):
(WebCore::AccessibilityObject::helpTextAttributeValue const):
- accessibility/mac/AccessibilityObjectMac.mm:
(WebCore::AccessibilityObject::fileUploadButtonReturnsValueInTitle const):
- accessibility/mac/WebAccessibilityObjectWrapperBase.h:
- accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
(addChildToArray):
(convertToNSArray):
(-[WebAccessibilityObjectWrapperBase isolatedTreeNode]):
(-[WebAccessibilityObjectWrapperBase detach]):
(-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
(-[WebAccessibilityObjectWrapperBase accessibilityObject]):
(-[WebAccessibilityObjectWrapperBase baseAccessibilityTitle]):
(-[WebAccessibilityObjectWrapperBase axBackingObject]):
(-[WebAccessibilityObjectWrapperBase baseAccessibilityDescription]):
(-[WebAccessibilityObjectWrapperBase baseAccessibilitySpeechHint]):
(-[WebAccessibilityObjectWrapperBase baseAccessibilityHelpText]):
(convertPathToScreenSpaceFunction):
(-[WebAccessibilityObjectWrapperBase convertRectToSpace:space:]):
(-[WebAccessibilityObjectWrapperBase ariaLandmarkRoleDescription]):
(-[WebAccessibilityObjectWrapperBase titleTagShouldBeUsedInDescriptionField]): Deleted.
(-[WebAccessibilityObjectWrapperBase fileUploadButtonReturnsValueInTitle]): Deleted.
- accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
(-[WebAccessibilityObjectWrapper IGNORE_WARNINGS_END]):
(-[WebAccessibilityObjectWrapper childrenVectorSize]):
(-[WebAccessibilityObjectWrapper childrenVectorArray]):
(-[WebAccessibilityObjectWrapper position]):
(-[WebAccessibilityObjectWrapper subrole]):
(-[WebAccessibilityObjectWrapper roleDescription]):
(-[WebAccessibilityObjectWrapper accessibilityAttributeValue:]):
(-[WebAccessibilityObjectWrapper accessibilityFocusedUIElement]):
(-[WebAccessibilityObjectWrapper accessibilityHitTest:]):
(-[WebAccessibilityObjectWrapper accessibilityIndexOfChild:]):
(-[WebAccessibilityObjectWrapper accessibilityArrayAttributeCount:]):
(-[WebAccessibilityObjectWrapper accessibilityArrayAttributeValues:index:maxCount:]):
Source/WebCore/PAL:
- pal/spi/mac/HIServicesSPI.h:
Source/WebKit:
- Platform/spi/mac/AccessibilityPrivSPI.h: Added.
- WebKit.xcodeproj/project.pbxproj:
- WebProcess/WebPage/mac/WKAccessibilityWebPageObjectBase.h:
- WebProcess/WebPage/mac/WKAccessibilityWebPageObjectBase.mm:
(-[WKAccessibilityWebPageObjectBase clientSupportsIsolatedTree]):
(-[WKAccessibilityWebPageObjectBase isolatedTreeRootObject]):
(-[WKAccessibilityWebPageObjectBase accessibilityRootObjectWrapper]):
- WebProcess/WebPage/mac/WKAccessibilityWebPageObjectMac.mm:
(-[WKAccessibilityWebPageObject IGNORE_WARNINGS_END]):
(-[WKAccessibilityWebPageObject convertScreenPointToRootView:]):
(-[WKAccessibilityWebPageObject accessibilityAttributeValue:]):
(-[WKAccessibilityWebPageObject accessibilityAttributeSizeValue]):
(-[WKAccessibilityWebPageObject accessibilityAttributePositionValue]):
(-[WKAccessibilityWebPageObject accessibilityDataDetectorValue:point:]):
(-[WKAccessibilityWebPageObject accessibilityAttributeValue:forParameter:]):
(-[WKAccessibilityWebPageObject accessibilityHitTest:]):
- 2:37 PM Changeset in webkit [241320] by
-
- 36 edits1 add in trunk/Source
Allow pages to trigger programmatic paste from script on iOS
https://bugs.webkit.org/show_bug.cgi?id=194271
<rdar://problem/47808810>
Reviewed by Ryosuke Niwa.
Source/WebCore:
Add support for allowing script to trigger programmatic paste commands. Currently on macOS and iOS, the ability
to trigger programmatic paste (i.e.document.execCommand('Paste');
) is disabled by default, such that
execCommand is simply a no-op that returns false. This policy is a privacy measure (common among other major
browsers) that prevents untrusted web content from sniffing content from the system pasteboard (even on user
interaction, since unintended user interaction occasionally happens as well!).
In order to make it possible for web pages to programmatically paste without opening the door to privacy and
security issues, we make paste commands triggered from bindings present platform UI on iOS, in the form of a
callout bar with the single option to paste. This UI is dismissed upon any user interaction; furthermore, any
user interaction short of explicitly triggering the "Paste" action subsequently prevents the page from executing
the paste (and causes execCommand to return false). However, if the paste action is chosen by the user, we
instead follow through with the programmatic paste command.
New tests to come in a followup patch.
- WebCore.xcodeproj/project.pbxproj:
- dom/DOMPasteAccessPolicy.h: Added.
- dom/UserGestureIndicator.h:
(WebCore::UserGestureToken::domPasteAccessPolicy const):
(WebCore::UserGestureToken::didRequestDOMPasteAccess):
Add helpers on UserGestureToken to update and query the current DOM paste access policy. The access policies are
"NotRequestedYet" (i.e. pending a response from the user), "Granted" (the user has granted DOM paste access to
the page), or "Denied" (the user has prevented the page from reading the contents of the clipboard). When DOM
paste access is granted or rejected, make this decision sticky until the end of the current user gesture.
- editing/EditorCommand.cpp:
(WebCore::executePaste):
(WebCore::executePasteAndMatchStyle):
(WebCore::executePasteAsPlainText):
(WebCore::executePasteAsQuotation):
When executing a paste command where the source is DOM bindings, request DOM paste if needed before proceeding
with the paste.
(WebCore::supportedPaste):
- loader/EmptyClients.cpp:
- page/EditorClient.h:
- page/Frame.cpp:
(WebCore::Frame::requestDOMPasteAccess):
Add a helper method that requests access to the clipboard on behalf of script when pasting.
- page/Frame.h:
- page/Settings.yaml:
Introduce a new WebCore setting, used to gate DOM paste access requests.
Source/WebKit:
- Shared/WebPreferences.yaml:
- Shared/WebPreferencesDefaultValues.h:
Add an internal setting to enable or disable DOM paste access requests. This is on by default in iOS only
(excluding watchOS and Apple TV), and is additionally disabled on macOS.
- UIProcess/API/gtk/PageClientImpl.cpp:
(WebKit::PageClientImpl::requestDOMPasteAccess):
- UIProcess/API/gtk/PageClientImpl.h:
- UIProcess/API/wpe/PageClientImpl.cpp:
(WebKit::PageClientImpl::requestDOMPasteAccess):
Plumb DOM paste access requests from the web process (WebEditorClient) to the view (WKContentView). As per the
usual, this involves WebEditorClient, WebPage, WebPageProxy, PageClient and finally WKContentView.
- UIProcess/API/wpe/PageClientImpl.h:
- UIProcess/PageClient.h:
- UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::requestDOMPasteAccess):
- UIProcess/WebPageProxy.h:
- UIProcess/WebPageProxy.messages.in:
- UIProcess/ios/PageClientImplIOS.h:
- UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::requestDOMPasteAccess):
- UIProcess/ios/WKContentViewInteraction.h:
- UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView setupInteraction]):
(-[WKContentView cleanupInteraction]):
(-[WKContentView resignFirstResponderForWebView]):
(-[WKContentView _webTouchEventsRecognized:]):
Bail from any pending DOM paste access handler the moment we start handling touches on the web view, or if the
web view resigns first responder, or if the web process crashes.
(-[WKContentView textInteractionGesture:shouldBeginAtPoint:]):
Reject text selection gestures while waiting for DOM paste access.
(-[WKContentView canPerformAction:withSender:]):
(-[WKContentView canPerformActionForWebView:withSender:]):
If we're handling a DOM paste, always return YES to allow the callout bar to show the "Paste" option.
(-[WKContentView _didHideMenu:]):
If the menu is programmatically hidden by the app while handling a DOM paste request, immediately reject the DOM
paste request.
(-[WKContentView pasteForWebView:]):
Adjust -pasteForWebView: on WKContentView to first check whether there's an outstanding DOM paste completion
handler to invoke, instead of telling the page to execute a paste command.
(-[WKContentView _handleDOMPasteRequestWithResult:]):
Add a helper to take and invoke the current DOM paste completion handler (if it exists) with the given result,
and then dismiss the shared callout bar. Returns whether or not the paste completion handler exists. Invoked
from various sources of user interaction or significant state changes (e.g. following a web process crash in
-cleanupInteraction).
(-[WKContentView _willPerformAction:sender:]):
(-[WKContentView _didPerformAction:sender:]):
Add hooks to detect when WKContentView is executing an editing action. This is to ensure that the page doesn't
get stuck in a bad state in the case where WKWebView has been subclassed, overrides-paste:
, and does not
invoke the superclass method (which calls back into-[WKContentView pasteForWebView:]
). There are a few
possibilities here:
- WKWebView's
-paste:
action is not overridden. In this case, we will call back into-pasteForWebView:
, which will notice that we have a pending paste completion handler and invoke it. - WKWebView's
-paste:
action is overridden and does not call back into the content view. In this case, we will invoke the paste completion handler in-_didPerformAction:sender:
. - WKWebView's
-canPerformAction:withSender:
is overridden to include additional actions. In this case, we may get a call to invoke a different action selector while waiting for a potential paste action. If this happens, prevent the DOM paste in-_willPerformAction:sender:
prior to handling the other action.
(-[WKContentView handleKeyWebEvent:withCompletionHandler:]):
Dismiss DOM paste UI upon handling any key event.
(-[WKContentView showGlobalMenuControllerInRect:]):
(-[WKContentView hideGlobalMenuController]):
Helper methods to present and dismiss the global UIMenuController, that accounts for available platform APIs for
presenting or dismissing the menu controller on iOS.
(-[WKContentView _requestDOMPasteAccessWithElementRect:completionHandler:]):
Attempt to find a good target presentation rect when showing the callout menu. First, we will try to use the
rect of the element the user has interacted with when triggering the paste. If such an element is too large or
does not exist, we fall back to presenting the callout menu near the user's last touch location (with a small
amount of margin, such that the action doesn't overlap with the user's finger, stylus, etc.).
(-[WKContentView _resetShowingTextStyle:]): Deleted.
Rename this to
-_didHideMenu:
.
- UIProcess/mac/PageClientImplMac.h:
- UIProcess/win/PageClientImpl.cpp:
(WebKit::PageClientImpl::requestDOMPasteAccess):
- UIProcess/win/PageClientImpl.h:
- WebProcess/WebCoreSupport/WebEditorClient.cpp:
(WebKit::WebEditorClient::requestDOMPasteAccess):
- WebProcess/WebCoreSupport/WebEditorClient.h:
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::requestDOMPasteAccess):
Add more plumbing and method stubs.
(WebKit::WebPage::updateCurrentModifierState):
(WebKit::WebPage::rectForElementAtInteractionLocation const):
- WebProcess/WebPage/WebPage.h:
- WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::rectForElementAtInteractionLocation const):
(WebKit::WebPage::rectForElementAtInteractionLocation): Deleted.
Mark this method as const, add a platform-agnostic stub, and adopt it for the purposes of determining where to
position the callout bar when pasting.
Source/WebKitLegacy/mac:
See WebCore and WebKit ChangeLogs for more details.
- WebCoreSupport/WebEditorClient.h:
Source/WebKitLegacy/win:
- WebCoreSupport/WebEditorClient.h:
- 1:57 PM Changeset in webkit [241319] by
-
- 3 edits2 adds in trunk
Source/WebCore:
Remove setDefersLoading infrastructure from WebKit2
https://bugs.webkit.org/show_bug.cgi?id=194506
Patch by Alex Christensen <achristensen@webkit.org> on 2019-02-12
Reviewed by Brady Eidson.
setDefersLoading is inherently racy from WebCore to the NetworkProcess,
it adds unwanted complexity to the initialization and use of network objects,
and it has led to many unrecoverable hang bugs over the years.
We needed to force it into WebKit2 to transition some existing clients who relied on it,
but we have recently finished transitioning those clients to other solutions, mostly
completion handlers.
- inspector/PageScriptDebugServer.cpp:
(WebCore::PageScriptDebugServer::setJavaScriptPaused):
LayoutTests:
BitmapRenderer should handle existing ImageBuffers
https://bugs.webkit.org/show_bug.cgi?id=194555
<rdar://problem/47857150>
Reviewed by Tim Horton.
Test that creates a canvas, triggers an ImageBuffer to be created, then
creates the bitmaprenderer context.
- fast/canvas/bitmaprenderer-created-after-toBlob-expected.txt: Added.
- fast/canvas/bitmaprenderer-created-after-toBlob.html: Added.
- 1:53 PM Changeset in webkit [241318] by
-
- 3 edits in trunk/Tools
webkitpy: No option to only show unexpected failures in results.html for iPad
https://bugs.webkit.org/show_bug.cgi?id=194554
<rdar://problem/47922442>
Rubber-stamped by Aakash Jain.
Just because a TestExpecations file does not exist for a specific platform does not mean that
TestExpecations are not being used, given that platforms inherit test expectations.
- Scripts/webkitpy/port/base.py:
(Port.uses_test_expectations_file): Check all possible locations of a TestExpectations file.
- Scripts/webkitpy/port/base_unittest.py:
(PortTest.test_uses_test_expectations_file):
- 1:49 PM Changeset in webkit [241317] by
-
- 28 edits in trunk
Remove setDefersLoading infrastructure from WebKit2
https://bugs.webkit.org/show_bug.cgi?id=194506
Reviewed by Brady Eidson.
Source/WebCore:
setDefersLoading is inherently racy from WebCore to the NetworkProcess,
it adds unwanted complexity to the initialization and use of network objects,
and it has led to many unrecoverable hang bugs over the years.
We needed to force it into WebKit2 to transition some existing clients who relied on it,
but we have recently finished transitioning those clients to other solutions, mostly
completion handlers.
- inspector/PageScriptDebugServer.cpp:
(WebCore::PageScriptDebugServer::setJavaScriptPaused):
Source/WebKit:
- NetworkProcess/NetworkConnectionToWebProcess.cpp:
(WebKit::NetworkConnectionToWebProcess::setDefersLoading): Deleted.
- NetworkProcess/NetworkConnectionToWebProcess.h:
- NetworkProcess/NetworkConnectionToWebProcess.messages.in:
- NetworkProcess/NetworkDataTask.h:
- NetworkProcess/NetworkDataTaskBlob.cpp:
(WebKit::NetworkDataTaskBlob::suspend): Deleted.
- NetworkProcess/NetworkDataTaskBlob.h:
- NetworkProcess/NetworkLoad.cpp:
(WebKit::NetworkLoad::initialize):
(WebKit::NetworkLoad::setDefersLoading): Deleted.
- NetworkProcess/NetworkLoad.h:
- NetworkProcess/NetworkLoadParameters.h:
- NetworkProcess/NetworkResourceLoadParameters.cpp:
(WebKit::NetworkResourceLoadParameters::encode const):
(WebKit::NetworkResourceLoadParameters::decode):
- NetworkProcess/NetworkResourceLoader.cpp:
(WebKit::NetworkResourceLoader::start):
(WebKit::NetworkResourceLoader::startNetworkLoad):
(WebKit::NetworkResourceLoader::setDefersLoading): Deleted.
- NetworkProcess/NetworkResourceLoader.h:
- NetworkProcess/cocoa/NetworkDataTaskCocoa.h:
- NetworkProcess/cocoa/NetworkDataTaskCocoa.mm:
(WebKit::NetworkDataTaskCocoa::suspend): Deleted.
- NetworkProcess/curl/NetworkDataTaskCurl.cpp:
(WebKit::NetworkDataTaskCurl::suspend): Deleted.
- NetworkProcess/curl/NetworkDataTaskCurl.h:
- NetworkProcess/soup/NetworkDataTaskSoup.cpp:
(WebKit::NetworkDataTaskSoup::suspend): Deleted.
- NetworkProcess/soup/NetworkDataTaskSoup.h:
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
(WebKit::WebLoaderStrategy::setDefersLoading):
Tools:
- WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
- WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::setDefersLoading): Deleted.
- WebKitTestRunner/InjectedBundle/TestRunner.h:
LayoutTests:
- platform/wk2/TestExpectations:
- 1:35 PM Changeset in webkit [241316] by
-
- 6 edits in trunk/Source
Unreviewed, fix build warnings after content extensions enablement
https://bugs.webkit.org/show_bug.cgi?id=193622
<rdar://problem/47982850>
Source/WebCore:
- contentextensions/DFABytecode.h:
(WebCore::ContentExtensions::instructionSizeWithArguments):
- contentextensions/DFABytecodeCompiler.h:
- contentextensions/URLFilterParser.cpp:
(WebCore::ContentExtensions::URLFilterParser::statusString):
Source/WebKit:
- UIProcess/API/C/WKUserContentExtensionStoreRef.cpp:
(toResult):
- 1:21 PM Changeset in webkit [241315] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: Timeline.prototype.recordsInTimeRange uses a property most records do not have
https://bugs.webkit.org/show_bug.cgi?id=194549
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-12
Reviewed by Devin Rousso.
- UserInterface/Models/Timeline.js:
(WI.Timeline.prototype.recordsInTimeRange):
- 1:17 PM Changeset in webkit [241314] by
-
- 2 edits in trunk/Source/JavaScriptCore
Unreviewed, fix -Wimplicit-fallthrough warning after r241140
https://bugs.webkit.org/show_bug.cgi?id=194399
<rdar://problem/47889777>
- dfg/DFGDoesGC.cpp:
(JSC::DFG::doesGC):
- 1:13 PM Changeset in webkit [241313] by
-
- 7 edits1 add in branches/safari-607-branch
Apply patch. rdar://problem/48009995
- 12:44 PM Changeset in webkit [241312] by
-
- 7 edits in branches/safari-607-branch/Source
Versioning.
- 12:30 PM Changeset in webkit [241311] by
-
- 5 edits in trunk/Source/WebKit
Switching focus from a UITextField to an editable WKWebView causes the keyboard to dance
https://bugs.webkit.org/show_bug.cgi?id=194524
<rdar://problem/35481797>
Reviewed by Wenson Hsieh.
- Platform/spi/ios/UIKitSPI.h:
- UIProcess/ios/InputViewUpdateDeferrer.h:
- UIProcess/ios/InputViewUpdateDeferrer.mm:
(WebKit::InputViewUpdateDeferrer::InputViewUpdateDeferrer):
(WebKit::InputViewUpdateDeferrer::~InputViewUpdateDeferrer):
Make use of the per-responder and much safer input view pinning mechanism.
- UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView becomeFirstResponderForWebView]):
(-[WKContentView _singleTapCommited:]):
(-[WKContentView _attemptClickAtLocation:modifierFlags:]):
Always temporarily pin input views when becoming first responder; there are
many paths (such as through the text interaction assistant) that can
focus us on tap, trying to cover them all is a fool's errand. We'll
just get out the big hammer and call it in becomeFirstResponder.
This also means we can remove it from _singleTapCommitted and _attemptClick...
(-[WKContentView _elementDidFocus:userIsInteracting:blurPreviousNode:changingActivityState:userObject:]):
Don't release the input view pinning until we return from _elementDidFocus;
it does the rebuilding synchronously, so we need to have actually updated
all of the prerequisites of -inputView before depinning.
- 12:11 PM Changeset in webkit [241310] by
-
- 24 edits1 copy4 moves3 adds1 delete in trunk
[Web GPU] DepthStencilAttachment implementation
https://bugs.webkit.org/show_bug.cgi?id=194458
<rdar://problem/47932446>
Reviewed by Dean Jackson.
Source/WebCore:
Implement ability to provide a depth attachment to the render pass encoder. Also implement
GPULoad/StoreOp and update color attachments' implementation for full functionality.
Test: webgpu/depth-enabled-triangle-strip.html
Update project files for new symbols:
- CMakeLists.txt:
- DerivedSources-input.xcfilelist:
- DerivedSources-output.xcfilelist:
- DerivedSources.make:
- Sources.txt:
- WebCore.xcodeproj/project.pbxproj:
- Modules/webgpu/GPUColor.idl: Renamed from WebGPUColor.idl
- Modules/webgpu/GPULoadOp.idl: Added. Interface for attachment operation enum.
- Modules/webgpu/GPUStoreOp.idl: Ditto.
- Modules/webpug/WebGPUColor.h: Removed.
- Modules/webgpu/WebGPUCommandBuffer.cpp: Refactored descriptor validation logic out of this file.
(WebCore::WebGPUCommandBuffer::beginRenderPass):
- Modules/webgpu/WebGPURenderPassDescriptor.cpp: Added. Now owns code for validating descriptors.
(WebCore::WebGPURenderPassDescriptor::validateAndConvertToGPUVersion const):
- Modules/webgpu/WebGPURenderPassColorAttachmentDescriptor.h/idl: Removed. Code moved into WebGPURenderPassDescriptor.
- Modules/webgpu/WebGPURenderPassDescriptor.h: Move sub-descriptor definitions into this file.
- Modules/webgpu/WebGPURenderPassDescriptor.idl: Ditto.
- Modules/webgpu/WebGPURenderPipelineDescriptor.h: Make depthStencilState optional to match API update.
- Modules/webgpu/WebGPURenderPipelineDescriptor.idl: Ditto.
- Modules/webgpu/WebGPUTextureView.h:
- platform/graphics/gpu/GPULoadOp.h: Added.
- platform/graphics/gpu/GPURenderPassColorAttachmentDescriptor.h: Removed (moved into GPURenderPassDescriptor).
- platform/graphics/gpu/GPURenderPassDescriptor.h: Mirror WebGPU* changes.
- platform/graphics/gpu/GPURenderPipelineDescriptor.h: Make depthStencilState optional.
(WebCore::GPURenderPipelineDescriptor::GPURenderPipelineDescriptor):
- platform/graphics/gpu/GPUStoreOp.h: Added.
- platform/graphics/gpu/GPUTexture.h:
- platform/graphics/gpu/cocoa/GPURenderPassEncoderMetal.mm:
(WebCore::loadActionForGPULoadOp): Added.
(WebCore::storeActionForGPUStoreOp): Added.
(WebCore::populateMtlColorAttachmentsArray): Added. Create all expected color attachments, rather than just the first.
(WebCore::populateMtlDepthStencilAttachment): Added.
(WebCore::GPURenderPassEncoder::create):
- platform/graphics/gpu/cocoa/GPURenderPipelineMetal.mm: Make depthStencilState optional.
(WebCore::GPURenderPipeline::create):
LayoutTests:
Add test and update utility functions for depth texture attachments. Update others to specify their
loadOp and storeOp for all render pass attachments, as these are no longer provided by default by the implementation.
- webgpu/buffer-resource-triangles.html:
- webgpu/depth-enabled-triangle-strip-expected.html: Added.
- webgpu/depth-enabled-triangle-strip.html: Added.
- webgpu/js/basic-webgpu-functions.js:
(render):
- webgpu/js/webgpu-functions.js:
(createBasicDepthStateDescriptor):
(createBasicDepthTexture):
(beginBasicRenderPass):
(createBasicPipeline): Deleted.
- webgpu/render-command-encoding.html:
- webgpu/render-passes.html:
- 11:58 AM Changeset in webkit [241309] by
-
- 7 edits in trunk/Source
REGRESSION (r238955, r240494): Soft-linking optional Lookup.framework triggers release assertion when missing
<https://webkit.org/b/194529>
<rdar://problem/47924449>
Reviewed by Eric Carlson.
Source/WebCore:
- SourcesCocoa.txt:
- Do not include DataDetectorsCoreSoftLink.mm in unified sources.
- WebCore.xcodeproj/project.pbxproj:
- Add DataDetectorsCoreSoftLink.mm to the WebCore target now that it isn't part of the unifed sources.
- platform/cocoa/DataDetectorsCoreSoftLink.mm:
- Switch from using SOFT_LINK_PRIVATE_FRAMEWORK_OPTIONAL() to SOFT_LINK_PRIVATE_FRAMEWORK_FOR_SOURCE() when linking DataDetectorsCore.framework. None of the other macros assume this framework is optional, and it was likely made optional originally because the framework was new to iOS and thus didn't exist on older versions.
- platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
- Change use of SOFT_LINK_CLASS_FOR_SOURCE() macros to SOFT_LINK_CLASS() since the latter can only be used with SOFT_LINK_FRAMEWORK_OPTIONAL(AVFoundation). This broke after the fix for <wtf/SoftLinking.h> was applied.
Source/WTF:
- wtf/cocoa/SoftLinking.h:
(SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT_AND_IS_OPTIONAL): Rename
SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT_AND_ASSERTION() to this
and changeassertion
argument toisOptional
. Pass
isOptional
to framework##Library() method to control assertion
behavior. Only check RELEASE_ASSERT() if!isOptional
, else
that code should be optimized out by the compiler. This fixes
the crash.
(NO_ASSERT): Remove macro since it's no longer used.
(SOFT_LINK_IS_OPTIONAL): Add macro to use for soft-linking
optional classes.
(SOFT_LINK_IS_NOT_OPTIONAL): Add macro to use for soft-linking
non-optional classes.
(SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT): Update to use new
SOFT_LINK_CLASS_FOR_SOURCE_WITH_EXPORT_AND_IS_OPTIONAL() macro.
(SOFT_LINK_CLASS_FOR_SOURCE_OPTIONAL_WITH_EXPORT): Ditto.
(SOFT_LINK_CLASS_FOR_SOURCE): Ditto.
(SOFT_LINK_CLASS_FOR_SOURCE_OPTIONAL): Ditto.
- 11:53 AM Changeset in webkit [241308] by
-
- 5 edits in trunk/Source
Make use of is<SubresourceLoader>
https://bugs.webkit.org/show_bug.cgi?id=194541
Reviewed by Alex Christensen.
Source/WebCore:
No change of behavior.
- inspector/agents/InspectorNetworkAgent.cpp:
(WebCore::InspectorNetworkAgent::didReceiveResponse):
- loader/SubresourceLoader.h:
(isType):
Source/WebKit:
- WebProcess/Network/WebLoaderStrategy.cpp:
(WebKit::WebLoaderStrategy::scheduleLoadFromNetworkProcess):
- 11:51 AM Changeset in webkit [241307] by
-
- 3 edits in trunk/LayoutTests
AX: Fix flaky accessibility/loading-iframe-sends-notification.html
https://bugs.webkit.org/show_bug.cgi?id=194546
Reviewed by Zalan Bujtas.
This test was relying on timing between load events being sent and accessibility events being sent.
We don't need to do that, we can more directly test this interplay.
- accessibility/loading-iframe-sends-notification-expected.txt:
- accessibility/loading-iframe-sends-notification.html:
- 11:29 AM Changeset in webkit [241306] by
-
- 7 edits1 add in trunk
WebPage::close needs to remove all message receivers associated with that WebPage, not WebPage::~WebPage
https://bugs.webkit.org/show_bug.cgi?id=194522
<rdar://problem/47789393>
Reviewed by Chris Dumez.
Source/WebKit:
The InjectedBundle SPI can retain the WebPage or wrapping objects (WKWebProcessPlugInBrowserContextController/WKBundlePageRef).
This can make it so WebPage::close is called before WebPage::~WebPage, and if the SuspendedPageProxy is reused for a subsequent
navigation to the same domain, the WebProcess is reused with a different WebPage instance with the same PageID, which causes problems
when another WebPage registers message handlers and then the previous WebPage is destroyed, which removes both message handlers.
- WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::~WebPage):
(WebKit::WebPage::close):
(WebKit::WebPage::mainFrameDidLayout):
- WebProcess/WebPage/WebPage.h:
- WebProcess/WebProcess.h:
(WebKit::WebProcess::eventDispatcher):
Tools:
- TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
- TestWebKitAPI/Tests/WebKitCocoa/BundleRetainPagePlugIn.mm: Added.
(-[BundleRetainPagePlugIn webProcessPlugIn:didCreateBrowserContextController:]):
- TestWebKitAPI/Tests/WebKitCocoa/ProcessSwapOnNavigation.mm:
- 11:20 AM Changeset in webkit [241305] by
-
- 5 edits in trunk/Source/bmalloc
Unreviewed, rolling out r241182.
https://bugs.webkit.org/show_bug.cgi?id=194547
causes a 2-3% Speedometer2 regression. (Requested by
keith_miller on #webkit).
Reverted changeset:
"bmalloc uses more memory on iOS compared to macOS due to
physical page size differences"
https://bugs.webkit.org/show_bug.cgi?id=192389
https://trac.webkit.org/changeset/241182
- 10:45 AM Changeset in webkit [241304] by
-
- 6 edits in trunk/Source
[WPE][GTK] Unsafe g_unsetenv() use in WebProcessPool::platformInitialize
https://bugs.webkit.org/show_bug.cgi?id=194370
Reviewed by Darin Adler.
Source/JavaScriptCore:
Change a couple WTFLogAlways to use g_warning, for good measure. Of course this isn't
necessary, but it will make errors more visible.
- inspector/remote/glib/RemoteInspectorGlib.cpp:
(Inspector::RemoteInspector::start):
(Inspector::dbusConnectionCallAsyncReadyCallback):
- inspector/remote/glib/RemoteInspectorServer.cpp:
(Inspector::RemoteInspectorServer::start):
Source/WebKit:
It is incorrect to use g_unsetenv() here because it is MT-Unsafe. We know that it is
impossible and unreasonable to expect the application has not started other threads at this
point, and threads will be calling getenv(). WebKit itself has probably already started
threads of its own.
Fortunately, the remote inspector in the web process is already prepared to deal with
failure to connect to the inspector server, so we don't need to do anything except stop
messing with the environment.
Note these files are copies of each other. I'll merge them together in a follow-up patch.
- UIProcess/gtk/WebProcessPoolGtk.cpp:
(WebKit::initializeRemoteInspectorServer):
(WebKit::WebProcessPool::platformInitialize):
- UIProcess/wpe/WebProcessPoolWPE.cpp:
(WebKit::initializeRemoteInspectorServer):
(WebKit::WebProcessPool::platformInitialize):
- 10:23 AM Changeset in webkit [241303] by
-
- 3 edits in trunk/Source/WebKit
Ensure old binaries have old snapshotting behaviors
https://bugs.webkit.org/show_bug.cgi?id=194449
-and corresponding-
rdar://problem/47931954
Reviewed by Darin Adler.
Make sure that a nil configuration behaves the same way that it used to on apps
that were linked before FirstWithSnapshotAfterScreenUpdates
- UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView takeSnapshotWithConfiguration:completionHandler:]):
- UIProcess/Cocoa/VersionChecks.h:
- 10:22 AM Changeset in webkit [241302] by
-
- 5 edits in trunk/Source/WebInspectorUI
Web Inspector: Timelines: clicking on an empty space in the overview should deselect any selected record bar
https://bugs.webkit.org/show_bug.cgi?id=194365
<rdar://problem/47868426>
Reviewed by Joseph Pecoraro.
- UserInterface/Views/TimelineRecordBar.js:
(WI.TimelineRecordBar.prototype._handleClick):
Mark the "click" event so that later listeners know it was handled byWI.TimelineRecordBar
.
- UserInterface/Views/TimelineOverview.js:
(WI.TimelineOverview):
(WI.TimelineOverview.prototype._instrumentAdded):
(WI.TimelineOverview.prototype._instrumentRemoved):
(WI.TimelineOverview.prototype._handleGraphsContainerClick): Added.
(WI.TimelineOverview.prototype._handleOverviewGraphRecordSelected): Added.
(WI.TimelineOverview.prototype._recordSelected):
Listen for "click" on the graph container and deselect all records when fired, unless the
click was marked by aWI.TimelineRecordBar
.
- UserInterface/Views/TimelineRecordingContentView.js:
(WI.TimelineRecordingContentView.prototype._recordSelected):
Ensure that allWI.TimelineView
update their selected record whenever it changes for any
otherWI.TimelineView
(or if there is no selected record).
- UserInterface/Views/TimelineOverviewGraph.js:
(WI.TimelineOverviewGraph.prototype.didLayoutSubtree): Added.
Drive-by: sinceWI.TimelineRecordBar
are reused when combining, we need to re-determine
which one holds the currently selected record.
- 10:21 AM Changeset in webkit [241301] by
-
- 2 edits in trunk/Source/WebInspectorUI
Web Inspector: Remove unused maxUsage in CPUTimelineView
https://bugs.webkit.org/show_bug.cgi?id=194526
Patch by Joseph Pecoraro <Joseph Pecoraro> on 2019-02-12
Reviewed by Devin Rousso.
- UserInterface/Views/CPUTimelineView.js:
(WI.CPUTimelineView):
(WI.CPUTimelineView.prototype.shown):
- 10:21 AM Changeset in webkit [241300] by
-
- 4 edits in trunk/Source/WebCore
Add some null checks in JSNodeCustom.h's root() and generated isReachableFromOpaqueRoots() functions.
https://bugs.webkit.org/show_bug.cgi?id=194530
<rdar://problem/47973274>
Reviewed by Chris Dumez.
This is needed to fix a null pointer dereference that arises from the following scenario:
- a Document detaches from its StyleSheetList.
- the JSStyleSheetList that is associated with the detached StyleSheetList has yet to be scanned and collected by the GC.
- the GC eventually looks for the opaque root of the StyleSheetList's owner, and discovers a null owner pointer.
This patch fixes this issue by applying the following null checks:
- Add a null check in JSNodeCustom.h's root().
root() is called from a isReachableFromOpaqueRoots() generated by CodeGeneratorJS.pm.
isReachableFromOpaqueRoots() calls a ownerNode() method and passes its result
to root(). However, depending on which class the ownerNode() method belongs to,
it can either return a pointer or a reference. The null check only makes sense
in the pointer case.
To accommodate the 2 forms, root() itself is has an overload that takes a
reference instead of a pointer.
Since CodeGeneratorJS.pm can't tell what the generated class' ownerNode()
returns, it can't discern when the result is a pointer and apply the null check.
Instead, we just add the null check to the version of root() that takes a
pointer. If the node pointer is null, we'll return a null opaque root.
- Fix CodeGeneratorJS.pm to null check the opaque root before using it.
- bindings/js/JSNodeCustom.h:
(WebCore::root):
- bindings/scripts/CodeGeneratorJS.pm:
(GenerateImplementation):
- bindings/scripts/test/JS/JSTestGenerateIsReachable.cpp:
(WebCore::JSTestGenerateIsReachableOwner::isReachableFromOpaqueRoots):
- 9:43 AM Changeset in webkit [241299] by
-
- 17 edits in trunk
[iOSMac] Enable Parental Controls Content Filtering
https://bugs.webkit.org/show_bug.cgi?id=194521
<rdar://39732376>
Reviewed by Tim Horton.
Source/JavaScriptCore:
- Configurations/FeatureDefines.xcconfig:
Source/WebCore:
- Configurations/FeatureDefines.xcconfig:
- platform/ContentFilterUnblockHandler.h:
- platform/cocoa/ContentFilterUnblockHandlerCocoa.mm:
- platform/cocoa/ParentalControlsContentFilter.mm:
Source/WebCore/PAL:
- Configurations/FeatureDefines.xcconfig:
Source/WebKit:
- Configurations/FeatureDefines.xcconfig:
Source/WebKitLegacy/mac:
- Configurations/FeatureDefines.xcconfig:
Source/WTF:
- wtf/Platform.h:
Tools:
- TestWebKitAPI/Configurations/FeatureDefines.xcconfig:
- 9:38 AM Changeset in webkit [241298] by
-
- 2 edits in trunk/LayoutTests
Unreviewed WPE gardening. Unskip content extensions tests after r241283
- platform/wpe/TestExpectations: Unskip content extensions tests, and list
as failing those known to not pass due to missing expectaions or timeouts.
- 8:53 AM Changeset in webkit [241297] by
-
- 5 edits in trunk/Source/WebCore
Source/WebCore:
Unreviewed build fix; add a HAVE_CELESTIAL guard around Celestial framework usage.
- platform/audio/ios/MediaSessionManagerIOS.h:
- platform/audio/ios/MediaSessionManagerIOS.mm:
(WebCore::MediaSessionManageriOS::providePresentingApplicationPIDIfNecessary):
Source/WebCore/PAL:
Unreviewed build fix; add a HAVE_CELESTIAL guard around the CelestialSPI.h contents.
- pal/spi/ios/CelestialSPI.h:
- 8:22 AM Changeset in webkit [241296] by
-
- 2 edits in trunk/Source/WebCore
Crash in WebCore::ScrollingTree::updateTreeFromStateNode
https://bugs.webkit.org/show_bug.cgi?id=194538
<rdar://problem/47841926>
Reviewed by Zalan Bujtas.
- page/scrolling/ScrollingTree.cpp:
(WebCore::ScrollingTree::updateTreeFromStateNode):
Make sure we don't leave node entry behind in m_nodeMap in case we failed to add it to the parent.
- 7:59 AM Changeset in webkit [241295] by
-
- 5 edits in trunk/Source/WebCore
[LFC] Remove redundant InlineFormattingContext::computeBorderAndPadding
https://bugs.webkit.org/show_bug.cgi?id=194540
Reviewed by Antti Koivisto.
Use FormattingContext::computeBorderAndPadding instead.
- layout/FormattingContext.cpp:
(WebCore::Layout::FormattingContext::computeBorderAndPadding const):
- layout/FormattingContext.h:
- layout/inlineformatting/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::computeBorderAndPadding const): Deleted.
- layout/inlineformatting/InlineFormattingContext.h:
- 7:42 AM WebKitGTK/2.22.x edited by
- (diff)
- 7:34 AM Changeset in webkit [241294] by
-
- 5 edits in trunk
[LFC][IFC] Add intrinsic width support for float boxes.
https://bugs.webkit.org/show_bug.cgi?id=194528
Reviewed by Antti Koivisto.
Source/WebCore:
This patch implements a very simple float box support for intrinsic width.
- layout/inlineformatting/InlineFormattingContext.cpp:
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthConstraints const):
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthForFloatBox const):
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthForInlineBlock const):
(WebCore::Layout::InlineFormattingContext::computeMargin const):
(WebCore::Layout::InlineFormattingContext::computeIntrinsicWidthForFormattingContextRoot const): Deleted.
- layout/inlineformatting/InlineFormattingContext.h:
Tools:
Expand tests coverage (2 new tests -> 800).
(This is the correct test ordering --runs-singly --child-processes=1)
- LayoutReloaded/misc/LFC-passing-tests.txt:
- 3:40 AM Changeset in webkit [241293] by
-
- 17 edits in releases/WebKitGTK/webkit-2.24
Revert r240363 - Deprecate API to limit the maximum number of WebProcesses
This reverts commit r240363.
- 3:19 AM WebKitGTK/2.24.x created by
- 2:47 AM Changeset in webkit [241292] by
-
- 1 copy in releases/WebKitGTK/webkit-2.24
Branch WebKitGTK for 2.24
- 2:04 AM Changeset in webkit [241291] by
-
- 5 edits in trunk
Implement serializing in MIME type parser
https://bugs.webkit.org/show_bug.cgi?id=193909
Patch by Rob Buis <rbuis@igalia.com> on 2019-02-12
Reviewed by Darin Adler.
Source/WebCore:
Implement serializing in MIME type parser [1], to preserve the parameter
order the Vector m_parameterNames is introduced, since HashMaps do not
guarantee any order.
Test: ParsedContentType.Serialize
[1] https://mimesniff.spec.whatwg.org/#serializing-a-mime-type
- platform/network/ParsedContentType.cpp:
(WebCore::skipSpaces):
(WebCore::parseQuotedString):
(WebCore::ParsedContentType::parseContentType):
(WebCore::ParsedContentType::parameterValueForName const):
(WebCore::ParsedContentType::parameterCount const):
(WebCore::ParsedContentType::setContentType):
(WebCore::ParsedContentType::setContentTypeParameter):
(WebCore::ParsedContentType::serialize const):
- platform/network/ParsedContentType.h:
Tools:
Add various tests involving upper case, non-ASCII, control/null characters,
various HTTP whitespace, single quotes and an unpaired surrogate.
- TestWebKitAPI/Tests/WebCore/ParsedContentType.cpp:
(TestWebKitAPI::escapeNonASCIIPrintableCharacters):
(TestWebKitAPI::serializeIfValid):
(TestWebKitAPI::TEST):
- 1:29 AM Changeset in webkit [241290] by
-
- 2 edits in trunk/Source/WebCore/PAL
[WPE][GTK] Sleep disabler code should inhibit idle when a "System" sleep disabler is requested
https://bugs.webkit.org/show_bug.cgi?id=194500
Reviewed by Carlos Garcia Campos.
There are three things wrong with the comment at the top of SleepDisablerGLib's constructor:
(1) Nowadays, GNOME suspends the computer automatically on inactivity, and we actually do
want to prevent that.
(2) Inhibiting idle does affect the autosuspend countdown. So the current code should
prevent automatic suspend, just not manual suspend. (I think I stand by my comment that
we do not want to inhibit normal suspend, since that would just be annoying.)
(3) I don't know why I thought HTMLMediaElement::shouldDisableSleep was suspicious.
Anyway, the behavior we want is to ignore the Type argument and just always inhibit idle.
That is, treat type=System the same way we current treat type=Display.
- pal/system/glib/SleepDisablerGLib.cpp:
(PAL::SleepDisablerGLib::SleepDisablerGLib):
- 1:28 AM Changeset in webkit [241289] by
-
- 11 edits in trunk
AXObjectCache::childrenChanged shouldn't update layout or style during another style recalc
https://bugs.webkit.org/show_bug.cgi?id=182280
<rdar://problem/37018386>
Reviewed by Alan Bujtas.
Source/WebCore:
Remove the possibility that changing children calls back into updating layout by
handling children changes in a deferred manner.
This follows the same architecture as many other deferred changes, but also requires us to check deferred changes
in updateBackingStore, because things like aria-hidden changes won't trigger a layout, but will require us to update children.
A few tests had to be modified to no longer change the tree and then check the children immediately.
- accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::remove):
(WebCore::AXObjectCache::childrenChanged):
(WebCore::AXObjectCache::prepareForDocumentDestruction):
(WebCore::AXObjectCache::performDeferredCacheUpdate):
- accessibility/AXObjectCache.h:
- accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::updateBackingStore):
- accessibility/mac/WebAccessibilityObjectWrapperBase.mm:
(convertToNSArray):
(-[WebAccessibilityObjectWrapperBase updateObjectBackingStore]):
LayoutTests:
- accessibility/aria-hidden-update.html:
- accessibility/aria-hidden-updates-alldescendants.html:
- accessibility/image-load-on-delay.html:
- accessibility/mac/aria-hidden-changes-for-non-ignored-elements.html:
- accessibility/removed-anonymous-block-child-causes-crash.html: