⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Jul 6, 2019:

7:09 PM Changeset in webkit [247196] by Nikita Vasilyev
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Styles: unbalanced quotes and parenthesis aren't displayed as property closed after editing values
https://bugs.webkit.org/show_bug.cgi?id=199090
<rdar://problem/51965431>

Reviewed by Devin Rousso.

} gets added by WI.tokenizeCSSValue (called by SpreadsheetStyleProperty.prototype._renderValue)
when it encounters unbalanced quotes. Fix unbalanced quotes by re-rendering the value from the model,
not the DOM content.

  • UserInterface/Views/SpreadsheetStyleProperty.js:

(WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidCommit):
For consistency, render property name from the model as well.

5:20 PM Changeset in webkit [247195] by Simon Fraser
  • 5 edits in trunk

Long hang when loading a cnn.com page on iOS
https://bugs.webkit.org/show_bug.cgi?id=199556

Reviewed by Zalan Bujtas.
Source/WebCore:

Loading https://edition.cnn.com/travel/article/brussels-airlines-flight-to-nowhere/index.html in the iOS 13 sim
results in a long hang under OverlapMapContainer::append(). We were creating pathological clipping scopes with
thousands of entries, because OverlapMapContainer::mergeClippingScopesRecursive() had a logic error where
it added 'sourceScope' to the child instead of 'sourceChildScope'. Add a new assertion to detect that case.

I wasn't able to create a testcase that caused a hang, but a number of existing tests would have
hit the assertion.

  • rendering/LayerOverlapMap.cpp:

(WebCore::OverlapMapContainer::ClippingScope::addChild):
(WebCore::OverlapMapContainer::mergeClippingScopesRecursive):

  • rendering/RenderLayerCompositor.cpp:

(WebCore::RenderLayerCompositor::flushPendingLayerChanges): Drive-by fix: m_overflowControlsHostLayer is null on iOS, so use rootGraphicsLayer().

Tools:

Add code to load a page by default in MobileMiniBrowser so it's easy to hack it
to load a test page of your choice.

  • MobileMiniBrowser/MobileMiniBrowserFramework/WebViewController.m:

(-[WebViewController viewDidLoad]):

6:34 AM Changeset in webkit [247194] by msaboff@apple.com
  • 5 edits
    1 add in trunk

switch(String) needs to check for exceptions when resolving the string
https://bugs.webkit.org/show_bug.cgi?id=199541

Reviewed by Mark Lam.

JSTests:

New tests.

  • stress/switch-string-oom.js: Added.

(test):
(testLowerTiers):
(testFTL):

Source/JavaScriptCore:

Added exception checks for resolved Strings in switch processing for all tiers.

  • dfg/DFGOperations.cpp:
  • jit/JITOperations.cpp:
  • llint/LLIntSlowPaths.cpp:

(JSC::LLInt::LLINT_SLOW_PATH_DECL):

4:03 AM Changeset in webkit [247193] by commit-queue@webkit.org
  • 78 edits
    64 adds in trunk/LayoutTests

Import css/cssom-view testcases from WPT.
https://bugs.webkit.org/show_bug.cgi?id=199509

Patch by Cathie Chen <cathiechen> on 2019-07-06
Reviewed by Frédéric Wang.

LayoutTests/imported/w3c:

  • resources/import-expectations.json:
  • web-platform-tests/css/cssom-view/CaretPosition-001.html:
  • web-platform-tests/css/cssom-view/DOMRectList.html:
  • web-platform-tests/css/cssom-view/GetBoundingRect.html:
  • web-platform-tests/css/cssom-view/HTMLBody-ScrollArea_quirksmode.html:
  • web-platform-tests/css/cssom-view/MediaQueryList-001.html:
  • web-platform-tests/css/cssom-view/MediaQueryList-with-empty-string.html:
  • web-platform-tests/css/cssom-view/Screen-pixelDepth-Screen-colorDepth001.html:
  • web-platform-tests/css/cssom-view/cssom-getBoundingClientRect-001.html:
  • web-platform-tests/css/cssom-view/cssom-getBoundingClientRect-002.html:
  • web-platform-tests/css/cssom-view/cssom-getBoxQuads-001.html:
  • web-platform-tests/css/cssom-view/cssom-getClientRects-002.html:
  • web-platform-tests/css/cssom-view/cssom-getClientRects.html:
  • web-platform-tests/css/cssom-view/cssom-view-img-attributes-001.html:
  • web-platform-tests/css/cssom-view/cssom-view-window-screen-interface.html:
  • web-platform-tests/css/cssom-view/dom-element-scroll.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-001.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-002.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-003.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-dynamic-anon-box.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-mixed-font-sizes.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-parameters.html:
  • web-platform-tests/css/cssom-view/elementFromPoint-subpixel-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementFromPoint-subpixel.html: Added.
  • web-platform-tests/css/cssom-view/elementFromPoint.html:
  • web-platform-tests/css/cssom-view/elementFromPosition.html:
  • web-platform-tests/css/cssom-view/elementScroll-002.html:
  • web-platform-tests/css/cssom-view/elementScroll.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-iframes.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-htb-ltr-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-htb-ltr.html: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-htb-rtl-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-htb-rtl.html: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vlr-ltr-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vlr-ltr.html: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vlr-rtl-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vlr-rtl.html: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vrl-ltr-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vrl-ltr.html: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vrl-rtl-expected.txt: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-inline-vrl-rtl.html: Added.
  • web-platform-tests/css/cssom-view/elementsFromPoint-invalid-cases.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-shadowroot.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-simple.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-svg-text.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-svg.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint-table.html:
  • web-platform-tests/css/cssom-view/elementsFromPoint.html:
  • web-platform-tests/css/cssom-view/getClientRects-br-htb-ltr-expected.txt: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-htb-ltr.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-htb-rtl-expected.txt: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-htb-rtl.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vlr-ltr-expected.txt: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vlr-ltr.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vlr-rtl-expected.txt: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vlr-rtl.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vrl-ltr-expected.txt: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vrl-ltr.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vrl-rtl-expected.txt: Added.
  • web-platform-tests/css/cssom-view/getClientRects-br-vrl-rtl.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-inline-expected.html: Added.
  • web-platform-tests/css/cssom-view/getClientRects-inline.html: Added.
  • web-platform-tests/css/cssom-view/historical.html:
  • web-platform-tests/css/cssom-view/htmlelement-offset-width-001.html:
  • web-platform-tests/css/cssom-view/inheritance-expected.txt: Added.
  • web-platform-tests/css/cssom-view/inheritance.html: Added.
  • web-platform-tests/css/cssom-view/interfaces.html:
  • web-platform-tests/css/cssom-view/long_scroll_composited-expected.html: Added.
  • web-platform-tests/css/cssom-view/long_scroll_composited.html: Added.
  • web-platform-tests/css/cssom-view/matchMedia-display-none-iframe-expected.txt: Added.
  • web-platform-tests/css/cssom-view/matchMedia-display-none-iframe.html: Added.
  • web-platform-tests/css/cssom-view/matchMedia.xht:
  • web-platform-tests/css/cssom-view/matchMediaAddListener.html:
  • web-platform-tests/css/cssom-view/mouseEvent.html:
  • web-platform-tests/css/cssom-view/negativeMargins.html:
  • web-platform-tests/css/cssom-view/offsetParent_element_test.html:
  • web-platform-tests/css/cssom-view/offsetTopLeft-empty-inline-expected.txt: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-empty-inline-offset-expected.txt: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-empty-inline-offset.html: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-empty-inline.html: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-inline-expected.html: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-inline.html: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-leading-space-inline-expected.txt: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-leading-space-inline.html: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-trailing-space-inline-expected.txt: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeft-trailing-space-inline.html: Added.
  • web-platform-tests/css/cssom-view/offsetTopLeftInScrollableParent.html:
  • web-platform-tests/css/cssom-view/outer-svg-expected.txt: Added.
  • web-platform-tests/css/cssom-view/outer-svg.html: Added.
  • web-platform-tests/css/cssom-view/resize-event-on-initial-layout-expected.txt: Added.
  • web-platform-tests/css/cssom-view/resize-event-on-initial-layout.html: Added.
  • web-platform-tests/css/cssom-view/screenLeftTop-expected.txt: Added.
  • web-platform-tests/css/cssom-view/screenLeftTop.html: Added.
  • web-platform-tests/css/cssom-view/scroll-behavior-default-css.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-element.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-main-frame-root.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-main-frame-window.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-scrollintoview-nested.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-smooth-positions.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-smooth.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-subframe-root.html:
  • web-platform-tests/css/cssom-view/scroll-behavior-subframe-window.html:
  • web-platform-tests/css/cssom-view/scroll-no-layout-box.html:
  • web-platform-tests/css/cssom-view/scrollIntoView-horizontal-tb-writing-mode-and-rtl-direction-expected.txt: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-horizontal-tb-writing-mode-and-rtl-direction.html: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-horizontal-tb-writing-mode-expected.txt: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-horizontal-tb-writing-mode.html: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-scrollMargin.html:
  • web-platform-tests/css/cssom-view/scrollIntoView-scrollPadding.html:
  • web-platform-tests/css/cssom-view/scrollIntoView-shadow.html:
  • web-platform-tests/css/cssom-view/scrollIntoView-smooth.html:
  • web-platform-tests/css/cssom-view/scrollIntoView-svg-shape-expected.txt: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-svg-shape.html: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-vertical-lr-writing-mode-and-rtl-direction-expected.txt: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-vertical-lr-writing-mode-and-rtl-direction.html: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-vertical-lr-writing-mode-expected.txt: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-vertical-lr-writing-mode.html: Added.
  • web-platform-tests/css/cssom-view/scrollIntoView-vertical-rl-writing-mode-expected.txt:
  • web-platform-tests/css/cssom-view/scrollIntoView-vertical-rl-writing-mode.html:
  • web-platform-tests/css/cssom-view/scrollWidthHeight.xht:
  • web-platform-tests/css/cssom-view/scrollWidthHeightWhenNotScrollable.xht:
  • web-platform-tests/css/cssom-view/scrolling-no-browsing-context.html:
  • web-platform-tests/css/cssom-view/scrolling-quirks-vs-nonquirks.html:
  • web-platform-tests/css/cssom-view/scrollingElement.html:
  • web-platform-tests/css/cssom-view/scrollintoview.html:
  • web-platform-tests/css/cssom-view/table-client-props.html:
  • web-platform-tests/css/cssom-view/table-offset-props.html:
  • web-platform-tests/css/cssom-view/table-scroll-props.html:
  • web-platform-tests/css/cssom-view/ttwf-js-cssomview-getclientrects-length.html:
  • web-platform-tests/css/cssom-view/w3c-import.log:
  • web-platform-tests/css/cssom-view/window-screen-height-immutable.html:
  • web-platform-tests/css/cssom-view/window-screen-height.html:
  • web-platform-tests/css/cssom-view/window-screen-width-immutable.html:
  • web-platform-tests/css/cssom-view/window-screen-width.html:

