Timeline
Dec 25, 2019:
- 6:06 PM Changeset in webkit [253912] by
-
- 5 edits2 adds in trunk
Run with offset from the content box's logical left paint its tab stop at wrong position.
https://bugs.webkit.org/show_bug.cgi?id=205595
<rdar://problem/58194698>
Reviewed by Antti Koivisto.
Source/WebCore:
Test: fast/text/tab-stops-with-offset-from-parent.html
Use the run's left offset from the line as the xPos for the TextRun. Most cases the line has only one run
with 0 offset. This patch fixes the case when the additional runs (with offset != 0) paint their tab positions at the wrong place.
- layout/integration/LayoutIntegrationLineLayout.cpp:
(WebCore::LayoutIntegration::LineLayout::paint):
- rendering/SimpleLineLayoutFunctions.cpp:
(WebCore::SimpleLineLayout::paintFlow):
LayoutTests:
- fast/text/tab-stops-with-offset-from-parent-expected.html: Added.
- fast/text/tab-stops-with-offset-from-parent.html: Added.
- 10:26 AM Changeset in webkit [253911] by
-
- 2 edits in trunk/Source/WebCore
[LFC][Painting] Fix LayoutTests/imported/w3c/web-platform-tests/css/css-text/white-space/tab-stop-threshold-001.html
https://bugs.webkit.org/show_bug.cgi?id=205594
<rdar://problem/58194138>
Reviewed by Antti Koivisto.
Construct the TextRun with relative coordinates to get tab stops right.
- layout/displaytree/DisplayPainter.cpp:
(WebCore::Display::paintInlineContent):
- 9:50 AM Changeset in webkit [253910] by
-
- 7 edits in trunk/Tools
WKTR/DRT always trigger the Discrete GPU on dual GPU systems
https://bugs.webkit.org/show_bug.cgi?id=205546
<rdar://problem/58139610>
Reviewed by Alexey Proskuryakov.
Add an option "--prefer-integrated-gpu" to run-webkit-test
that causes the LayoutTestHelper to NOT lock the
machine to a discrete GPU on a dual-GPU system.
The default is false.
- DumpRenderTree/mac/LayoutTestHelper.m:
(main):
- Scripts/webkitpy/layout_tests/controllers/manager.py:
(Manager._set_up_run):
- Scripts/webkitpy/layout_tests/run_webkit_tests.py:
(parse_args):
- Scripts/webkitpy/port/base.py:
(Port.start_helper):
- Scripts/webkitpy/port/mac.py:
(MacPort.start_helper):
- Scripts/webkitpy/port/mock_drt.py:
(MockDRTPort.start_helper):
- 7:52 AM Changeset in webkit [253909] by
-
- 5 edits in trunk/Source/WebCore
[LFC][IFC] Forward scan for soft wrap opportunities
https://bugs.webkit.org/show_bug.cgi?id=205584
<rdar://problem/58188386>
Reviewed by Antti Koivisto.
This patch implements forward scanning to find wrap opportunities in inline content.
e.g <span></span>example<span><span></span> content</span>
When we reach "ex-" content, in order to figure out if it is at a wrap opportunity, we scan the content
forward until after we reach another inline content, in this case " " right before the "content" and
check if we can break the content between these 2 inline items.
isAtSoftWrapOpportunity: takes 2 (adjacent by skipping non-content inline items) and return true if there's
a soft wrap opportunity in between them.
LineBreaker::nextWrapOpportunity: returns the next wrap opportunity (either a soft wrap opportunity or a line break or the end of the content)
- layout/inlineformatting/InlineLineBreaker.cpp:
(WebCore::Layout::endsWithSoftWrapOpportunity):
(WebCore::Layout::isAtSoftWrapOpportunity):
(WebCore::Layout::LineBreaker::nextWrapOpportunity):
(WebCore::Layout::LineBreaker::ContinousContent::ContinousContent):
(WebCore::Layout::LineBreaker::lastSoftWrapOpportunity): Deleted.
- layout/inlineformatting/InlineLineBreaker.h:
- layout/inlineformatting/LineLayoutContext.cpp:
(WebCore::Layout::LineCandidateContent::isLineBreak const):
(WebCore::Layout::LineCandidateContent::append):
(WebCore::Layout::LineCandidateContent::setIsLineBreak):
(WebCore::Layout::LineLayoutContext::layoutLine):
(WebCore::Layout::LineLayoutContext::nextContentForLine):
(WebCore::Layout::ContinousContent::hasIntrusiveFloats const): Deleted.
(WebCore::Layout::ContinousContent::runs const): Deleted.
(WebCore::Layout::ContinousContent::floats const): Deleted.
(WebCore::Layout::ContinousContent::endsWithLineBreak const): Deleted.
(WebCore::Layout::ContinousContent::setEndsWithLineBreak): Deleted.
(WebCore::Layout::ContinousContent::append): Deleted.
(WebCore::Layout::LineLayoutContext::nextContinousContentForLine): Deleted.
- layout/inlineformatting/LineLayoutContext.h:
- 5:09 AM Changeset in webkit [253908] by
-
- 2 edits in trunk/Tools
REGRESSION (r253282): Tests that use applyAutocorrection assert in UIScriptContext::requestUIScriptCompletion
https://bugs.webkit.org/show_bug.cgi?id=205588
<rdar://problem/58109942>
Reviewed by Tim Horton.
The change made in r253282 intended to defer completing the async task prepared in
UIScriptController::applyAutocorrection until after the current runloop; however, it ended up keeping the
synchronous call to asyncTaskComplete. Fix this by removing this code, so that we instead wait for the
dispatch_async block to invoke asyncTaskComplete.
- WebKitTestRunner/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptControllerIOS::applyAutocorrection):
- 4:38 AM Changeset in webkit [253907] by
-
- 5 edits in trunk/Source/WebCore
[LFC][IFC] LineBreaker should tell whether the line should receive no more content
https://bugs.webkit.org/show_bug.cgi?id=205587
<rdar://problem/58188635>
Reviewed by Antti Koivisto.
LineBreaker returns IsEndOfLine::No when the current line should still be able to receive additional content.
This way we can start closing the line sooner (as opposed to start probing the subsequent content).
(Note that just because the current content overflows the line, it does not necessarily mean that the subsequent content
wraps to the next line.)
- layout/inlineformatting/InlineLineBreaker.cpp:
(WebCore::Layout::LineBreaker::breakingContextForInlineContent):
(WebCore::Layout::LineBreaker::ContinousContent::lastContentRunIndex const):
- layout/inlineformatting/InlineLineBreaker.h:
- layout/inlineformatting/LineLayoutContext.cpp:
(WebCore::Layout::LineLayoutContext::layoutLine):
(WebCore::Layout::LineLayoutContext::addFloatItems):
(WebCore::Layout::LineLayoutContext::placeInlineContentOnCurrentLine):
- layout/inlineformatting/LineLayoutContext.h:
- 4:22 AM Changeset in webkit [253906] by
-
- 5 edits in trunk/Source/WebCore
[LFC][IFC] Add support for zero-width-space character (U+200B)
https://bugs.webkit.org/show_bug.cgi?id=205586
<rdar://problem/58188505>
Reviewed by Antti Koivisto.
If a line has only U+200B characters, it is still considered empty from line breaking point of view.
(Note that U+200B is not considered a whitespace character so a run with U+200B does not collapse.)
- layout/inlineformatting/InlineLineBuilder.cpp:
(WebCore::Layout::LineBuilder::appendTextContent): empty runs don't collapse.
(WebCore::Layout::LineBuilder::isVisuallyNonEmpty const):
(WebCore::Layout::LineBuilder::InlineItemRun::hasEmptyTextContent const):
- layout/inlineformatting/InlineLineBuilder.h:
- layout/inlineformatting/InlineTextItem.cpp:
(WebCore::Layout::InlineTextItem::isEmptyContent const):
- layout/inlineformatting/InlineTextItem.h:
- 4:07 AM Changeset in webkit [253905] by
-
- 2 edits in trunk/Source/WebCore
[LFC][IFC] Fix LayoutTests/imported/w3c/web-platform-tests/css/css-text/letter-spacing/letter-spacing-control-chars-001.html
https://bugs.webkit.org/show_bug.cgi?id=205585
<rdar://problem/58188420>
Reviewed by Antti Koivisto.
TextUtil::fixedPitchWidth works on simple content only (letter-spacing forces slow font measuring path).
- layout/inlineformatting/text/TextUtil.cpp:
(WebCore::Layout::TextUtil::width):
- 1:07 AM Changeset in webkit [253904] by
-
- 9 edits in trunk/Source/JavaScriptCore
[JSC] Compact Bytecodes more by emitting 1-byte Opcode
https://bugs.webkit.org/show_bug.cgi?id=205553
Reviewed by Keith Miller.
When emitting 16bit / 32bit bytecodes, we also emit 16bit / 32bit Opcode.
So the layout is the following.
8bit 16bit 16bit 16bit
- [op_wide16][ Opcode ][ Operand0 ][ Operand1 ]
But this is unnecessary since Opcode must fit in 8bit. We should emit Opcode in 8bit in all cases.
8bit 8bit 16bit 16bit
- [op_wide16][Opcode][ Operand0 ][ Operand1 ]
- bytecode/Instruction.h:
(JSC::BaseInstruction::size const):
- bytecompiler/BytecodeGeneratorBaseInlines.h:
(JSC::BytecodeGeneratorBase<Traits>::alignWideOpcode16):
(JSC::BytecodeGeneratorBase<Traits>::alignWideOpcode32):
- generator/Argument.rb:
- generator/Opcode.rb:
- llint/LowLevelInterpreter.asm:
- llint/LowLevelInterpreter32_64.asm:
- llint/LowLevelInterpreter64.asm:
- llint/WebAssembly.asm:
Dec 24, 2019:
- 12:05 PM Changeset in webkit [253903] by
-
- 2 edits in trunk/Source/JavaScriptCore
Fix ARM64E by adding missing pointer tag.
- llint/LowLevelInterpreter.asm:
- 10:52 AM Changeset in webkit [253902] by
-
- 1 edit1 delete in trunk/LayoutTests
REGRESSION: [ Catalina wk1 ] imported/w3c/web-platform-tests/fetch/content-type/script.window.html is failing
https://bugs.webkit.org/show_bug.cgi?id=205313
Remove a no longer necessary and incorrect expectation.
- platform/mac-wk1/imported/w3c/web-platform-tests/fetch/content-type/script.window-expected.txt: Removed.
- 10:35 AM Changeset in webkit [253901] by
-
- 3 edits2 adds in trunk
[Web Animations] REGRESSION: Changing the animation-duration of a CSS Animation may not resume it
https://bugs.webkit.org/show_bug.cgi?id=205580
<rdar://problem/58127956>
Patch by Antoine Quint <Antoine Quint> on 2019-12-24
Reviewed by Dean Jackson.
Source/WebCore:
Test: webanimations/css-animation-dynamic-duration-change.html
Setting the animation-duration of an animation will transition the animation back into its idle state
and the "update animations and send events" procedure would remove that animation from the timeline.
It would also remove it from the map that would associate an animation with a given CSS Animation name
so that we would know whether an animation exists for a given animation name when one of the animation's
properties changed. Since that animation was (mistakenly) removed, we would fail to update its timing
and it would never be resumed. We now only update the CSS Animation name to animation map when styles
change.
- animation/AnimationTimeline.cpp:
(WebCore::AnimationTimeline::animationWasRemovedFromElement):
LayoutTests:
Add a new test that, by virtue of changing the animation-duration, transitions a CSS Animation from
idle, to running, back to idle and back to running. Prior to this change, the test would not perform
the final play state transition and the it would time out.
- webanimations/css-animation-dynamic-duration-change-expected.txt: Added.
- webanimations/css-animation-dynamic-duration-change.html: Added.
- 10:10 AM Changeset in webkit [253900] by
-
- 12 edits in trunk/Source
[Media in GPU process] Enable media player proxy logging
https://bugs.webkit.org/show_bug.cgi?id=205557
<rdar://problem/58160932>
Reviewed by Youenn Fablet.
Source/WebKit:
- GPUProcess/GPUConnectionToWebProcess.cpp:
(WebKit::GPUConnectionToWebProcess::create):
(WebKit::GPUConnectionToWebProcess::GPUConnectionToWebProcess):
(WebKit::GPUConnectionToWebProcess::logger):
- GPUProcess/GPUConnectionToWebProcess.h:
- GPUProcess/GPUProcess.cpp:
(WebKit::GPUProcess::createGPUConnectionToWebProcess):
- GPUProcess/GPUProcess.h:
- GPUProcess/GPUProcess.messages.in:
- GPUProcess/media/RemoteMediaPlayerManagerProxy.cpp:
(WebKit::RemoteMediaPlayerManagerProxy::logger const):
(WebKit::nullLogger): Deleted.
- Platform/Logging.h:
- UIProcess/GPU/GPUProcessProxy.cpp:
(WebKit::GPUProcessProxy::openGPUProcessConnection):
- WebProcess/GPU/media/MediaPlayerPrivateRemote.cpp:
(WebKit::MediaPlayerPrivateRemote::logChannel const):
Source/WTF:
- wtf/Logger.h:
(WTF::Logger::willLog const): Minor optimization: don't check m_enabled unnecessarily.
- 6:41 AM Changeset in webkit [253899] by
-
- 5 edits2 adds in trunk
Deny Notification API access for non secure contexts
https://bugs.webkit.org/show_bug.cgi?id=205496
<rdar://problem/58074660>
Reviewed by Chris Dumez.
Source/WebCore:
If document is not SecureContext, deny permission automatically.
This behavior is matching a planned update to the spec, as discussed in
https://github.com/whatwg/notifications/issues/93.
Chrome landed this restriction in M62. Mozilla is also on board with this restriction.
Test: http/tests/notifications/notification-in-non-secure-context.html
- Modules/notifications/Notification.cpp:
(WebCore::Notification::requestPermission):
Tools:
- TestWebKitAPI/Tests/WebKitCocoa/UIDelegate.mm:
(TEST):
LayoutTests:
- http/tests/notifications/notification-in-non-secure-context-expected.txt: Added.
- http/tests/notifications/notification-in-non-secure-context.html: Added.
- 6:19 AM Changeset in webkit [253898] by
-
- 32 edits9 adds in trunk
Service Worker doesn't terminate after a period of time when thread blocking
https://bugs.webkit.org/show_bug.cgi?id=202992
<rdar://problem/56298596>
Reviewed by Chris Dumez.
Source/WebCore:
Whenever running a service worker task, running script or posting events (install, activate, message and fetch),
start a timer to check that the service worker is not spinning.
This is done by posting a task to service worker thread and hopping back to the main thread.
If this post/hop is done before the heartbeat timer is fired, the service worker is considered live.
Otherwise, the check is failed and the task is considered as failing.
The service worker will be terminated.
Timeout is 60 seconds by default and 1 second for test purposes.
Add settings to have short heartbeat timeout for testing purposes.
Add internals API to check whether a service worker is running.
Tests: http/wpt/service-workers/service-worker-spinning-activate.https.html
http/wpt/service-workers/service-worker-spinning-fetch.https.html
http/wpt/service-workers/service-worker-spinning-install.https.html
http/wpt/service-workers/service-worker-spinning-message.https.html
- page/Settings.yaml:
- testing/Internals.cpp:
(WebCore::Internals::isServiceWorkerRunning):
- testing/Internals.h:
- testing/Internals.idl:
- workers/service/SWClientConnection.h:
(WebCore::SWClientConnection::isServiceWorkerRunning):
- workers/service/context/SWContextManager.h:
(WebCore::SWContextManager::Connection::isTestMode const):
(WebCore::SWContextManager::Connection::setIsTestMode):
- workers/service/context/ServiceWorkerThread.cpp:
(WebCore::ServiceWorkerThread::ServiceWorkerThread):
(WebCore::ServiceWorkerThread::postFetchTask):
(WebCore::ServiceWorkerThread::postMessageToServiceWorker):
(WebCore::ServiceWorkerThread::fireInstallEvent):
(WebCore::ServiceWorkerThread::finishedFiringInstallEvent):
(WebCore::ServiceWorkerThread::fireActivateEvent):
(WebCore::ServiceWorkerThread::finishedFiringActivateEvent):
(WebCore::ServiceWorkerThread::finishedEvaluatingScript):
(WebCore::ServiceWorkerThread::start):
(WebCore::ServiceWorkerThread::finishedStarting):
(WebCore::ServiceWorkerThread::startFetchEventMonitoring):
(WebCore::ServiceWorkerThread::startHeartBeatTimer):
(WebCore::ServiceWorkerThread::heartBeatTimerFired):
- workers/service/context/ServiceWorkerThread.h:
(WebCore::ServiceWorkerThread::stopFetchEventMonitoring):
- workers/service/context/ServiceWorkerThreadProxy.cpp:
(WebCore::ServiceWorkerThreadProxy::startFetch):
(WebCore::ServiceWorkerThreadProxy::cancelFetch):
(WebCore::ServiceWorkerThreadProxy::removeFetch):
- workers/service/server/SWServerToContextConnection.cpp:
(WebCore::SWServerToContextConnection::didFailHeartBeatCheck):
- workers/service/server/SWServerToContextConnection.h:
- workers/service/server/SWServerWorker.cpp:
(WebCore::SWServerWorker::didFailHeartBeatCheck):
- workers/service/server/SWServerWorker.h:
Source/WebKit:
Add a preference to enable/disable service worker short timeouts.
Add IPC handling for passing service worker heart beat failures and to get from WebProcess
whether a given service worker is running or not.
- NetworkProcess/ServiceWorker/WebSWServerConnection.cpp:
(WebKit::WebSWServerConnection::contextConnectionCreated):
(WebKit::WebSWServerConnection::syncTerminateWorkerFromClient):
(WebKit::WebSWServerConnection::isServiceWorkerRunning):
- NetworkProcess/ServiceWorker/WebSWServerConnection.h:
- NetworkProcess/ServiceWorker/WebSWServerConnection.messages.in:
- NetworkProcess/ServiceWorker/WebSWServerToContextConnection.messages.in:
- Shared/WebPreferences.yaml:
- UIProcess/API/C/WKPreferences.cpp:
(WKPreferencesGetServiceWorkerTestMode):
(WKPreferencesSetServiceWorkerTestMode):
- UIProcess/API/C/WKPreferencesRef.h:
- WebProcess/Storage/WebSWClientConnection.cpp:
(WebKit::WebSWClientConnection::isServiceWorkerRunning):
- WebProcess/Storage/WebSWClientConnection.h:
- WebProcess/Storage/WebSWContextManagerConnection.cpp:
(WebKit::WebSWContextManagerConnection::updatePreferencesStore):
(WebKit::WebSWContextManagerConnection::didFailHeartBeatCheck):
- WebProcess/Storage/WebSWContextManagerConnection.h:
Tools:
- WebKitTestRunner/TestController.cpp:
(WTR::TestController::resetPreferencesToConsistentValues):
Enable small timeout values.
LayoutTests:
- http/wpt/service-workers/resources/routines.js:
(async.waitForServiceWorkerNoLongerRunning):
- http/wpt/service-workers/service-worker-spinning-activate.https-expected.txt: Added.
- http/wpt/service-workers/service-worker-spinning-activate.https.html: Added.
- http/wpt/service-workers/service-worker-spinning-fetch.https-expected.txt: Added.
- http/wpt/service-workers/service-worker-spinning-fetch.https.html: Added.
- http/wpt/service-workers/service-worker-spinning-install.https-expected.txt: Added.
- http/wpt/service-workers/service-worker-spinning-install.https.html: Added.
- http/wpt/service-workers/service-worker-spinning-message.https-expected.txt: Added.
- http/wpt/service-workers/service-worker-spinning-message.https.html: Added.
- http/wpt/service-workers/service-worker-spinning-worker.js: Added.