Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ae4e64022c2f5abe9db96726c5f066812875a375
      
https://github.com/WebKit/WebKit/commit/ae4e64022c2f5abe9db96726c5f066812875a375
  Author: Wenson Hsieh <[email protected]>
  Date:   2026-09-03 (Thu, 03 Sep 2026)

  Changed paths:
    M Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml
    M Source/WebCore/css/query/MediaQueryFeatures.cpp
    M Source/WebKit/Shared/WebsitePoliciesData.cpp
    M Source/WebKit/Shared/WebsitePoliciesData.h
    M Source/WebKit/Shared/WebsitePoliciesData.serialization.in
    M Source/WebKit/UIProcess/API/APIWebsitePolicies.h
    M Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm
    M Tools/TestWebKitAPI/Tests/WebKit/WKWebView/TextExtractionTests.mm

  Log Message:
  -----------
  [Text Extraction] iOS: Override several mouse-related media queries when 
loading desktop-class content with background text extraction
https://bugs.webkit.org/show_bug.cgi?id=323355
rdar://186475042

Reviewed by Abrar Rahman Protyasha and Richard Robinson.

Override several mouse, hover and pointer-related media queries to behave more 
like Mac in the case
where:

- Background text extraction is enabled
- The client requests desktop content mode

Instead of `(pointer: coarse)` and `(hover: none)`, we'll instead get 
`(pointer: fine)` and
`(hover: hover)`.

Test: TextExtractionTests.DesktopClassHardwareEmulationInDesktopContentMode

* Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml:
* Source/WebCore/css/query/MediaQueryFeatures.cpp:
(WebCore::MQ::Features::anyHoverFeatureSchema):
(WebCore::MQ::Features::anyPointerFeatureSchema):
(WebCore::MQ::Features::hoverFeatureSchema):
(WebCore::MQ::Features::pointerFeatureSchema):
* Source/WebKit/Shared/WebsitePoliciesData.cpp:
(WebKit::WebsitePoliciesData::applyToSettings):
(WebKit::WebsitePoliciesData::applyToDocumentLoader):
* Source/WebKit/Shared/WebsitePoliciesData.h:
* Source/WebKit/Shared/WebsitePoliciesData.serialization.in:
* Source/WebKit/UIProcess/API/APIWebsitePolicies.h:
* Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
* Tools/TestWebKitAPI/Tests/WebKit/WKWebView/TextExtractionTests.mm:

Canonical link: https://commits.webkit.org/320464@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to