LayoutTests:

  • TestExpectations:
  • platform/ios-simulator-wk2/imported/w3c/web-platform-tests/css/cssom-view/offsetTopLeft-empty-inline-expected.txt: Added.
  • platform/ios-simulator-wk2/imported/w3c/web-platform-tests/css/cssom-view/offsetTopLeft-leading-space-inline-expected.txt: Added.
  • platform/ios-simulator-wk2/imported/w3c/web-platform-tests/css/cssom-view/scrollIntoView-horizontal-tb-writing-mode-and-rtl-direction-expected.txt: Added.
  • tests-options.json:
1:14 AM Changeset in webkit [247192] by Chris Fleizach
  • 4 edits in trunk/Source/WebKit

AX: CrashTracer: com.apple.WebKit.WebContent at WebKit: WebKit::WebSpeechSynthesisClient::speak
https://bugs.webkit.org/show_bug.cgi?id=199435

Reviewed by Ryosuke Niwa.

Ensure we don't access null observers in speech callbacks.

  • WebProcess/WebCoreSupport/WebSpeechSynthesisClient.cpp:

(WebKit::WebSpeechSynthesisClient::voiceList):
(WebKit::WebSpeechSynthesisClient::speak):
(WebKit::WebSpeechSynthesisClient::pause):
(WebKit::WebSpeechSynthesisClient::resume):

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::speakingErrorOccurred):
(WebKit::WebPage::boundaryEventOccurred):
(WebKit::WebPage::voicesDidChange):

Jul 5, 2019:

10:37 PM Changeset in webkit [247191] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

Carvana.com needs the fetch AbortSignal quirk
https://bugs.webkit.org/show_bug.cgi?id=199540

Reviewed by Chris Dumez.

Manually tested.

  • page/Quirks.cpp:

(WebCore::Quirks::shouldIgnoreInvalidSignal const):

5:33 PM Changeset in webkit [247190] by Chris Dumez
  • 2 edits in trunk/Source/WebKit

Fix thread safety bug in WebResourceLoadStatisticsTelemetry::calculateAndSubmit()
https://bugs.webkit.org/show_bug.cgi?id=199536

Reviewed by Youenn Fablet.

The resourceLoadStatisticsStore is an object that is created / used / destroyed on the background
queue. It is therefore not safe to create a WeakPtr for it and use that WeakPtr on the main thread.

  • NetworkProcess/Classifier/WebResourceLoadStatisticsTelemetry.cpp:

(WebKit::WebResourceLoadStatisticsTelemetry::calculateAndSubmit):

5:33 PM Changeset in webkit [247189] by rmorisset@apple.com
  • 2 edits in trunk/Source/WebCore

[WHLSL] The checker does not need to keep a separate m_typeAnnotations map
https://bugs.webkit.org/show_bug.cgi?id=199537

Reviewed by Myles C. Maxfield.

Nothing is ever deleted from it, and all of its contents are eventually copied into the expressions.
We might as well put the type annotations directly into the expressions in the first place.
It is about a 5% speedup of the checker.

No new test as there is no inteded functional change.

  • Modules/webgpu/WHLSL/WHLSLChecker.cpp:

(WebCore::WHLSL::Checker::assignTypes):
(WebCore::WHLSL::Checker::getInfo):
(WebCore::WHLSL::Checker::assignType):
(WebCore::WHLSL::Checker::forwardType):
(WebCore::WHLSL::Checker::visit):

4:46 PM Changeset in webkit [247188] by Michael Catanzaro
  • 2 edits in trunk/Source/WebKit

Unreviewed, fix -Wswitch warning

We don't support HTTPCookieAcceptPolicy::ExclusivelyFromMainDocumentDomain.

Fun fact, soup's OnlyFromMainDocumentDomain functions the same as Apple's
ExclusivelyFromMainDocumentDomain. These should be renamed....

  • NetworkProcess/Cookies/soup/WebCookieManagerSoup.cpp:

(WebKit::WebCookieManager::platformSetHTTPCookieAcceptPolicy):

4:36 PM Changeset in webkit [247187] by Simon Fraser
  • 3 edits
    2 adds in trunk

Trigger a compositing update when video element is changing
https://bugs.webkit.org/show_bug.cgi?id=199522
<rdar://problem/47297159>

Reviewed by Simon Fraser.

Source/WebCore:

Test: compositing/video/video-update-rendering.html

  • rendering/RenderLayerBacking.cpp:

(WebCore::RenderLayerBacking::contentChanged):

LayoutTests:

  • compositing/video/video-update-rendering-expected.txt: Added.
  • compositing/video/video-update-rendering.html: Added.
4:35 PM Changeset in webkit [247186] by Michael Catanzaro
  • 2 edits in trunk/Source/WebCore

Unreviewed, fix -Wmisleading-indentation warning introduced in r246764
https://bugs.webkit.org/show_bug.cgi?id=199173
<rdar://problem/45968770>

  • contentextensions/ContentExtensionsBackend.cpp:

(WebCore::ContentExtensions::ContentExtensionsBackend::processContentRuleListsForLoad):

4:34 PM Changeset in webkit [247185] by dino@apple.com
  • 2 edits in trunk/Source/WebKit

[iOS] Context Menu - Add to Reading List does nothing
https://bugs.webkit.org/show_bug.cgi?id=199504
<rdar://problem/52554137>

Reviewed by Anders Carlsson.

We were holding weak references to the _WKElementAction in
the handler provided to UIAction. By the time the handler was
called, the object had been deallocated.

  • UIProcess/API/Cocoa/_WKElementAction.mm:

(-[_WKElementAction uiActionForElementInfo:]): Use strong references in handler.

4:19 PM Changeset in webkit [247184] by timothy@apple.com
  • 6 edits in trunk/Source/WebCore

Mail's use of punchOutWhiteBackgroundsInDarkMode not working on iOS.
https://bugs.webkit.org/show_bug.cgi?id=199534
rdar://problem/52586836

Reviewed by Simon Fraser.

Tests: css3/color-filters/punch-out-white-backgrounds.html

  • dom/Document.cpp:

(WebCore::Document::compositeOperatorForBackgroundColor const): Added.
Use CompositeDestinationOut for transparent frames, otherwise CompositeDestinationIn.

  • dom/Document.h:
  • rendering/InlineFlowBox.cpp:

(WebCore::InlineFlowBox::paintBoxDecorations): Use compositeOperatorForBackgroundColor.

  • rendering/RenderBox.cpp:

(WebCore::RenderBox::paintRootBoxFillLayers): Ditto.
(WebCore::RenderBox::paintBackground): Ditto.

  • rendering/RenderTableCell.cpp:

(WebCore::RenderTableCell::paintBackgroundsBehindCell): Ditto.

4:05 PM Changeset in webkit [247183] by mark.lam@apple.com
  • 3 edits
    1 add in trunk

ArgumentsEliminationPhase::eliminateCandidatesThatInterfere() should not decrement nodeIndex pass zero.
https://bugs.webkit.org/show_bug.cgi?id=199533
<rdar://problem/52669111>

Reviewed by Filip Pizlo.

JSTests:

  • stress/ArgumentsEliminationPhase-eliminateCandidatesThatEscape-should-not-decrement-nodeIndex-pass-zero.js: Added.

Source/JavaScriptCore:

  • dfg/DFGArgumentsEliminationPhase.cpp:
3:24 PM Changeset in webkit [247182] by jer.noble@apple.com
  • 2 edits in trunk/Source/WebCore

Revert change to block playback when process is ostensibly "suspended".
https://bugs.webkit.org/show_bug.cgi?id=199530

Reviewed by Eric Carlson.

In r243958, a drive-by-fix was added that blocked playback when the WebProcess thought it
was susposed to be suspended. The intent was to keep the AVAudioSession for the process
from being activated just before the process was suspended, and thus avoid receiving an
"interruption" and having the AVAudioSession deactivated out from under us upon resuming.

Unfortunately, this caused problems when another process resumes the WebContent process
in order to start playback; namely the Now Playing UI's play button. Because we may receive
the play command long before whe notice that we've been resumed, the WebContent process
may refuse to honor the play command because it thinks its supposed to be suspended.

  • platform/audio/PlatformMediaSessionManager.cpp:

(WebCore::PlatformMediaSessionManager::sessionWillBeginPlayback):

3:13 PM Changeset in webkit [247181] by bshafiei@apple.com
  • 3 edits
    2 adds in tags/Safari-608.1.34

Cherry-pick r247167. rdar://problem/52547473

[ContentChangeObserver] REGRESSION (r247015): facebook photo/video upload button is unresponsive to user interaction.
https://bugs.webkit.org/show_bug.cgi?id=199502
<rdar://problem/52547473>

Reviewed by Simon Fraser.

Source/WebKit:

Apparently it's a common practice to put transparent elements over visible click targets (button like divs) and use the invisible
elements to catch the user input (e.g. Facebook's Photo/Video button).
This patch modifies the original "do not trigger click on invisible targets" heuristic to a more restrictive "do not trigger
click if the click target was previously hidden and became visible through touch start".
If this still breaks some use cases, we could turn it into YouTube quirk.

  • WebProcess/WebPage/ios/WebPageIOS.mm: (WebKit::WebPage::handleSyntheticClick):

LayoutTests:

  • fast/events/touch/ios/content-observation/opacity-change-happens-on-touchstart-with-transition3-expected.txt: Added.
  • fast/events/touch/ios/content-observation/opacity-change-happens-on-touchstart-with-transition3.html: Added.

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

2:56 PM Changeset in webkit [247180] by rniwa@webkit.org
  • 14 edits
    2 adds in trunk

[iOS] Crash in WebKit::WebPage::positionInformation via Range::startPosition
https://bugs.webkit.org/show_bug.cgi?id=199503

Reviewed by Wenson Hsieh.

Source/WebCore:

  • editing/Editor.cpp:

(WebCore::Editor::compositionRange const): Added a FIXME.

Source/WebKit:

The crash was caused because focusedElementPositionInformation asssumes Editor::compositionRange is not null
whenever Editor::hasComposition returns true, which is not necessary the case when Editor::m_compositionNode
contains no text (data is of length 0).

Fixed the crash by adding an early return for when Editor::compositionRange returns nullptr.

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::focusedElementPositionInformation):

Tools:

Added UIScriptController.ensurePositionInformationIsUpToDateAt using the existing WKWebView SPI:
_requestActivatedElementAtPosition

  • DumpRenderTree/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptController::ensurePositionInformationIsUpToDateAt):

  • DumpRenderTree/mac/UIScriptControllerMac.mm:

(WTR::UIScriptController::ensurePositionInformationIsUpToDateAt):

  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
  • TestRunnerShared/UIScriptContext/UIScriptController.cpp:

(WTR::UIScriptController::ensurePositionInformationIsUpToDateAt):

  • TestRunnerShared/UIScriptContext/UIScriptController.h:
  • WebKitTestRunner/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptController::ensurePositionInformationIsUpToDateAt):

  • WebKitTestRunner/ios/UIScriptControllerMac.mm:

(WTR::UIScriptController::ensurePositionInformationIsUpToDateAt):

LayoutTests:

Added a regression test for the crash.

  • editing/input/delete-text-in-composition-expected.txt: Added.
  • editing/input/delete-text-in-composition.html: Added.
  • resources/ui-helper.js:

(window.UIHelper.ensurePositionInformationUpdateForElement): Added.

2:48 PM Changeset in webkit [247179] by Devin Rousso
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: current call frame indicator not visible in dark mode
https://bugs.webkit.org/show_bug.cgi?id=199047
<rdar://problem/51922895>

Reviewed by Timothy Hatcher.

  • UserInterface/Views/CallFrameTreeElement.css:

(.tree-outline .item.call-frame .status > .status-image):
(.tree-outline .item.call-frame.selected .status > .status-image):
Replace the CSS variables used for fill with their actual color value (in light mode),
as the semantic "name" of the variable doesn't really match its usage. As an example, the
current call frame shouldn't rely on the value of --border-color, as it's not a "border".

2:47 PM Changeset in webkit [247178] by bshafiei@apple.com
  • 8 edits in tags/Safari-608.1.33.2/Source

Cherry-pick r247095. rdar://problem/52695729

Unreviewed, rolling out r246616.

Caused http/tests/inspector/network/har/har-page.html to fail
on Catalina.

Reverted changeset:

"Web Inspector: Network: replace CFNetwork SPI with new API
where able"
https://bugs.webkit.org/show_bug.cgi?id=198762
https://trac.webkit.org/changeset/246616

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

2:45 PM Changeset in webkit [247177] by bshafiei@apple.com
  • 7 edits in tags/Safari-608.1.33.2/Source

Versioning.

2:42 PM Changeset in webkit [247176] by bshafiei@apple.com
  • 1 copy in tags/Safari-608.1.33.2

Tag Safari-608.1.33.2.

2:30 PM Changeset in webkit [247175] by ysuzuki@apple.com
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, fix build failure on ARM64_32
https://bugs.webkit.org/show_bug.cgi?id=182434

Implicit narrowing from uint64_t to uint32_t happens. We should explicitly narrow it because we already checked
the length is <= UINT32_MAX.

  • runtime/ArrayPrototype.cpp:

(JSC::arrayProtoFuncSpeciesCreate):

2:14 PM Changeset in webkit [247174] by mmaxfield@apple.com
  • 21 edits
    3 copies
    3 adds in trunk

[WHLSL] Standard library is too big to directly include in WebCore
https://bugs.webkit.org/show_bug.cgi?id=198186
<rdar://problem/51288898>

Reviewed by Saam Barati.

Source/WebCore:

This patch adds almost the entire remainder of the standard library. There are a few
pieces missing:

There were two problems with adding so many standard library functions:

  • We didn't want to increase the WebCore binary size that much
  • Compiling all the functions at runtime took 7 seconds, which is much too long

This patch addresses the first problem by gzipping the standard library before including it in the binary.
At runtime, we use libcompression to unzip it.

To address the second problem, we did some analysis and found that 14% of that 7 seconds was simply
destroying all the AST nodes. Even if we eliminated all processing of the AST, simply having the AST
of the entire standard library built and destroyed would still be too slow. Therefore, this patch limits
which parts of the standard library get parsed in the first place. All the functions in the standard library
file are sorted by name, and each group of functions with the same name are preceeded by a comment of the
form /* Functions named xyz */. At build time, a Python script looks for all these comments, and builds a
map from function name to character offset inside the file where those functions begin. At run time, we
parse the user program first, look for all function calls within it, and look up those function call names
in the map to see which part of the standard library holds those functions. We then parse just that part.
Because the standard library can call other functions in the standard library, we do this in a loop until
we have exhausted all the functions.

Covered by existing tests.

  • DerivedSources-input.xcfilelist:
  • DerivedSources-output.xcfilelist:
  • DerivedSources.make: gzip the standard library, and add a build step to generate the offset map.
  • Modules/webgpu/WHLSL/AST/WHLSLCallExpression.h:

(WebCore::WHLSL::AST::CallExpression::setOverloads):
(WebCore::WHLSL::AST::CallExpression::function): Every caller of this ASSERT()s the result. Might as well
move the ASSERT() into the function.
(WebCore::WHLSL::AST::CallExpression::setFunction):

  • Modules/webgpu/WHLSL/Cocoa/WHLSLStandardLibraryUtilities.cpp: Added.

(WebCore::WHLSL::decompressStandardLibrary): Use libcompression. This is why this file is in a Cocoa/
subfolder, and is listed in SourcesCocoa.txt instead of Sources.txt.
(WebCore::WHLSL::decompressAndDecodeStandardLibrary):
(WebCore::WHLSL::NameFinder::takeFunctionNames):
(WebCore::WHLSL::includeStandardLibrary): Include only the bits of the standard library which are relevant,
as described above.

  • Modules/webgpu/WHLSL/Metal/WHLSLFunctionWriter.cpp: Only emit MSL code for functions which are actually

reached. The MSL compiler is a significant amount of our compile time, so reducing the size of the emitted
program can significantly improve compile times.
(WebCore::WHLSL::Metal::FunctionDefinitionWriter::visit):
(WebCore::WHLSL::Metal::sharedMetalFunctions):
(WebCore::WHLSL::Metal::metalFunctions):

  • Modules/webgpu/WHLSL/Metal/WHLSLNativeFunctionWriter.cpp:

(WebCore::WHLSL::Metal::writeNativeFunction):

  • Change how load() and store() are written. We need explicit functions because we have explicit atomic types, which HLSL doesn't have. load() and store() aren't present in HLSL.
  • Delete f16tof32 because they're probably not important and are not obvious how to implement. We can re-add them again later if necessary.
  • Various fixes to make us generate the correct MSL code for each standard library function.
  • Modules/webgpu/WHLSL/WHLSLBuildStandardLibraryFunctionMap.py: Added. Build the function map as described

above.

  • Modules/webgpu/WHLSL/WHLSLChecker.cpp:

(WebCore::WHLSL::resolveByInstantiation): Previously, the standard library included an operator== for two
pointers. However, that function should be generated by the compiler instead. This fixes the bug in the
compiler which allows the compiler to correctly generate the right function. This also prompted me to file
https://bugs.webkit.org/show_bug.cgi?id=199335
(WebCore::WHLSL::checkOperatorOverload):
(WebCore::WHLSL::Checker::visit):

  • Modules/webgpu/WHLSL/WHLSLFunctionStageChecker.cpp: Update to the new function() signature.
  • Modules/webgpu/WHLSL/WHLSLLexer.h: Add a new position() method to the lexer. This isn't actually used

in this patch, but it's useful when doing some analysis during parsing.
(WebCore::WHLSL::Lexer::Lexer):
(WebCore::WHLSL::Lexer::consumeToken):
(WebCore::WHLSL::Lexer::peek const):
(WebCore::WHLSL::Lexer::peekFurther const):
(WebCore::WHLSL::Lexer::position const):
(WebCore::WHLSL::Lexer::state const):
(WebCore::WHLSL::Lexer::setState):
(WebCore::WHLSL::Lexer::isFullyConsumed const): Fixes a bug where isFullyConsumed() might return true even
when there is a token in the ring buffer.
(WebCore::WHLSL::Lexer::peek): Deleted.
(WebCore::WHLSL::Lexer::peekFurther): Deleted.

  • Modules/webgpu/WHLSL/WHLSLNameResolver.cpp:

(WebCore::WHLSL::NameResolver::visit): Drive-by partial fix of https://bugs.webkit.org/show_bug.cgi?id=199347

  • Modules/webgpu/WHLSL/WHLSLPrepare.cpp: Call includeStandardLibrary().

(WebCore::WHLSL::prepareShared):

  • Modules/webgpu/WHLSL/WHLSLPreserveVariableLifetimes.cpp:
  • Modules/webgpu/WHLSL/WHLSLRecursionChecker.cpp:
  • Modules/webgpu/WHLSL/WHLSLStandardLibrary.txt:
  • Modules/webgpu/WHLSL/WHLSLStandardLibraryFunctionMap.h: Copied from Source/WebCore/Modules/webgpu/WHLSL/WHLSLRecursionChecker.cpp.
  • Modules/webgpu/WHLSL/WHLSLStandardLibraryUtilities.h: Copied from Source/WebCore/Modules/webgpu/WHLSL/WHLSLRecursionChecker.cpp.
  • SourcesCocoa.txt:
  • WebCore.xcodeproj/project.pbxproj:

LayoutTests:

The standard library doesn't include any matrix constructors that broadcast a single value
to every field in a matrix. https://bugs.webkit.org/show_bug.cgi?id=199333

  • webgpu/whlsl-matrix.html:
1:26 PM Changeset in webkit [247173] by commit-queue@webkit.org
  • 13 edits in trunk

[JSC] Clean up ArraySpeciesCreate
https://bugs.webkit.org/show_bug.cgi?id=182434

Patch by Alexey Shvayka <Alexey Shvayka> on 2019-07-05
Reviewed by Yusuke Suzuki.

JSTests:

Adjusts error message expectations in stress tests.

  • stress/array-flatmap.js:
  • stress/array-flatten.js:
  • stress/array-species-create-should-handle-masquerader.js:
  • test262/expectations.yaml: Mark 4 test cases as passing.

Source/JavaScriptCore:

We have duplicate code in arraySpeciesCreate, filter, map, concatSlowPath of ArrayPrototype.js
and speciesConstructArray of ArrayPrototype.cpp. This patch fixes cross-realm Array constructor
detection in native speciesConstructArray, upgrades length type to correctly handle large integers,
and exposes it as @arraySpeciesCreate. Also removes now unused @isArrayConstructor private function.
Native speciesConstructArray is preferred because it has fast path via speciesWatchpointIsValid.

Thoroughly benchmarked: this change progresses ARES-6 by 0-1%.

  • builtins/ArrayPrototype.js:

(filter):
(map):
(globalPrivate.concatSlowPath):
(globalPrivate.arraySpeciesCreate): Deleted.

  • builtins/BuiltinNames.h:
  • runtime/ArrayConstructor.cpp:

(JSC::arrayConstructorPrivateFuncIsArrayConstructor): Deleted.

  • runtime/ArrayConstructor.h:
  • runtime/ArrayPrototype.cpp:

(JSC::arrayProtoFuncSpeciesCreate):

  • runtime/ArrayPrototype.h:
  • runtime/JSGlobalObject.cpp:

(JSC::JSGlobalObject::init):

1:13 PM Changeset in webkit [247172] by youenn@apple.com
  • 2 edits in trunk/Source/WebCore

Add fetch quirk for www.bnz.co.nz
https://bugs.webkit.org/show_bug.cgi?id=199518
rdar://problem/52230914

Reviewed by Chris Dumez.

Use fetch quirk to make bnz main page load properly.
Manually tested.

  • page/Quirks.cpp:

(WebCore::Quirks::shouldIgnoreInvalidSignal const):

1:10 PM Changeset in webkit [247171] by rmorisset@apple.com
  • 7 edits in trunk/Source/WebCore

[WHLSL] Optimize the lexer
https://bugs.webkit.org/show_bug.cgi?id=199520

Reviewed by Myles Maxfield.

This patch includes a number of small optimizations to the lexer:

  • By creating two new types of Token (Invalid and EOF), we can avoid having to manipulate Optional<Token> everywhere
  • By combining the lexing of identifiers, keywords and operator names, we can avoid re-reading them several times
  • By storing mere offsets in the tokens instead of string views, we save space in the common case where the string view is unused (e.g. for keywords)
  • By storing mere offsets in the tokens instead of line numbers, we can simplify the whitespace and comment lexing; and we can easily recompute the line number on demand
  • By using templates we can avoid constructing and destructing vectors at runtime every time we call tryTypes, consumeTypes or peekTypes; as well as avoiding a call to find().
  • I also hoisted the length check out of the loop in Lexer::string()

All of this combined brought the time spent in the parser when running LayoutTests/webgpu/whlsl-test-harness-test.html 5 times on my machine from 612ms to 462ms.

I also removed the 'anyCharacter' method since it was dead code.
I also removed Lexer::position(), but it is directly equivalent now to peek().startOffset.

No new tests as there is no intended functional change.

  • Modules/webgpu/WHLSL/WHLSLLexer.cpp:

(WebCore::WHLSL::Lexer::Token::typeName):
(WebCore::WHLSL::Lexer::consumeTokenFromStream):
(WebCore::WHLSL::Lexer::lineNumberFromOffset):
(WebCore::WHLSL::isWhitespace):
(WebCore::WHLSL::isNewline):
(WebCore::WHLSL::Lexer::skipWhitespaceAndComments):
(WebCore::WHLSL::Lexer::digitStar const):
(WebCore::WHLSL::Lexer::completeOperatorName const):

  • Modules/webgpu/WHLSL/WHLSLLexer.h:

(WebCore::WHLSL::Lexer::Lexer):
(WebCore::WHLSL::Lexer::Token::stringView):
(WebCore::WHLSL::Lexer::consumeToken):
(WebCore::WHLSL::Lexer::peek const):
(WebCore::WHLSL::Lexer::peekFurther const):
(WebCore::WHLSL::Lexer::state const):
(WebCore::WHLSL::Lexer::setState):
(WebCore::WHLSL::Lexer::isFullyConsumed const):
(WebCore::WHLSL::Lexer::errorString):
(WebCore::WHLSL::Lexer::string const):

  • Modules/webgpu/WHLSL/WHLSLNameResolver.h:
  • Modules/webgpu/WHLSL/WHLSLParser.cpp:

(WebCore::WHLSL::Parser::parse):
(WebCore::WHLSL::Parser::peek):
(WebCore::WHLSL::Parser::peekFurther):
(WebCore::WHLSL::Types::includes):
(WebCore::WHLSL::Types::appendNameTo):
(WebCore::WHLSL::Types<t>::includes):
(WebCore::WHLSL::Types<t>::appendNameTo):
(WebCore::WHLSL::Parser::peekTypes):
(WebCore::WHLSL::Parser::tryType):
(WebCore::WHLSL::Parser::tryTypes):
(WebCore::WHLSL::Parser::consumeType):
(WebCore::WHLSL::Parser::consumeTypes):
(WebCore::WHLSL::Parser::consumeIntegralLiteral):
(WebCore::WHLSL::Parser::parseConstantExpression):
(WebCore::WHLSL::Parser::parseTypeArgument):
(WebCore::WHLSL::Parser::parseTypeSuffixAbbreviated):
(WebCore::WHLSL::Parser::parseTypeSuffixNonAbbreviated):
(WebCore::WHLSL::Parser::parseType):
(WebCore::WHLSL::Parser::parseTypeDefinition):
(WebCore::WHLSL::Parser::parseBuiltInSemantic):
(WebCore::WHLSL::Parser::parseResourceSemantic):
(WebCore::WHLSL::Parser::parseQualifiers):
(WebCore::WHLSL::Parser::parseStructureElement):
(WebCore::WHLSL::Parser::parseStructureDefinition):
(WebCore::WHLSL::Parser::parseEnumerationDefinition):
(WebCore::WHLSL::Parser::parseEnumerationMember):
(WebCore::WHLSL::Parser::parseNativeTypeDeclaration):
(WebCore::WHLSL::Parser::parseParameter):
(WebCore::WHLSL::Parser::parseComputeFunctionDeclaration):
(WebCore::WHLSL::Parser::parseVertexOrFragmentFunctionDeclaration):
(WebCore::WHLSL::Parser::parseRegularFunctionDeclaration):
(WebCore::WHLSL::Parser::parseBlockBody):
(WebCore::WHLSL::Parser::parseSwitchCase):
(WebCore::WHLSL::Parser::parseVariableDeclaration):
(WebCore::WHLSL::Parser::parseStatement):
(WebCore::WHLSL::Parser::parseEffectfulAssignment):
(WebCore::WHLSL::Parser::parseLimitedSuffixOperator):
(WebCore::WHLSL::Parser::parseSuffixOperator):
(WebCore::WHLSL::Parser::completeAssignment):
(WebCore::WHLSL::Parser::parsePossibleTernaryConditional):
(WebCore::WHLSL::Parser::completePossibleLogicalBinaryOperation):
(WebCore::WHLSL::Parser::completePossibleRelationalBinaryOperation):
(WebCore::WHLSL::Parser::completePossibleShift):
(WebCore::WHLSL::Parser::completePossibleAdd):
(WebCore::WHLSL::Parser::completePossibleMultiply):
(WebCore::WHLSL::Parser::parsePossiblePrefix):
(WebCore::WHLSL::Parser::parseCallExpression):
(WebCore::WHLSL::Parser::parseTerm):

  • Modules/webgpu/WHLSL/WHLSLParser.h:
  • Modules/webgpu/WHLSL/WHLSLPreserveVariableLifetimes.cpp:

(WebCore::WHLSL::anonymousToken):

1:09 PM Changeset in webkit [247170] by rmorisset@apple.com
  • 9 edits in trunk/Source/WebCore

[WHLSL] Remove the phase resolveCallsInFunctions
https://bugs.webkit.org/show_bug.cgi?id=199474

Reviewed by Myles Maxfield.

This pass only stores into each property access and call expression vectors of all the functions it might be calling, for use by the Checker afterwards.
But the checker is perfectly able to compute a pointer to these vectors by itself.
So by removing this pass, we gain the following:

  • One less pass over the AST
  • No need to copy these vectors (which can be large for heavily overloaded functions, of which there are quite a few in the stdlib)
  • No need to have these vectors in the expressions, saving 24 bytes per CallExpression and 72 bytes per PropertyAccessExpression
  • No need to allocate and then destroy these vectors.

No new tests as there is no intended functional change.

  • Modules/webgpu/WHLSL/AST/WHLSLCallExpression.h:

(WebCore::WHLSL::AST::CallExpression::castReturnType):

  • Modules/webgpu/WHLSL/AST/WHLSLPropertyAccessExpression.h:
  • Modules/webgpu/WHLSL/WHLSLAutoInitializeVariables.cpp:

(WebCore::WHLSL::AutoInitialize::visit):

  • Modules/webgpu/WHLSL/WHLSLChecker.cpp:

(WebCore::WHLSL::resolveFunction):
(WebCore::WHLSL::Checker::finishVisiting):
(WebCore::WHLSL::Checker::visit):

  • Modules/webgpu/WHLSL/WHLSLNameResolver.cpp:

(WebCore::WHLSL::NameResolver::NameResolver):
(WebCore::WHLSL::NameResolver::visit):

  • Modules/webgpu/WHLSL/WHLSLNameResolver.h:
  • Modules/webgpu/WHLSL/WHLSLPrepare.cpp:

(WebCore::WHLSL::prepareShared):

1:06 PM Changeset in webkit [247169] by Matt Baker
  • 2 edits in trunk/Source/WebInspectorUI

Web Inspector: Elements: use a CSS transition when showing/hiding DOM breakpoint gutter
https://bugs.webkit.org/show_bug.cgi?id=199411

Reviewed by Devin Rousso.

  • UserInterface/Views/DOMTreeContentView.css:

(.content-view.dom-tree .tree-outline.dom):

12:19 PM Changeset in webkit [247168] by Dewei Zhu
  • 2 edits in trunk/Websites/perf.webkit.org

Test freshness page should expose revision information for latest build on tooltip.
https://bugs.webkit.org/show_bug.cgi?id=199483

Reviewed by Ryosuke Niwa.

Added latest build revision information on test freshness page tooltip.

  • public/v3/pages/test-freshness-page.js: Add build revision information on tooltip.

(TestFreshnessPage.prototype.didConstructShadowTree):
(TestFreshnessPage.prototype._fetchTestResults):
(TestFreshnessPage.prototype.render):
(TestFreshnessPage.prototype._renderTooltip):
(TestFreshnessPage.cssTemplate):

12:12 PM Changeset in webkit [247167] by Alan Bujtas
  • 3 edits
    2 adds in trunk

[ContentChangeObserver] REGRESSION (r247015): facebook photo/video upload button is unresponsive to user interaction.
https://bugs.webkit.org/show_bug.cgi?id=199502
<rdar://problem/52547473>

Reviewed by Simon Fraser.

Source/WebKit:

Apparently it's a common practice to put transparent elements over visible click targets (button like divs) and use the invisible
elements to catch the user input (e.g. Facebook's Photo/Video button).
This patch modifies the original "do not trigger click on invisible targets" heuristic to a more restrictive "do not trigger
click if the click target was previously hidden and became visible through touch start".
If this still breaks some use cases, we could turn it into YouTube quirk.

  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::handleSyntheticClick):

LayoutTests:

  • fast/events/touch/ios/content-observation/opacity-change-happens-on-touchstart-with-transition3-expected.txt: Added.
  • fast/events/touch/ios/content-observation/opacity-change-happens-on-touchstart-with-transition3.html: Added.
11:57 AM Changeset in webkit [247166] by Tadeu Zagallo
  • 2 edits in trunk/Source/JavaScriptCore

Unreviewed, change the value used to scribble Heap::m_worldState
https://bugs.webkit.org/show_bug.cgi?id=199498

Follow-up after r247160. The value used to scribble should have the
conn bit set.

  • heap/Heap.cpp:

(JSC::Heap::~Heap):

11:54 AM Changeset in webkit [247165] by youenn@apple.com
  • 9 edits in trunk

[iOS] Local capture MediaStreamTrack does not render in portrait mode
https://bugs.webkit.org/show_bug.cgi?id=199519
<rdar://problem/52689720>

Reviewed by Eric Carlson.

Source/WebCore:

RealtimeVideoSource was badly computing its size in case of rotation.
Whenever its underlying source is notifying of settings change,
compute the size and transpose it only in left/right case.

Update mock video source to cover that case.
Covered by updated test.

  • platform/mediastream/RealtimeVideoSource.cpp:

(WebCore::RealtimeVideoSource::sourceSettingsChanged):

  • platform/mediastream/mac/MockRealtimeVideoSourceMac.h:
  • platform/mediastream/mac/MockRealtimeVideoSourceMac.mm:

(WebCore::MockRealtimeVideoSourceMac::updateSampleBuffer):

  • platform/mock/MockRealtimeVideoSource.cpp:

(WebCore::MockRealtimeVideoSource::settings):
(WebCore::MockRealtimeVideoSource::orientationChanged):
(WebCore::MockRealtimeVideoSource::monitorOrientation):

  • platform/mock/MockRealtimeVideoSource.h:

LayoutTests:

  • webrtc/video-rotation-expected.txt:
  • webrtc/video-rotation.html:
11:05 AM Changeset in webkit [247164] by Ryan Haddad
  • 27 edits
    6 deletes in trunk

Unreviewed, rolling out r247115.

Breaks lldbWebKitTester (and by extension, test-webkitpy)

Reverted changeset:

"[WHLSL] Standard library is too big to directly include in
WebCore"
https://bugs.webkit.org/show_bug.cgi?id=198186
https://trac.webkit.org/changeset/247115

11:00 AM Changeset in webkit [247163] by Ryan Haddad
  • 6 edits in trunk/Source/WebCore

Unreviewed, rolling out r247159.

IndexedDB layout tests are failing the new assert.

Reverted changeset:

"ASSERT that a sessionID is valid when encoding it"
https://bugs.webkit.org/show_bug.cgi?id=199302
https://trac.webkit.org/changeset/247159

9:59 AM Changeset in webkit [247162] by Ryan Haddad
  • 12 edits in trunk

Unreviewed, rolling out r247123.

Caused TestWebKitAPI.Challenge.BasicProposedCredential to
fail.

Reverted changeset:

"Only allow fetching and removing session credentials from
WebsiteDataStore"
https://bugs.webkit.org/show_bug.cgi?id=199385
https://trac.webkit.org/changeset/247123

9:58 AM Changeset in webkit [247161] by Wenson Hsieh
  • 8 edits
    3 adds in trunk

Click events on outer page are not being dispatched correctly after touch-zooming within an iframe
https://bugs.webkit.org/show_bug.cgi?id=185001
<rdar://problem/40569615>

Reviewed by Simon Fraser.

Source/WebKit:

Mitigations introduced in r227759 prevent a touch inside a document of origin A to result in a click event being
dispatched on an element inside a document of origin B. It accomplishes this by keeping track of the security
origin of the last touch via m_potentialTapSecurityOrigin on WebPage. However, there exists a corner case in
which m_potentialTapSecurityOrigin, set after touching a document in a subframe, may persist even after the user
has finished interacting, causing taps in subsequent documents to not result in synthetic click events due to
mismatched potential tap origins.

This may happen if the first user gesture happens inside an element in a subframe with touch event handlers, but
no click event handler (and the touch is additionally not over some clickable element). In this case,
m_potentialTapNode is set to null in WebPage::potentialTapAtPosition, and when we consult it in
WebPage::commitPotentialTap, we just end up calling commitPotentialTapFailed(); and return early. This means
that m_potentialTapNode, m_potentialTapLocation, and (importantly) m_potentialTapSecurityOrigin are not reset.
This causes subsequent taps in the top-level document to never dispatch click events, if the security origin
does not match with that of the subframe.

To fix this, we add a new async IPC message from the UI process to the web process to ensure that our current
security origin is reset before attempting to handle a tap.

Test: http/tests/events/touch/ios/click-after-handling-touch-in-cross-origin-frame.https.html

  • UIProcess/WebPageProxy.cpp:

(WebKit::WebPageProxy::resetPotentialTapSecurityOrigin):

Reset any stale potential tap security origin if needed.

  • UIProcess/WebPageProxy.h:
  • UIProcess/ios/WKContentViewInteraction.mm:

(-[WKContentView _webTouchEventsRecognized:]):

Send the new IPC message when starting a touch.

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::resetPotentialTapSecurityOrigin):

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/WebPage.messages.in:

LayoutTests:

Add a new layout test to verify that after interacting with an element with touch event handlers in a cross-
origin subframe, the user is still able to click on elements on the top level document.

  • http/tests/events/touch/ios/click-after-handling-touch-in-cross-origin-frame.https-expected.txt: Added.
  • http/tests/events/touch/ios/click-after-handling-touch-in-cross-origin-frame.https.html: Added.
  • http/tests/events/touch/ios/resources/touch-target.html: Added.
9:38 AM Changeset in webkit [247160] by Tadeu Zagallo
  • 2 edits in trunk/Source/JavaScriptCore

Scribble Heap::m_worldState on destructor
https://bugs.webkit.org/show_bug.cgi?id=199498

Reviewed by Sam Weinig.

The worldState is dumped when we crash due to a failed checkConn, and
this will make it clear if the heap has already been destroyed.

  • heap/Heap.cpp:

(JSC::Heap::~Heap):

9:24 AM Changeset in webkit [247159] by youenn@apple.com
  • 6 edits in trunk/Source/WebCore

ASSERT that a sessionID is valid when encoding it
https://bugs.webkit.org/show_bug.cgi?id=199302

Reviewed by Darin Adler.

Source/WebCore:

For IDBValue, instead of encoding an invalid session ID, encode a boolean that tells there is no sessionID.
For IDBRequestData, keep track of whether there is an IDBDatabaseIdentifier
and encode/decode accordingly to not encode an invalid sessionID.
No observable change of behavior.

  • Modules/indexeddb/IDBValue.h:

(WebCore::IDBValue::sessionID const):
(WebCore::IDBValue::encode const):
(WebCore::IDBValue::decode):

  • Modules/indexeddb/shared/IDBRequestData.cpp:

(WebCore::IDBRequestData::isolatedCopy):

  • Modules/indexeddb/shared/IDBRequestData.h:

(WebCore::IDBRequestData::databaseIdentifier const):
(WebCore::IDBRequestData::decode):

Source/WebCore/PAL:

ASSERT that a sessionID is valid at encoding/decoding time.

  • pal/SessionID.h:

(PAL::SessionID::encode const):
(PAL::SessionID::decode):

9:22 AM Changeset in webkit [247158] by Wenson Hsieh
  • 14 edits
    2 adds in trunk

Touching media controls sometimes shows software keyboard
https://bugs.webkit.org/show_bug.cgi?id=199490
<rdar://problem/52076270>

Reviewed by Eric Carlson.

Source/WebKit:

In r243044, we added a compatibility hack for Google Slides (and other G-suite properties) to allow the on-
screen keyboard to show up after a prevented touch event in the case where an element was already focused, even
if the touch event handler doesn't explicitly refocus the element. However, this means that if a regular text
field (or other form control) has been programmatically focused, then interacting with any other element that
prevents default on touchstart will cause us to show the keyboard for that focused element.

To mitigate this, only fall down this refocusing codepath in the case where the focused element is a hidden
editable element (in the style of many Google productivity web apps). For non-hidden editable elements that are
already focused, this refocusing logic is not necessary, since the user should be able to interact with the
control to show the keyboard anyways; for hidden editable areas, this compatibility hack is actually needed,
since there is typically no other way for a user to focus these elements and show an on-screen keyboard.

Tests: fast/events/touch/ios/show-keyboard-after-preventing-touchstart.html

fast/events/touch/ios/do-not-show-keyboard-after-preventing-touchstart.html

  • WebProcess/WebPage/WebPage.cpp:

(WebKit::WebPage::dispatchTouchEvent):

  • WebProcess/WebPage/WebPage.h:
  • WebProcess/WebPage/ios/WebPageIOS.mm:

(WebKit::WebPage::isTransparentOrFullyClipped const):

Renamed from enclosingLayerIsTransparentOrFullyClipped, and pulled out into a private helper method.

(WebKit::WebPage::platformEditorState const):
(WebKit::WebPage::requestEvasionRectsAboveSelection):
(WebKit::WebPage::getFocusedElementInformation):
(WebKit::enclosingLayerIsTransparentOrFullyClipped): Deleted.

Tools:

Adds plumbing for a new testing hook to check whether or not there is an active input session. See other
ChangeLog entries for more detail.

  • DumpRenderTree/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptController::hasInputSession const):

  • TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
  • TestRunnerShared/UIScriptContext/UIScriptController.cpp:

(WTR::UIScriptController::hasInputSession const):

  • TestRunnerShared/UIScriptContext/UIScriptController.h:
  • WebKitTestRunner/ios/UIScriptControllerIOS.mm:

(WTR::UIScriptController::hasInputSession const):

LayoutTests:

Adds a new layout test to verify that the keyboard only appears after a handled touch event if the focused
element is inside a hidden editable area; otherwise, the keyboard should not be present.

  • fast/events/touch/ios/do-not-show-keyboard-after-preventing-touchstart-expected.txt: Added.
  • fast/events/touch/ios/do-not-show-keyboard-after-preventing-touchstart.html: Added.

This test passes as long as we didn't begin showing the keyboard after tapping.

  • fast/events/touch/ios/show-keyboard-after-preventing-touchstart-expected.txt:
  • fast/events/touch/ios/show-keyboard-after-preventing-touchstart.html:

Adjust this existing test to make the focused textarea hidden.

  • resources/ui-helper.js:

(window.UIHelper.hasInputSession):

Add a new testing hook to check whether there is an active input session.

8:29 AM Changeset in webkit [247157] by bshafiei@apple.com
  • 24 edits
    6 deletes in tags/Safari-608.1.34

Revert r247115. rdar://problem/51288898

8:29 AM Changeset in webkit [247156] by bshafiei@apple.com
  • 7 edits
    1 copy in tags/Safari-608.1.34/Source/WebCore

Revert r247124. rdar://problem/52687835

8:15 AM Changeset in webkit [247155] by bshafiei@apple.com
  • 7 edits in trunk/Source

Versioning.

8:07 AM Changeset in webkit [247154] by bshafiei@apple.com
  • 1 copy in tags/Safari-608.1.34

Tag Safari-608.1.34.

7:24 AM Changeset in webkit [247153] by Alan Bujtas
  • 2 edits in trunk/Source/WebCore

[LFC][IFC] Inline runs should be relative to the line's top/left initially
https://bugs.webkit.org/show_bug.cgi?id=199157
<rdar://problem/52053415>

Reviewed by Antti Koivisto.

Let's construct the runs relative to the line's top/left and convert them relative to the formatting root's border box top/left
when the line is being closed. When the line moves (floats etc) we don't have to move each runs individually.

  • layout/inlineformatting/InlineLine.cpp:

(WebCore::Layout::Line::close):
(WebCore::Layout::Line::moveLogicalLeft):
(WebCore::Layout::Line::appendInlineContainerStart):
(WebCore::Layout::Line::appendTextContent):
(WebCore::Layout::Line::appendNonReplacedInlineBox):
(WebCore::Layout::Line::appendHardLineBreak):

7:18 AM Changeset in webkit [247152] by Antti Koivisto
  • 5 edits in trunk/Source/WebCore

REGRESSION(r244218): desmos.com: Cannot scroll formulas region when region is scrollable
https://bugs.webkit.org/show_bug.cgi?id=199508
<rdar://problem/50925173>

Reviewed by Zalan Bujtas.

The page invokes preventDefault on simulated mouse events which stops scrolling.
To fix, add a quirk that turns simulated mouse events non-cancelable.

  • dom/MouseEvent.h:
  • dom/ios/MouseEventIOS.cpp:

(WebCore::MouseEvent::create):

  • page/Quirks.cpp:

(WebCore::Quirks::simulatedMouseEventTypeForTarget const):
(WebCore::Quirks::shouldDispatchSimulatedMouseEventsOnTarget const): Deleted.

To avoid adding more similar functions, and for future flexibility, make this one return the type too.

  • page/Quirks.h:
7:02 AM Changeset in webkit [247151] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC][IFC] Empty text node should generate empty InlineTextItem
https://bugs.webkit.org/show_bug.cgi?id=199495
<rdar://problem/52643225>

Reviewed by Antti Koivisto.

Empty text nodes generate empty RenderText renderers but they don't generate inline boxes.
This patch aligns LFC with the current rendering code.

  • layout/inlineformatting/InlineLine.cpp:

(WebCore::Layout::Line::appendTextContent):

  • layout/inlineformatting/InlineTextItem.cpp:

(WebCore::Layout::InlineTextItem::createAndAppendTextItems):

6:50 AM BuildingCairoOnWindows edited by Fujii Hironori
(diff)
6:36 AM WebKitGTK/2.24.x edited by Adrian Perez de Castro
(diff)
4:27 AM Changeset in webkit [247150] by graouts@webkit.org
  • 1 edit
    3 deletes in trunk/LayoutTests/imported/w3c

Remove Wincorrect WPT test pointerevents/pointerevent_mouse_pointercapture_inactivate_pointer.html
https://bugs.webkit.org/show_bug.cgi?id=199512

Unreviewed, just removing a test that was removed from the WPT repository (https://github.com/web-platform-tests/wpt/pull/17614).

  • web-platform-tests/pointerevents/pointerevent_mouse_pointercapture_inactivate_pointer-expected.txt: Removed.
  • web-platform-tests/pointerevents/pointerevent_mouse_pointercapture_inactivate_pointer.html: Removed.
  • web-platform-tests/pointerevents/resources/pointerevent_mouse_pointercapture_inactivate_pointer-iframe.html: Removed.
4:23 AM Changeset in webkit [247149] by Adrian Perez de Castro
  • 2 edits in trunk/Source/WebCore

[ATK] Do not use C linkage for functions using C++ features
https://bugs.webkit.org/show_bug.cgi?id=199510
<rdar://problem/52674702>

Reviewed by Carlos Garcia Campos.

No new tests needed.

  • accessibility/atk/WebKitAccessible.h: Move function and type declarations involving

C++ features outside of the block delimited by the G_BEGIN_DECLS and G_END_DECLS macros,
which were setting the C linkage.

3:25 AM Changeset in webkit [247148] by graouts@webkit.org
  • 15 edits in trunk

[Pointer Events] Respect pointer capture when dispatching mouse boundary events and updating :hover
https://bugs.webkit.org/show_bug.cgi?id=198999
<rdar://problem/51979477>

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

Mark the progressions in 3 WPT tests.

  • web-platform-tests/pointerevents/pointerevent_boundary_events_at_implicit_release_hoverable_pointers-expected.txt:
  • web-platform-tests/pointerevents/pointerevent_mouse_capture_change_hover-expected.txt:
  • web-platform-tests/pointerevents/pointerevent_setpointercapture_relatedtarget-expected.txt:

Source/WebCore:

Up until now, we would not account for pointer capture (see ​https://w3c.github.io/pointerevents/#pointer-capture) when dispatching
mouse boundary events (mouseover, mouseout, mouseenter, mouseleave) and their counterpart pointer events. We would also not account
for it when updating :hover styles.

Now, when pointer capture changes for an element, we call setCapturingMouseEventsElement() on the EventHandler such that the element
that would naturally hit-test is overridden by the pointer capture element when identifying which target to use for the dispatch of
boundary mouse events. Additionally, when calling Document::prepareMouseEvent(), we also use the pointer capture element to
pass down to Document::updateHoverActiveState() such that :hover styles are applied to the correct element.

  • dom/Document.cpp:

(WebCore::Document::prepareMouseEvent): When a new event is going to be dispatched, we must run the Process Pending Capture Element
steps as mandated by the Pointer Events spec. Calling this will dispatch the appropriate pointer capture change events and also
required boundary events since EventHandler::setCapturingMouseEventsElement() calls into EventHandler::updateMouseEventTargetNode().
Since this may update the capturing mouse events element, we ensure that we call updateHoverActiveState() with a flag that indicates that.
Finally, we use the capturing mouse events element instead of the hit-testing element to pass to updateHoverActiveState() to ensure
that is has :hover styles applied.
(WebCore::Document::updateHoverActiveState): Account for the new CaptureChange flag to force the invalidation of the :hover and :active
elements chain at all times when the capturing mouse events element changed.

  • dom/Document.h:
  • dom/PointerEvent.h: Update PointerEvent::createForPointerCapture() to take specific parameters rather than a single PointerEvent to

set the pointerId, isPrimary and pointerType properties of the generated event. This is required to call processPendingPointerCapture()
outside of PointerEvent dispatch logic since we now call it from Document::prepareMouseEvent() where we haven't yet generated such an
event.

  • page/EventHandler.cpp:

(WebCore::EventHandler::pointerCaptureElementDidChange): When a new pointer capture element is set, call updateMouseEventTargetNode()
to ensure that boundary events are fired to indicate the pointer capture state change.
(WebCore::EventHandler::prepareMouseEvent): Keep track of the last PlatformMouseEvent used to prepare a mouse event so that we can use
it when setCapturingMouseEventsElement() is called.

  • page/EventHandler.h:
  • page/PointerCaptureController.cpp:

(WebCore::PointerCaptureController::pointerCaptureElement): Since Document::prepareMouseEvent() needs to know the current pointer capture
element, add a new public method that indicates the pointer capture element if that element is contained in the provided document. We need
to provide the document since PointerCaptureController is owned by the Page and may manage several documents.
(WebCore::PointerCaptureController::dispatchEvent): Only run the Process Pending Capture Element steps when dealing with a touch or pen
event since those steps are already ran for mouse events in Document::prepareMouseEvent(). Additionally, since the element target is already
set to be the pointer capture element with the changes made to processPendingPointerCapture(), and because on iOS pointer capture is always
active, we can remove the code that would retarget the event to the pointer capture element.
(WebCore::PointerCaptureController::pointerEventWasDispatched):
(WebCore::PointerCaptureController::cancelPointer):
(WebCore::PointerCaptureController::processPendingPointerCapture): We now call into EventHandler::setCapturingMouseEventsElement() when the
capture target element changes. We must be careful to call this method prior to dispatching the "gotpointercapture" event and after dispatching
the "lostpointercapture" event so that boundary events are fired at the right time.

  • page/PointerCaptureController.h:

LayoutTests:

Update some WK1-specific expectations.

  • platform/mac-wk1/imported/w3c/web-platform-tests/pointerevents/pointerevent_boundary_events_at_implicit_release_hoverable_pointers-expected.txt:
  • platform/mac-wk1/imported/w3c/web-platform-tests/pointerevents/pointerevent_setpointercapture_relatedtarget-expected.txt:
Note: See TracTimeline for information about the timeline view.