[webkit-changes] [295387] branches/safari-7614.1.16-branch/

2022-06-08 Thread alancoon
Title: [295387] branches/safari-7614.1.16-branch/








Revision 295387
Author alanc...@apple.com
Date 2022-06-08 11:03:58 -0700 (Wed, 08 Jun 2022)


Log Message
Delete branch.

Removed Paths

branches/safari-7614.1.16-branch/




Diff




___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295361] branches/safari-613-branch

2022-06-07 Thread alancoon
Title: [295361] branches/safari-613-branch








Revision 295361
Author alanc...@apple.com
Date 2022-06-07 13:14:22 -0700 (Tue, 07 Jun 2022)


Log Message
Revert "Calls to print can result in unresponsive print modal"

This reverts commit 8a2d5954643fd470ce6846432c4e31397f21e829.

Modified Paths

branches/safari-613-branch/Source/WebKit/ChangeLog
branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h
branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewTesting.mm
branches/safari-613-branch/Source/WebKit/UIProcess/API/ios/WKWebViewPrivateForTestingIOS.h
branches/safari-613-branch/Source/WebKit/UIProcess/WebPageProxy.cpp
branches/safari-613-branch/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp
branches/safari-613-branch/Tools/ChangeLog
branches/safari-613-branch/Tools/TestWebKitAPI/SourcesCocoa.txt
branches/safari-613-branch/Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
branches/safari-613-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/WKPDFView.mm


Removed Paths

branches/safari-613-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/WKPrinting.mm




Diff

Modified: branches/safari-613-branch/Source/WebKit/ChangeLog (295360 => 295361)

--- branches/safari-613-branch/Source/WebKit/ChangeLog	2022-06-07 19:52:13 UTC (rev 295360)
+++ branches/safari-613-branch/Source/WebKit/ChangeLog	2022-06-07 20:14:22 UTC (rev 295361)
@@ -31,30 +31,6 @@
 * UIProcess/API/C/WKWebsiteDataStoreRef.h:
 * UIProcess/WebsiteData/WebsiteDataStore.cpp:
 
-2022-03-17  Kate Cheney  
-
-Calls to print can result in unresponsive print modal
-https://bugs.webkit.org/show_bug.cgi?id=237940
-
-
-Reviewed by Chris Dumez.
-
-Calls to print were hanging in the case of the client asynchronously
-handling the completion handler passed to the delegate. To fix this
-we can adjust all printing IPC to have the option
-DispatchMessageEvenWhenWaitingForUnboundedSyncReply which allows IPC
-messages when waiting for a sync reply in the case where the receiver
-of the message is not guranteed to call the completion handler at the
-end of the runloop.
-
-* UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h:
-* UIProcess/API/Cocoa/WKWebViewTesting.mm:
-(-[WKWebView _computePagesForPrinting:completionHandler:]):
-* UIProcess/WebPageProxy.cpp:
-(WebKit::printingSendOptions):
-* WebProcess/WebCoreSupport/WebChromeClient.cpp:
-(WebKit::WebChromeClient::print):
-
 2022-04-14  Wenson Hsieh  
 
 Unreviewed, fix the Catalyst build after r292888


Modified: branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h (295360 => 295361)

--- branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h	2022-06-07 19:52:13 UTC (rev 295360)
+++ branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h	2022-06-07 20:14:22 UTC (rev 295361)
@@ -118,8 +118,6 @@
 
 - (void)_isLayerTreeFrozenForTesting:(void (^)(BOOL frozen))completionHandler WK_API_AVAILABLE(macos(WK_MAC_TBA), ios(WK_IOS_TBA));
 
-- (void)_computePagesForPrinting:(_WKFrameHandle *)handle completionHandler:(void(^)(void))completionHandler WK_API_AVAILABLE(macos(WK_MAC_TBA), ios(WK_IOS_TBA));
-
 @end
 
 typedef NS_ENUM(NSInteger, _WKMediaSessionReadyState) {


Modified: branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewTesting.mm (295360 => 295361)

--- branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewTesting.mm	2022-06-07 19:52:13 UTC (rev 295360)
+++ branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewTesting.mm	2022-06-07 20:14:22 UTC (rev 295361)
@@ -30,7 +30,6 @@
 #import "GPUProcessProxy.h"
 #import "MediaSessionCoordinatorProxyPrivate.h"
 #import "PlaybackSessionManagerProxy.h"
-#import "PrintInfo.h"
 #import "UserMediaProcessManager.h"
 #import "ViewGestureController.h"
 #import "WebPageProxy.h"
@@ -432,14 +431,6 @@
 });
 }
 
-- (void)_computePagesForPrinting:(_WKFrameHandle *)handle completionHandler:(void(^)(void))completionHandler
-{
-WebKit::PrintInfo printInfo;
-_page->computePagesForPrinting(handle->_frameHandle->frameID(), printInfo, [completionHandler = makeBlockPtr(completionHandler)] (const Vector&, double, const WebCore::FloatBoxExtent&) {
-completionHandler();
-});
-}
-
 - (void)_gpuToWebProcessConnectionCountForTesting:(void(^)(NSUInteger))completionHandler
 {
 RefPtr gpuProcess = _page->process().processPool().gpuProcess();


Modified: branches/safari-613-branch/Source/WebKit/UIProcess/API/ios/WKWebViewPrivateForTestingIOS.h (295360 => 295361)

--- branches/safari-613-branch/Source/WebKit/UIProcess/API/ios/WKWebViewPrivateForTestingIOS.h	2022-06-07 19:52:13 UTC (rev 295360)
+++ branches/safari-613-branch/Source/WebKit/UIProcess/API/ios/WKWebViewPrivateForTestingIOS.h	2022-06-07 

[webkit-changes] [295356] tags/WebKit-7614.1.14.10.13/

2022-06-07 Thread alancoon
Title: [295356] tags/WebKit-7614.1.14.10.13/








Revision 295356
Author alanc...@apple.com
Date 2022-06-07 10:22:16 -0700 (Tue, 07 Jun 2022)


Log Message
Tag WebKit-7614.1.14.10.13.

Added Paths

tags/WebKit-7614.1.14.10.13/




Diff




___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295355] branches/safari-7614.1.14.10-branch/Source

2022-06-07 Thread alancoon
Title: [295355] branches/safari-7614.1.14.10-branch/Source








Revision 295355
Author alanc...@apple.com
Date 2022-06-07 10:05:26 -0700 (Tue, 07 Jun 2022)


Log Message
Versioning.

WebKit-7614.1.14.10.13

Modified Paths

branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebInspectorUI/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebKit/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebKitLegacy/mac/Configurations/Version.xcconfig




Diff

Modified: branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig (295354 => 295355)

--- branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig	2022-06-07 17:01:28 UTC (rev 295354)
+++ branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig	2022-06-07 17:05:26 UTC (rev 295355)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 12;
+NANO_VERSION = 13;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig (295354 => 295355)

--- branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig	2022-06-07 17:01:28 UTC (rev 295354)
+++ branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig	2022-06-07 17:05:26 UTC (rev 295355)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 12;
+NANO_VERSION = 13;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig (295354 => 295355)

--- branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig	2022-06-07 17:01:28 UTC (rev 295354)
+++ branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig	2022-06-07 17:05:26 UTC (rev 295355)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 12;
+NANO_VERSION = 13;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig (295354 => 295355)

--- branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig	2022-06-07 17:01:28 UTC (rev 295354)
+++ branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig	2022-06-07 17:05:26 UTC (rev 295355)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 12;
+NANO_VERSION = 13;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig (295354 => 295355)

--- branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig	2022-06-07 17:01:28 UTC (rev 295354)
+++ branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig	2022-06-07 17:05:26 UTC (rev 295355)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 12;
+NANO_VERSION = 13;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig (295354 => 295355)

--- branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig	2022-06-07 17:01:28 UTC (rev 295354)
+++ branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig	2022-06-07 17:05:26 UTC (rev 295355)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 

[webkit-changes] [295332] tags/WebKit-7614.1.14.10.12/

2022-06-07 Thread alancoon
Title: [295332] tags/WebKit-7614.1.14.10.12/








Revision 295332
Author alanc...@apple.com
Date 2022-06-06 23:03:40 -0700 (Mon, 06 Jun 2022)


Log Message
Tag WebKit-7614.1.14.10.12.

Added Paths

tags/WebKit-7614.1.14.10.12/




Diff




___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295331] branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/src/ libANGLE/renderer/metal/ContextMtl.mm

2022-06-06 Thread alancoon
Title: [295331] branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/ContextMtl.mm








Revision 295331
Author alanc...@apple.com
Date 2022-06-06 22:47:37 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick r294877. rdar://problem/93834054

Uniform buffer reuse causes flush, creates invalid state
https://bugs.webkit.org/show_bug.cgi?id=240896

Patch by Kimmo Kinnunen  on 2022-05-26
Patch by Kyle Piddington.

Reviewed by Kimmo Kinnunen.

A flush during draw setup would leave the render command encoder
not started and render pipeline unset. This would assert in debug
and leak memory with corrupted draws in release.

This would happen for example when uniform buffer pool would run
out of uniform memory. If the pool is maxed out, we flush the
existing rendering to obtain free buffers. After the flush,
we need to re-run the setup.

Test is tracked in bug 240948.

* Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/ContextMtl.mm:
(rx::ContextMtl::setupDraw):
(rx::ContextMtl::setupDrawImpl):

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

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

Modified Paths

branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/ContextMtl.mm




Diff

Modified: branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/ContextMtl.mm (295330 => 295331)

--- branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/ContextMtl.mm	2022-06-07 05:47:34 UTC (rev 295330)
+++ branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/src/libANGLE/renderer/metal/ContextMtl.mm	2022-06-07 05:47:37 UTC (rev 295331)
@@ -,6 +,32 @@
 const void *indices,
 bool xfbPass)
 {
+ANGLE_TRY(setupDrawImpl(context, mode, firstVertex, vertexOrIndexCount, instances,
+indexTypeOrNone, indices, xfbPass));
+if (!mRenderEncoder.valid())
+{
+// Flush occurred during setup, due to running out of memory while setting up the render
+// pass state. This would happen for example when there is no more space in the uniform
+// buffers in the uniform buffer pool. The rendering would be flushed to free the uniform
+// buffer memory for new usage. In this case, re-run the setup.
+ANGLE_TRY(setupDrawImpl(context, mode, firstVertex, vertexOrIndexCount, instances,
+indexTypeOrNone, indices, xfbPass));
+// Setup with flushed state should either produce a working encoder or fail with an error
+// result.
+ASSERT(mRenderEncoder.valid());
+}
+return angle::Result::Continue;
+}
+
+angle::Result ContextMtl::setupDrawImpl(const gl::Context *context,
+gl::PrimitiveMode mode,
+GLint firstVertex,
+GLsizei vertexOrIndexCount,
+GLsizei instances,
+gl::DrawElementsType indexTypeOrNone,
+const void *indices,
+bool xfbPass)
+{
 ASSERT(mProgram);
 
 // instances=0 means no instanced draw.






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295330] branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess

2022-06-06 Thread alancoon
Title: [295330] branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess








Revision 295330
Author alanc...@apple.com
Date 2022-06-06 22:47:34 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick r294831. rdar://problem/93656000

Prevent NSAttributedString crashes when AppSSO URLs are provided
https://bugs.webkit.org/show_bug.cgi?id=240739


Reviewed by Chris Dumez.

When NSAttributedString is used in a sandboxed app, it is prevented from checking in with the
AppSSO plugin manager, causing a Sandbox Violation and crash. We don't want NSAttributedString
to ever hand-off to AppSSO, so we should configure it's internal WKWebView to do the right thing.
Reviewed by Chris Dumez.

* Source/WebKit/UIProcess/API/Cocoa/NSAttributedString.mm:
(+[_WKAttributedStringWebViewCache configuration]): Turn off AppSSO for string uses.
* Source/WebKit/UIProcess/Cocoa/NavigationState.mm:
(WebKit::trySOAuthorization): Use new lazy loading approach.
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::trySOAuthorization): Ditto.
* Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp:
(WebKit::WebsiteDataStore::WebsiteDataStore):
(WebKit::WebsiteDataStore::soAuthorizationCoordinator): Lazily initialize, and RELEASE_ASSERT
if we somehow reach this code without enabling AppSSO.
* Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h:
(WebKit::WebsiteDataStore::soAuthorizationCoordinator): Deleted.

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

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

Modified Paths

branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/API/Cocoa/NSAttributedString.mm
branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/Cocoa/NavigationState.mm
branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/WebPageProxy.cpp
branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.h




Diff

Modified: branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/API/Cocoa/NSAttributedString.mm (295329 => 295330)

--- branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/API/Cocoa/NSAttributedString.mm	2022-06-07 05:47:29 UTC (rev 295329)
+++ branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/API/Cocoa/NSAttributedString.mm	2022-06-07 05:47:34 UTC (rev 295330)
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2019 Apple Inc. All rights reserved.
+ * Copyright (C) 2019-2022 Apple Inc. All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
@@ -144,6 +144,7 @@
 [configuration _setAllowsJavaScriptMarkup:NO];
 [configuration _setAllowsMetaRefresh:NO];
 [configuration _setAttachmentElementEnabled:YES];
+[configuration preferences]._extensibleSSOEnabled = NO;
 [configuration _setInvisibleAutoplayNotPermitted:YES];
 [configuration _setMediaDataLoadsAutomatically:NO];
 [configuration _setNeedsStorageAccessFromFileURLsQuirk:NO];


Modified: branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/Cocoa/NavigationState.mm (295329 => 295330)

--- branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/Cocoa/NavigationState.mm	2022-06-07 05:47:29 UTC (rev 295329)
+++ branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/Cocoa/NavigationState.mm	2022-06-07 05:47:34 UTC (rev 295330)
@@ -424,7 +424,7 @@
 completionHandler(false);
 return;
 }
-page.websiteDataStore().soAuthorizationCoordinator().tryAuthorize(WTFMove(navigationAction), page, WTFMove(completionHandler));
+page.websiteDataStore().soAuthorizationCoordinator(page).tryAuthorize(WTFMove(navigationAction), page, WTFMove(completionHandler));
 #else
 completionHandler(false);
 #endif


Modified: branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/WebPageProxy.cpp (295329 => 295330)

--- branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/WebPageProxy.cpp	2022-06-07 05:47:29 UTC (rev 295329)
+++ branches/safari-7614.1.14.10-branch/Source/WebKit/UIProcess/WebPageProxy.cpp	2022-06-07 05:47:34 UTC (rev 295330)
@@ -5996,7 +5996,7 @@
 static void trySOAuthorization(Ref&& navigationAction, WebPageProxy& page, NewPageCallback&& newPageCallback, UIClientCallback&& uiClientCallback)
 {
 #if HAVE(APP_SSO)
-page.websiteDataStore().soAuthorizationCoordinator().tryAuthorize(WTFMove(navigationAction), page, WTFMove(newPageCallback), WTFMove(uiClientCallback));
+page.websiteDataStore().soAuthorizationCoordinator(page).tryAuthorize(WTFMove(navigationAction), page, WTFMove(newPageCallback), WTFMove(uiClientCallback));
 #else
 uiClientCallback(WTFMove(navigationAction), WTFMove(newPageCallback));
 #endif


Modified: 

[webkit-changes] [295329] branches/safari-7614.1.14.10-branch

2022-06-06 Thread alancoon
Title: [295329] branches/safari-7614.1.14.10-branch








Revision 295329
Author alanc...@apple.com
Date 2022-06-06 22:47:29 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick r294186. rdar://problem/93805727

Infinite recursion caused by call to accessibilityIsIgnored in the midst of AccessibilityObject::ignoredFromModalPresence
https://bugs.webkit.org/show_bug.cgi?id=240365

Reviewed by Chris Fleizach.

Source/WebCore:

We can get infinite recursion when accessibilityIsIgnored is called as
part of computing AccessibilityObject::ignoredFromModalPresence. One
example of such a cycle:

AXObjectCache::currentModalNode() ->
AccessibilityRenderObject::computeAccessibilityIsIgnored() ->
AccessibilityRenderObject::parentObjectUnignored() ->
AccessibilityObject::accessibilityIsIgnored() ->
AccessibilityObject::ignoredFromModalPresence() ->
AXObjectCache::currentModalNode() ->
...repeat...

This patch fixes this by tracking when we start computing the current
modal node in the AXObjectCache. Then, in AccessibilityObject::accessibilityIsIgnored(),
we don't call AccessibilityObject::ignoredFromModalPresence() if this new state is true,
since in this context we only need to know if the object is inherently
ignored (i.e. ignored disregarding modal presence).

Test: accessibility/aria-modal-with-text-crash.html

* accessibility/AXObjectCache.cpp:
(WebCore::AXObjectCache::currentModalNode):
* accessibility/AXObjectCache.h:
Add m_isRetrievingCurrentModalNode.
(WebCore::AXObjectCache::isRetrievingCurrentModalNode): Added.
* accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::accessibilityIsIgnored const):
Don't call ignoredFromModalPresence if we're in the midst of computing the current modal.

LayoutTests:

* accessibility/aria-modal-with-text-crash-expected.txt: Added.
* accessibility/aria-modal-with-text-crash.html: Added.
* platform/glib/TestExpectations: Skip new test.
* platform/ios/TestExpectations: Enable new test.
* platform/win/TestExpectations: Skip new test.

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

Modified Paths

branches/safari-7614.1.14.10-branch/LayoutTests/ChangeLog
branches/safari-7614.1.14.10-branch/LayoutTests/platform/glib/TestExpectations
branches/safari-7614.1.14.10-branch/LayoutTests/platform/ios/TestExpectations
branches/safari-7614.1.14.10-branch/LayoutTests/platform/win/TestExpectations
branches/safari-7614.1.14.10-branch/Source/WebCore/ChangeLog
branches/safari-7614.1.14.10-branch/Source/WebCore/accessibility/AXObjectCache.cpp
branches/safari-7614.1.14.10-branch/Source/WebCore/accessibility/AXObjectCache.h
branches/safari-7614.1.14.10-branch/Source/WebCore/accessibility/AccessibilityObject.cpp


Added Paths

branches/safari-7614.1.14.10-branch/LayoutTests/accessibility/aria-modal-with-text-crash-expected.txt
branches/safari-7614.1.14.10-branch/LayoutTests/accessibility/aria-modal-with-text-crash.html




Diff

Modified: branches/safari-7614.1.14.10-branch/LayoutTests/ChangeLog (295328 => 295329)

--- branches/safari-7614.1.14.10-branch/LayoutTests/ChangeLog	2022-06-07 05:37:39 UTC (rev 295328)
+++ branches/safari-7614.1.14.10-branch/LayoutTests/ChangeLog	2022-06-07 05:47:29 UTC (rev 295329)
@@ -1,3 +1,67 @@
+2022-06-06  Alan Coon  
+
+Cherry-pick r294186. rdar://problem/93805727
+
+Infinite recursion caused by call to accessibilityIsIgnored in the midst of AccessibilityObject::ignoredFromModalPresence
+https://bugs.webkit.org/show_bug.cgi?id=240365
+
+Reviewed by Chris Fleizach.
+
+Source/WebCore:
+
+We can get infinite recursion when accessibilityIsIgnored is called as
+part of computing AccessibilityObject::ignoredFromModalPresence. One
+example of such a cycle:
+
+AXObjectCache::currentModalNode() ->
+AccessibilityRenderObject::computeAccessibilityIsIgnored() ->
+AccessibilityRenderObject::parentObjectUnignored() ->
+AccessibilityObject::accessibilityIsIgnored() ->
+AccessibilityObject::ignoredFromModalPresence() ->
+AXObjectCache::currentModalNode() ->
+...repeat...
+
+This patch fixes this by tracking when we start computing the current
+modal node in the AXObjectCache. Then, in AccessibilityObject::accessibilityIsIgnored(),
+we don't call AccessibilityObject::ignoredFromModalPresence() if this new state is true,
+since in this context we only need to know if the object is inherently
+ignored (i.e. ignored disregarding modal presence).
+
+Test: accessibility/aria-modal-with-text-crash.html
+
+* accessibility/AXObjectCache.cpp:
+(WebCore::AXObjectCache::currentModalNode):
+* accessibility/AXObjectCache.h:
+Add m_isRetrievingCurrentModalNode.
+(WebCore::AXObjectCache::isRetrievingCurrentModalNode): Added.
+* 

[webkit-changes] [295328] branches/safari-7614.1.14.10-branch/Source

2022-06-06 Thread alancoon
Title: [295328] branches/safari-7614.1.14.10-branch/Source








Revision 295328
Author alanc...@apple.com
Date 2022-06-06 22:37:39 -0700 (Mon, 06 Jun 2022)


Log Message
Versioning.

WebKit-7614.1.14.10.12

Modified Paths

branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebInspectorUI/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebKit/Configurations/Version.xcconfig
branches/safari-7614.1.14.10-branch/Source/WebKitLegacy/mac/Configurations/Version.xcconfig




Diff

Modified: branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig (295327 => 295328)

--- branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig	2022-06-07 03:58:28 UTC (rev 295327)
+++ branches/safari-7614.1.14.10-branch/Source/_javascript_Core/Configurations/Version.xcconfig	2022-06-07 05:37:39 UTC (rev 295328)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 11;
+NANO_VERSION = 12;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig (295327 => 295328)

--- branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig	2022-06-07 03:58:28 UTC (rev 295327)
+++ branches/safari-7614.1.14.10-branch/Source/ThirdParty/ANGLE/Configurations/Version.xcconfig	2022-06-07 05:37:39 UTC (rev 295328)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 11;
+NANO_VERSION = 12;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig (295327 => 295328)

--- branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig	2022-06-07 03:58:28 UTC (rev 295327)
+++ branches/safari-7614.1.14.10-branch/Source/ThirdParty/libwebrtc/Configurations/Version.xcconfig	2022-06-07 05:37:39 UTC (rev 295328)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 11;
+NANO_VERSION = 12;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig (295327 => 295328)

--- branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig	2022-06-07 03:58:28 UTC (rev 295327)
+++ branches/safari-7614.1.14.10-branch/Source/WebCore/Configurations/Version.xcconfig	2022-06-07 05:37:39 UTC (rev 295328)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 11;
+NANO_VERSION = 12;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig (295327 => 295328)

--- branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig	2022-06-07 03:58:28 UTC (rev 295327)
+++ branches/safari-7614.1.14.10-branch/Source/WebCore/PAL/Configurations/Version.xcconfig	2022-06-07 05:37:39 UTC (rev 295328)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 TINY_VERSION = 14;
 MICRO_VERSION = 10;
-NANO_VERSION = 11;
+NANO_VERSION = 12;
 FULL_VERSION = $(MAJOR_VERSION).$(MINOR_VERSION).$(TINY_VERSION).$(MICRO_VERSION).$(NANO_VERSION);
 
 // The bundle version and short version string are set based on the current build configuration, see below.


Modified: branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig (295327 => 295328)

--- branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig	2022-06-07 03:58:28 UTC (rev 295327)
+++ branches/safari-7614.1.14.10-branch/Source/WebGPU/Configurations/Version.xcconfig	2022-06-07 05:37:39 UTC (rev 295328)
@@ -25,7 +25,7 @@
 MINOR_VERSION = 1;
 

[webkit-changes] [295325] trunk/Tools/Scripts/libraries

2022-06-06 Thread alancoon
Title: [295325] trunk/Tools/Scripts/libraries








Revision 295325
Author alanc...@apple.com
Date 2022-06-06 20:43:00 -0700 (Mon, 06 Jun 2022)


Log Message
Add proxy support to webkitscmpy's GitHub client
https://bugs.webkit.org/show_bug.cgi?id=241031
rdar://93129765

Reviewed by Jonathan Bedard.

Allow for the passing of proxy settings to the GitHub client. Use
requests.Session to pass the proxy settings to all requests made.

Additionally pass this session to the Tracker data member, for
github.com networking requests made at the Tracker level.

Version bumps webkitbugspy and webkitscmpy.

* Tools/Scripts/libraries/webkitbugspy/setup.py: version bump to 0.6.3
* Tools/Scripts/libraries/webkitbugspy/webkitbugspy/__init__.py: version bump to 0.6.3
* Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py:
Add a requests.Session member to the class that can be passed into the constructor.
Call all networking requests through the session.
(Tracker.__init__):
(Tracker):
(Tracker.credentials.validater):
* Tools/Scripts/libraries/webkitscmpy/setup.py: version bump to 4.15.4
* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/__init__.py: version bump to 4.15.4
* Tools/Scripts/libraries/webkitscmpy/webkitscmpy/remote/git_hub.py:
Add a proxies argument to the constructor. Will pass proxies to a request.Session member
that is used to perform networking requests to github.com from this class.
This session is passed to the Tracker member in its constructor (see webkitbugspy.github changes).
(GitHub.PRGenerator.create):
(GitHub.PRGenerator.update):
(GitHub.__init__):
(GitHub.request):
(GitHub._count_for_ref):
(GitHub._branches_for):

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

Modified Paths

trunk/Tools/Scripts/libraries/webkitbugspy/setup.py
trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/__init__.py
trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py
trunk/Tools/Scripts/libraries/webkitscmpy/setup.py
trunk/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/__init__.py
trunk/Tools/Scripts/libraries/webkitscmpy/webkitscmpy/remote/git_hub.py




Diff

Modified: trunk/Tools/Scripts/libraries/webkitbugspy/setup.py (295324 => 295325)

--- trunk/Tools/Scripts/libraries/webkitbugspy/setup.py	2022-06-07 02:30:53 UTC (rev 295324)
+++ trunk/Tools/Scripts/libraries/webkitbugspy/setup.py	2022-06-07 03:43:00 UTC (rev 295325)
@@ -30,7 +30,7 @@
 
 setup(
 name='webkitbugspy',
-version='0.6.2',
+version='0.6.3',
 description='Library containing a shared API for various bug trackers.',
 long_description=readme(),
 classifiers=[


Modified: trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/__init__.py (295324 => 295325)

--- trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/__init__.py	2022-06-07 02:30:53 UTC (rev 295324)
+++ trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/__init__.py	2022-06-07 03:43:00 UTC (rev 295325)
@@ -46,7 +46,7 @@
 "Please install webkitcorepy with `pip install webkitcorepy --extra-index-url `"
 )
 
-version = Version(0, 6, 2)
+version = Version(0, 6, 3)
 
 from .user import User
 from .issue import Issue


Modified: trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py (295324 => 295325)

--- trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py	2022-06-07 02:30:53 UTC (rev 295324)
+++ trunk/Tools/Scripts/libraries/webkitbugspy/webkitbugspy/github.py	2022-06-07 03:43:00 UTC (rev 295325)
@@ -65,10 +65,15 @@
 raise TypeError('Cannot invoke parent class when classmethod')
 return super(Tracker.Encoder, context).default(obj)
 
-
-def __init__(self, url, users=None, res=None, component_color=DEFAULT_COMPONENT_COLOR, version_color=DEFAULT_VERSION_COLOR):
+def __init__(
+self, url, users=None, res=None,
+component_color=DEFAULT_COMPONENT_COLOR,
+version_color=DEFAULT_VERSION_COLOR,
+session=None
+):
 super(Tracker, self).__init__(users=users)
 
+self.session = session or requests.Session()
 self.component_color = component_color
 self.version_color = version_color
 
@@ -98,7 +103,7 @@
 if '@' in username:
 sys.stderr.write("Provided username contains an '@' symbol. Please make sure to enter your GitHub username, not an email associated with the account\n")
 return False
-response = requests.get(
+response = self.session.get(
 '{}/user'.format(self.api_url),
 headers=dict(Accept='application/vnd.github.v3+json'),
 auth=HTTPBasicAuth(username, access_token),
@@ -158,7 +163,7 @@
 name=self.name,
 path='{}'.format(path) if path else '',
 )
-response = requests.request(method, url, params=params, headers=headers, auth=auth, json=json)
+response = self.session.request(method, url, params=params, headers=headers, auth=auth, 

[webkit-changes] [295324] branches/safari-613-branch/Source/WebCore

2022-06-06 Thread alancoon
Title: [295324] branches/safari-613-branch/Source/WebCore








Revision 295324
Author alanc...@apple.com
Date 2022-06-06 19:30:53 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick c88d60bba878. rdar://problem/91643534

 always sends credentials to different-origin, ignoring crossorigin=anonymous
https://bugs.webkit.org/show_bug.cgi?id=239119


Reviewed by John Wilander.

Update the check as per spec, step 5 of
https://html.spec.whatwg.org/multipage/links.html#link-type-preconnect

This is difficult to test as preconnect can only expose TLS credentials.

* loader/LinkLoader.cpp:
(WebCore::LinkLoader::preconnectIfNeeded):

Canonical link: https://commits.webkit.org/250034@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293503 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/loader/LinkLoader.cpp




Diff

Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (295323 => 295324)

--- branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:49 UTC (rev 295323)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:53 UTC (rev 295324)
@@ -1,3 +1,19 @@
+2022-04-27  Youenn Fablet  
+
+ always sends credentials to different-origin, ignoring crossorigin=anonymous
+https://bugs.webkit.org/show_bug.cgi?id=239119
+
+
+Reviewed by John Wilander.
+
+Update the check as per spec, step 5 of
+https://html.spec.whatwg.org/multipage/links.html#link-type-preconnect
+
+This is difficult to test as preconnect can only expose TLS credentials.
+
+* loader/LinkLoader.cpp:
+(WebCore::LinkLoader::preconnectIfNeeded):
+
 2022-05-06  Patrick Griffis  
 
 CSP: Fix script-src-elem policies in workers


Modified: branches/safari-613-branch/Source/WebCore/loader/LinkLoader.cpp (295323 => 295324)

--- branches/safari-613-branch/Source/WebCore/loader/LinkLoader.cpp	2022-06-07 02:30:49 UTC (rev 295323)
+++ branches/safari-613-branch/Source/WebCore/loader/LinkLoader.cpp	2022-06-07 02:30:53 UTC (rev 295324)
@@ -214,7 +214,7 @@
 return;
 ASSERT(document.settings().linkPreconnectEnabled());
 StoredCredentialsPolicy storageCredentialsPolicy = StoredCredentialsPolicy::Use;
-if (equalIgnoringASCIICase(params.crossOrigin, "anonymous") && document.securityOrigin().isSameOriginDomain(SecurityOrigin::create(href)))
+if (equalIgnoringASCIICase(params.crossOrigin, "anonymous") && !document.securityOrigin().isSameOriginDomain(SecurityOrigin::create(href)))
 storageCredentialsPolicy = StoredCredentialsPolicy::DoNotUse;
 ASSERT(document.frame()->loader().networkingContext());
 platformStrategies()->loaderStrategy()->preconnectTo(document.frame()->loader(), href, storageCredentialsPolicy, LoaderStrategy::ShouldPreconnectAsFirstParty::No, [weakDocument = WeakPtr { document }, href](ResourceError error) {






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295321] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295321] branches/safari-613-branch








Revision 295321
Author alanc...@apple.com
Date 2022-06-06 19:30:29 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick bf09fd4a06a7. rdar://problem/92033309

Add testRunner API to clear memory cache
https://bugs.webkit.org/show_bug.cgi?id=239804
rdar://92033309

Reviewed by Chris Dumez.

Source/WebCore:

* testing/Internals.cpp:
(WebCore::Internals::clearMemoryCache):
Beef up clearMemoryCache to be on par with testRunner counterpart.

Source/WebKit:

Add necessary WebKit API to implement the testRunner API.
Make use of new testRunner API in added test.

Test: http/wpt/fetch/clear-memory-cache.html

* NetworkProcess/NetworkProcess.cpp:
* UIProcess/API/C/WKWebsiteDataStoreRef.cpp:
* UIProcess/API/C/WKWebsiteDataStoreRef.h:
* UIProcess/WebsiteData/WebsiteDataStore.cpp:

Tools:

Implement the clear memory cache testRunner API and related plumbery.

* WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
* WebKitTestRunner/InjectedBundle/TestRunner.cpp:
* WebKitTestRunner/InjectedBundle/TestRunner.h:
* WebKitTestRunner/TestController.cpp:
* WebKitTestRunner/TestController.h:
* WebKitTestRunner/TestInvocation.cpp:

LayoutTests:

* http/wpt/fetch/clear-memory-cache-expected.txt: Added.
* http/wpt/fetch/clear-memory-cache.html: Added.
* http/wpt/fetch/resources/clear-memory-cache.py: Added.

Canonical link: https://commits.webkit.org/250033@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293502 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/ChangeLog
branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/testing/Internals.cpp
branches/safari-613-branch/Source/WebKit/ChangeLog
branches/safari-613-branch/Source/WebKit/NetworkProcess/NetworkProcess.cpp
branches/safari-613-branch/Source/WebKit/UIProcess/API/C/WKWebsiteDataStoreRef.cpp
branches/safari-613-branch/Source/WebKit/UIProcess/API/C/WKWebsiteDataStoreRef.h
branches/safari-613-branch/Source/WebKit/UIProcess/WebsiteData/WebsiteDataStore.cpp
branches/safari-613-branch/Tools/ChangeLog
branches/safari-613-branch/Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl
branches/safari-613-branch/Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp
branches/safari-613-branch/Tools/WebKitTestRunner/InjectedBundle/TestRunner.h
branches/safari-613-branch/Tools/WebKitTestRunner/TestController.cpp
branches/safari-613-branch/Tools/WebKitTestRunner/TestController.h
branches/safari-613-branch/Tools/WebKitTestRunner/TestInvocation.cpp


Added Paths

branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache-expected.txt
branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache.html
branches/safari-613-branch/LayoutTests/http/wpt/fetch/resources/clear-memory-cache.py




Diff

Modified: branches/safari-613-branch/LayoutTests/ChangeLog (295320 => 295321)

--- branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 02:30:22 UTC (rev 295320)
+++ branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 02:30:29 UTC (rev 295321)
@@ -1,3 +1,15 @@
+2022-04-27  Youenn Fablet  
+
+Add testRunner API to clear memory cache
+https://bugs.webkit.org/show_bug.cgi?id=239804
+rdar://92033309
+
+Reviewed by Chris Dumez.
+
+* http/wpt/fetch/clear-memory-cache-expected.txt: Added.
+* http/wpt/fetch/clear-memory-cache.html: Added.
+* http/wpt/fetch/resources/clear-memory-cache.py: Added.
+
 2022-04-28  Patrick Griffis  
 
 CSP: Fix mixing strict-dynamic and unsafe-inline policies


Added: branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache-expected.txt (0 => 295321)

--- branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache-expected.txt	(rev 0)
+++ branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache-expected.txt	2022-06-07 02:30:29 UTC (rev 295321)
@@ -0,0 +1,3 @@
+
+PASS Clear memory cache between fetches
+


Added: branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache.html (0 => 295321)

--- branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache.html	(rev 0)
+++ branches/safari-613-branch/LayoutTests/http/wpt/fetch/clear-memory-cache.html	2022-06-07 02:30:29 UTC (rev 295321)
@@ -0,0 +1,31 @@
+
+
+promise_test(async (test) => {
+const uuid = token();
+const url = "" + '/WebKit/fetch/resources/clear-memory-cache.py?uuid=' + uuid;
+
+await fetch(url, { mode: 'cors', headers: [['header', 'value']] });
+
+let response = await fetch(url, { mode: 'cors' });
+assert_equals(await response.text(), "1");
+
+if (window.testRunner && testRunner.clearMemoryCache)
+testRunner.clearMemoryCache();
+
+if (window.internals)
+internals.clearMemoryCache();

[webkit-changes] [295322] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295322] branches/safari-613-branch








Revision 295322
Author alanc...@apple.com
Date 2022-06-06 19:30:34 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick e40c1e30bd61. rdar://problem/94467808

CSP: Fix script-src-elem policies in workers
https://bugs.webkit.org/show_bug.cgi?id=239840

Reviewed by Kate Cheney.

Source/WebCore:

Test: http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html

* page/csp/ContentSecurityPolicyDirectiveList.cpp:
(WebCore::ContentSecurityPolicyDirectiveList::violatedDirectiveForScript const):

LayoutTests:

CSP: Fix script-src-elem policies in workers

* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem-expected.txt: Added.
* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html: Added.

Canonical link: https://commits.webkit.org/250386@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293940 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/ChangeLog
branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/page/csp/ContentSecurityPolicyDirectiveList.cpp


Added Paths

branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem-expected.txt
branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html




Diff

Modified: branches/safari-613-branch/LayoutTests/ChangeLog (295321 => 295322)

--- branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 02:30:29 UTC (rev 295321)
+++ branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 02:30:34 UTC (rev 295322)
@@ -1,3 +1,15 @@
+2022-05-06  Patrick Griffis  
+
+CSP: Fix script-src-elem policies in workers
+https://bugs.webkit.org/show_bug.cgi?id=239840
+
+Reviewed by Kate Cheney.
+
+CSP: Fix script-src-elem policies in workers
+
+* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem-expected.txt: Added.
+* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html: Added.
+
 2022-04-27  Youenn Fablet  
 
 Add testRunner API to clear memory cache


Added: branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem-expected.txt (0 => 295322)

--- branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem-expected.txt	(rev 0)
+++ branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem-expected.txt	2022-06-07 02:30:34 UTC (rev 295322)
@@ -0,0 +1,2 @@
+ALERT: importScripts allowed
+


Added: branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html (0 => 295322)

--- branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html	(rev 0)
+++ branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html	2022-06-07 02:30:34 UTC (rev 295322)
@@ -0,0 +1,28 @@
+
+
+
+
+if (window.testRunner) {
+testRunner.waitUntilDone();
+testRunner.dumpAsText();
+}
+
+
+
+
+try {
+var worker = new Worker('http://127.0.0.1:8000/security/contentSecurityPolicy/resources/worker.py?type=importscripts&csp=' +
+encodeURIComponent("script-src 'strict-dynamic'; script-src-elem localhost:8000"));
+worker._onmessage_ = function (event) {
+alert(event.data);
+if (window.testRunner)
+testRunner.notifyDone();
+};
+} catch (e) {
+alert(e);
+if (window.testRunner)
+testRunner.notifyDone();
+}
+
+
+


Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (295321 => 295322)

--- branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:29 UTC (rev 295321)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:34 UTC (rev 295322)
@@ -1,3 +1,15 @@
+2022-05-06  Patrick Griffis  
+
+CSP: Fix script-src-elem policies in workers
+https://bugs.webkit.org/show_bug.cgi?id=239840
+
+Reviewed by Kate Cheney.
+
+Test: http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-script-src-elem.html
+
+* page/csp/ContentSecurityPolicyDirectiveList.cpp:
+(WebCore::ContentSecurityPolicyDirectiveList::violatedDirectiveForScript const):
+
 2022-04-27  Youenn Fablet  
 
 Add testRunner API to clear memory cache


Modified: 

[webkit-changes] [295319] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295319] branches/safari-613-branch








Revision 295319
Author alanc...@apple.com
Date 2022-06-06 19:30:20 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 97487f0eee71. rdar://problem/90755619

[iOS 15] Unable to type in Google Docs with a hardware keyboard without refocusing editor
https://bugs.webkit.org/show_bug.cgi?id=241308
rdar://90755619

Reviewed by Tim Horton.

After the changes in r277265, we no longer call into `-reloadInputViews` when starting an input
session after programmatically focusing an editable container with `inputmode="none"`, with a
hardware keyboard attached. This is because `-_shouldShowKeyboardForElement:` returns `NO` (due to
inputmode none), so we bail early at this check:

```
if (!shouldShowInputView || information.elementType == WebKit::InputType::None) {
_page->setIsShowingInputViewForFocusedElement(false);
return;
}
```

As a result, UIKit never resets UIKeyboardImpl's input delegate, which should now be the
`WKContentView`, and thus never consults whether we require key events (`-requiresKeyEvents`), which
in turn means that `-handleKeyWebEvent:withCompletionHandler:` is never invoked on the content view,
so we never dispatch key events to the page.

In the normal, non-editable key event case, we lazily call `-reloadInputViews` in
`-_handleKeyUIEvent:` (which is called just before keyboard WebEvents start getting dispatched by
UIKit). However, since we're still focusing an editable element in this case, we don't end up going
down this codepath.

When the hardware keyboard is not connected, avoiding the call to `-reloadInputViews` is expected,
since we aren't showing a keyboard anyways due to the fact that the element was programmatically
focused (so the user has no way of typing or dispatching key events, in the first place).

And finally, when the `inputmode` is not none, `_isFocusingElementWithKeyboard` is set to `YES`, so
we begin the input session and call `-reloadInputViews` as normal.

It's only in this `inputmode=none` case with both the hardware keyboard attached and the editable
container being programmatically focused, where we end up in a state where the user can type with a
hardware keyboard, but we haven't informed UIKit that we should receive key events.

We can fix this by consulting a separate `-_shouldShowKeyboardForElementIgnoringInputMode:` instead
which allows us to follow the normal routine for focusing an editable element with `inputmode="none"`
which includes zooming to reveal the focused element if it's on-screen and not hidden, as well as
calling the related delegate methods; the only difference is that we avoid showing the UCB or
software keyboard, by returning `YES` from `-_disableAutomaticKeyboardUI` in this case.

* LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none-expected.txt: Added.
* LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none.html: Added.

Add a new layout test to simulate typing in Google Docs with a hardware keyboard (i.e., focus a
hidden contenteditable container with `inputmode="none"`), and verify that we dispatch key events to
the focused editable element.

* Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _elementTypeRequiresAccessoryView:]):
(-[WKContentView _shouldShowKeyboardForElement:]):
(-[WKContentView _shouldShowKeyboardForElementIgnoringInputMode:]):

Split this helper method into two versions (one of which ignores `inputmode=none`). See above for
more details.

(-[WKContentView _elementDidFocus:userIsInteracting:blurPreviousNode:activityStateChanges:userObject:]):

Canonical link: https://commits.webkit.org/251335@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295289 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm


Added Paths

branches/safari-613-branch/LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none-expected.txt
branches/safari-613-branch/LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none.html




Diff

Added: branches/safari-613-branch/LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none-expected.txt (0 => 295319)

--- branches/safari-613-branch/LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none-expected.txt	(rev 0)
+++ branches/safari-613-branch/LayoutTests/fast/forms/ios/keydown-in-hidden-contenteditable-with-inputmode-none-expected.txt	2022-06-07 02:30:20 UTC (rev 295319)
@@ -0,0 +1,13 @@
+This test verifies that key events are dispatched when performing a keypress in a programmatically focused hidden editable container with inputmode='none'. To manually run the 

[webkit-changes] [295317] branches/safari-613-branch/Source/WebCore

2022-06-06 Thread alancoon
Title: [295317] branches/safari-613-branch/Source/WebCore








Revision 295317
Author alanc...@apple.com
Date 2022-06-06 19:30:12 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 753398de3962. rdar://problem/92081823

Use more smart pointers in Element.cpp
https://bugs.webkit.org/show_bug.cgi?id=239836

Patch by Alex Christensen  on 2022-04-28
Reviewed by Chris Dumez.

* dom/Element.cpp:
(WebCore::Element::setScrollLeft):
(WebCore::Element::setScrollTop):

Canonical link: https://commits.webkit.org/250083@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293569 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/dom/Element.cpp




Diff

Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (295316 => 295317)

--- branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:09 UTC (rev 295316)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:12 UTC (rev 295317)
@@ -1,5 +1,16 @@
 2022-04-28  Alex Christensen  
 
+Use more smart pointers in Element.cpp
+https://bugs.webkit.org/show_bug.cgi?id=239836
+
+Reviewed by Chris Dumez.
+
+* dom/Element.cpp:
+(WebCore::Element::setScrollLeft):
+(WebCore::Element::setScrollTop):
+
+2022-04-28  Alex Christensen  
+
 afterprint event should be scheduled on event loop
 https://bugs.webkit.org/show_bug.cgi?id=239883
 


Modified: branches/safari-613-branch/Source/WebCore/dom/Element.cpp (295316 => 295317)

--- branches/safari-613-branch/Source/WebCore/dom/Element.cpp	2022-06-07 02:30:09 UTC (rev 295316)
+++ branches/safari-613-branch/Source/WebCore/dom/Element.cpp	2022-06-07 02:30:12 UTC (rev 295317)
@@ -1458,7 +1458,7 @@
 options.animated = useSmoothScrolling(ScrollBehavior::Auto, this) ? ScrollIsAnimated::Yes : ScrollIsAnimated::No;
 
 if (document().scrollingElement() == this) {
-if (auto* frame = documentFrameWithNonNullView()) {
+if (RefPtr frame = documentFrameWithNonNullView()) {
 IntPoint position(static_cast(newLeft * frame->pageZoomFactor() * frame->frameScaleFactor()), frame->view()->scrollY());
 frame->view()->setScrollPosition(position, options);
 }
@@ -1465,10 +1465,10 @@
 return;
 }
 
-if (auto* renderer = renderBox()) {
+if (WeakPtr renderer = renderBox()) {
 int clampedLeft = clampToInteger(newLeft * renderer->style().effectiveZoom());
 renderer->setScrollLeft(clampedLeft, options);
-if (auto* scrollableArea = renderer->layer() ? renderer->layer()->scrollableArea() : nullptr)
+if (auto* scrollableArea = renderer && renderer->layer() ? renderer->layer()->scrollableArea() : nullptr)
 scrollableArea->setScrollShouldClearLatchedState(true);
 }
 }
@@ -1481,7 +1481,7 @@
 options.animated = useSmoothScrolling(ScrollBehavior::Auto, this) ? ScrollIsAnimated::Yes : ScrollIsAnimated::No;
 
 if (document().scrollingElement() == this) {
-if (auto* frame = documentFrameWithNonNullView()) {
+if (RefPtr frame = documentFrameWithNonNullView()) {
 IntPoint position(frame->view()->scrollX(), static_cast(newTop * frame->pageZoomFactor() * frame->frameScaleFactor()));
 frame->view()->setScrollPosition(position, options);
 }
@@ -1488,10 +1488,10 @@
 return;
 }
 
-if (auto* renderer = renderBox()) {
+if (WeakPtr renderer = renderBox()) {
 int clampedTop = clampToInteger(newTop * renderer->style().effectiveZoom());
 renderer->setScrollTop(clampedTop, options);
-if (auto* scrollableArea = renderer->layer() ? renderer->layer()->scrollableArea() : nullptr)
+if (auto* scrollableArea = renderer && renderer->layer() ? renderer->layer()->scrollableArea() : nullptr)
 scrollableArea->setScrollShouldClearLatchedState(true);
 }
 }






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295318] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295318] branches/safari-613-branch








Revision 295318
Author alanc...@apple.com
Date 2022-06-06 19:30:17 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 8a2d5954643f. rdar://problem/94467773

Calls to print can result in unresponsive print modal
https://bugs.webkit.org/show_bug.cgi?id=237940


Reviewed by Chris Dumez.

Source/WebKit:

Calls to print were hanging in the case of the client asynchronously
handling the completion handler passed to the delegate. To fix this
we can adjust all printing IPC to have the option
DispatchMessageEvenWhenWaitingForUnboundedSyncReply which allows IPC
messages when waiting for a sync reply in the case where the receiver
of the message is not guranteed to call the completion handler at the
end of the runloop.

* UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h:
* UIProcess/API/Cocoa/WKWebViewTesting.mm:
(-[WKWebView _computePagesForPrinting:completionHandler:]):
* UIProcess/WebPageProxy.cpp:
(WebKit::printingSendOptions):
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::print):

Tools:

Add API test. Adjust delegate naming in the PDF case to be more
specific so we can use the generic PrintUIDelegate name in the general
case.

* TestWebKitAPI/SourcesCocoa.txt:
* TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
* TestWebKitAPI/Tests/WebKitCocoa/WKPDFView.mm:
(TEST):
(-[PrintUIDelegate _webView:printFrame:pdfFirstPageSize:completionHandler:]): Deleted.
(-[PrintUIDelegate waitForPageSize]): Deleted.
(-[PrintUIDelegate lastPrintedFrame]): Deleted.
* TestWebKitAPI/Tests/WebKitCocoa/WKPrinting.mm: Added.
(-[PrintUIDelegate callBlockAsync:]):
(-[PrintUIDelegate _webView:printFrame:pdfFirstPageSize:completionHandler:]):
(-[PrintUIDelegate waitForPagination]):
(TEST):

Canonical link: https://commits.webkit.org/248540@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@291412 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/Source/WebKit/ChangeLog
branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h
branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewTesting.mm
branches/safari-613-branch/Source/WebKit/UIProcess/API/ios/WKWebViewPrivateForTestingIOS.h
branches/safari-613-branch/Source/WebKit/UIProcess/WebPageProxy.cpp
branches/safari-613-branch/Source/WebKit/WebProcess/WebCoreSupport/WebChromeClient.cpp
branches/safari-613-branch/Tools/ChangeLog
branches/safari-613-branch/Tools/TestWebKitAPI/SourcesCocoa.txt
branches/safari-613-branch/Tools/TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj
branches/safari-613-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/WKPDFView.mm


Added Paths

branches/safari-613-branch/Tools/TestWebKitAPI/Tests/WebKitCocoa/WKPrinting.mm




Diff

Modified: branches/safari-613-branch/Source/WebKit/ChangeLog (295317 => 295318)

--- branches/safari-613-branch/Source/WebKit/ChangeLog	2022-06-07 02:30:12 UTC (rev 295317)
+++ branches/safari-613-branch/Source/WebKit/ChangeLog	2022-06-07 02:30:17 UTC (rev 295318)
@@ -1,3 +1,27 @@
+2022-03-17  Kate Cheney  
+
+Calls to print can result in unresponsive print modal
+https://bugs.webkit.org/show_bug.cgi?id=237940
+
+
+Reviewed by Chris Dumez.
+
+Calls to print were hanging in the case of the client asynchronously
+handling the completion handler passed to the delegate. To fix this
+we can adjust all printing IPC to have the option
+DispatchMessageEvenWhenWaitingForUnboundedSyncReply which allows IPC
+messages when waiting for a sync reply in the case where the receiver
+of the message is not guranteed to call the completion handler at the
+end of the runloop.
+
+* UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h:
+* UIProcess/API/Cocoa/WKWebViewTesting.mm:
+(-[WKWebView _computePagesForPrinting:completionHandler:]):
+* UIProcess/WebPageProxy.cpp:
+(WebKit::printingSendOptions):
+* WebProcess/WebCoreSupport/WebChromeClient.cpp:
+(WebKit::WebChromeClient::print):
+
 2022-04-14  Wenson Hsieh  
 
 Unreviewed, fix the Catalyst build after r292888


Modified: branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h (295317 => 295318)

--- branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h	2022-06-07 02:30:12 UTC (rev 295317)
+++ branches/safari-613-branch/Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivateForTesting.h	2022-06-07 02:30:17 UTC (rev 295318)
@@ -118,6 +118,8 @@
 
 - (void)_isLayerTreeFrozenForTesting:(void (^)(BOOL frozen))completionHandler WK_API_AVAILABLE(macos(WK_MAC_TBA), ios(WK_IOS_TBA));
 
+- (void)_computePagesForPrinting:(_WKFrameHandle *)handle completionHandler:(void(^)(void))completionHandler 

[webkit-changes] [295314] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295314] branches/safari-613-branch








Revision 295314
Author alanc...@apple.com
Date 2022-06-06 19:30:00 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 0fe83157c4d9. rdar://problem/94467906

CSP: Fix mixing strict-dynamic and unsafe-inline policies
https://bugs.webkit.org/show_bug.cgi?id=239862

Reviewed by Kate Cheney.

Source/WebCore:

Test: http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html

* page/csp/ContentSecurityPolicyDirectiveList.cpp:
(WebCore::ContentSecurityPolicyDirectiveList::violatedDirectiveForNonParserInsertedScripts const):

LayoutTests:

If you had multiple policies, one including strict-dynamic and another with unsafe-inline, the unsafe-inline
policy was incorrectly handled.

* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies-expected.txt: Added.
* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html: Added.

Canonical link: https://commits.webkit.org/250109@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293603 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/ChangeLog
branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/page/csp/ContentSecurityPolicyDirectiveList.cpp


Added Paths

branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies-expected.txt
branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html




Diff

Modified: branches/safari-613-branch/LayoutTests/ChangeLog (295313 => 295314)

--- branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 01:32:27 UTC (rev 295313)
+++ branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 02:30:00 UTC (rev 295314)
@@ -1,3 +1,16 @@
+2022-04-28  Patrick Griffis  
+
+CSP: Fix mixing strict-dynamic and unsafe-inline policies
+https://bugs.webkit.org/show_bug.cgi?id=239862
+
+Reviewed by Kate Cheney.
+
+If you had multiple policies, one including strict-dynamic and another with unsafe-inline, the unsafe-inline
+policy was incorrectly handled.
+
+* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies-expected.txt: Added.
+* http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html: Added.
+
 2022-05-03  Antti Koivisto  
 
 [CSS Cascade Layers] Endless recursion with revert-layer in other tree context


Added: branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies-expected.txt (0 => 295314)

--- branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies-expected.txt	(rev 0)
+++ branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies-expected.txt	2022-06-07 02:30:00 UTC (rev 295314)
@@ -0,0 +1,2 @@
+CONSOLE MESSAGE: allowed
+


Added: branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html (0 => 295314)

--- branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html	(rev 0)
+++ branches/safari-613-branch/LayoutTests/http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html	2022-06-07 02:30:00 UTC (rev 295314)
@@ -0,0 +1,17 @@
+
+
+  
+
+
+
+
+
+  if (window.testRunner) {
+testRunner.dumpAsText();
+  }
+
+  
+  
+console.log('allowed');
+  
+
\ No newline at end of file


Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (295313 => 295314)

--- branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 01:32:27 UTC (rev 295313)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:00 UTC (rev 295314)
@@ -1,3 +1,15 @@
+2022-04-28  Patrick Griffis  
+
+CSP: Fix mixing strict-dynamic and unsafe-inline policies
+https://bugs.webkit.org/show_bug.cgi?id=239862
+
+Reviewed by Kate Cheney.
+
+Test: http/tests/security/contentSecurityPolicy/script-src-strict-dynamic-and-unsafe-inline-policies.html
+
+* page/csp/ContentSecurityPolicyDirectiveList.cpp:
+(WebCore::ContentSecurityPolicyDirectiveList::violatedDirectiveForNonParserInsertedScripts const):
+
 2022-05-03  Antti Koivisto  
 
 [CSS Cascade Layers] Endless recursion with revert-layer in other tree context


Modified: 

[webkit-changes] [295315] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295315] branches/safari-613-branch








Revision 295315
Author alanc...@apple.com
Date 2022-06-06 19:30:06 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 2c80da108c11. rdar://problem/84667910

[iOS] Keyboard obscures file upload context menu when trying to attach a file in gmail.com
https://bugs.webkit.org/show_bug.cgi?id=241320
rdar://84667910

Reviewed by Tim Horton.

When composing a message on gmail.com, if a user taps the "Attach file" button in the bottom
toolbar, Gmail's script programmatically clicks a hidden file input and then immediately focuses the
editable body field. The context menu presents at the interaction location near the bottom of the
viewport; however, if no hardware keyboard is attached, the software keyboard appears right
afterwards, obscuring the context menu completely.

To address this, teach `WKFileUploadPanel` to reposition its context menu when the keyboard is
shown, if it might overlap with the bounds of the input view.

* LayoutTests/fast/forms/ios/show-file-upload-context-menu-above-keyboard-expected.txt: Added.
* LayoutTests/fast/forms/ios/show-file-upload-context-menu-above-keyboard.html: Added.

Add a layout test to verify that focusing a text field with the software keyboard while presenting a
file picker doesn't result in the file picker's context menu being obscured behind the keyboard.

* LayoutTests/resources/ui-helper.js:
(window.UIHelper.dismissMenu):
(window.UIHelper.contextMenuRect):

Add a couple of new UIHelper methods.

* Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _keyboardDidShow]):

If the keyboard appears while the file upload panel is active, reposition the context menu if it
overlaps with the new keyboard bounds.

(-[WKContentView _zoomToFocusRectAfterShowingKeyboardIfNeeded]):

Factor this existing logic out into a helper method.

* Source/WebKit/UIProcess/ios/forms/WKFileUploadPanel.h:
* Source/WebKit/UIProcess/ios/forms/WKFileUploadPanel.mm:
(-[WKFileUploadPanel contextMenuInteraction:willEndForConfiguration:animator:]):

If the `_isRepositioningContextMenu` flag is set, avoid removing and destroying the context menu
interaction.

(-[WKFileUploadPanel ensureContextMenuInteraction]):

Drive-by fix: adjust `-ensureContextMenuInteraction` so that it returns the either the existing or
newly created context menu interaction.

(-[WKFileUploadPanel repositionContextMenuIfNeeded]):

Add a helper method to reposition the context menu by removing and re-presenting the context menu
interaction without animation, only if it overlaps the input view bounds. While removing and
presenting the context menu again, set a `_isRepositioningContextMenu` flag, such that

(-[WKFileUploadPanel showDocumentPickerMenu]):
* Tools/TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl:
* Tools/TestRunnerShared/UIScriptContext/UIScriptController.h:
(WTR::UIScriptController::contextMenuRect const):
* Tools/WebKitTestRunner/cocoa/TestRunnerWKWebView.mm:
(-[TestRunnerWKWebView _dismissAllContextMenuInteractions]):

Adjust this helper to immediately cancel all context menu interactions without animation, so that
context menu removal delegate methods don't bleed into subsequent tests.

* Tools/WebKitTestRunner/ios/UIScriptControllerIOS.h:
* Tools/WebKitTestRunner/ios/UIScriptControllerIOS.mm:
(WTR::UIScriptControllerIOS::menuRect const):

Use the new `toObject` helper method.

(WTR::UIScriptControllerIOS::contextMenuRect const):

Add support for a new script controller method to return the context menu container view's bounds
in window coordinates. Note that I'm using window coordinates here as opposed to root view
coordinates, since the new test that uses this method needs to compare the context menu's position
against the input view bounds in window coordinates.

(WTR::UIScriptControllerIOS::toObject const):

Add a helper method to convert the given `CGRect` into a _javascript_ object reference.

Canonical link: https://commits.webkit.org/251344@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295299 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/resources/ui-helper.js
branches/safari-613-branch/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
branches/safari-613-branch/Source/WebKit/UIProcess/ios/forms/WKFileUploadPanel.h
branches/safari-613-branch/Source/WebKit/UIProcess/ios/forms/WKFileUploadPanel.mm
branches/safari-613-branch/Tools/TestRunnerShared/UIScriptContext/Bindings/UIScriptController.idl
branches/safari-613-branch/Tools/TestRunnerShared/UIScriptContext/UIScriptController.h
branches/safari-613-branch/Tools/WebKitTestRunner/cocoa/TestRunnerWKWebView.mm

[webkit-changes] [295316] branches/safari-613-branch/Source/WebCore

2022-06-06 Thread alancoon
Title: [295316] branches/safari-613-branch/Source/WebCore








Revision 295316
Author alanc...@apple.com
Date 2022-06-06 19:30:09 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 694fbb13c1b6. rdar://problem/92081556

afterprint event should be scheduled on event loop
https://bugs.webkit.org/show_bug.cgi?id=239883

Patch by Alex Christensen  on 2022-04-28
Reviewed by Chris Dumez.

* page/Page.cpp:
(WebCore::dispatchPrintEvent):
(WebCore::Page::dispatchBeforePrintEvent):
(WebCore::Page::dispatchAfterPrintEvent):

Canonical link: https://commits.webkit.org/250112@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293606 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/page/Page.cpp




Diff

Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (295315 => 295316)

--- branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:06 UTC (rev 295315)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 02:30:09 UTC (rev 295316)
@@ -1,3 +1,15 @@
+2022-04-28  Alex Christensen  
+
+afterprint event should be scheduled on event loop
+https://bugs.webkit.org/show_bug.cgi?id=239883
+
+Reviewed by Chris Dumez.
+
+* page/Page.cpp:
+(WebCore::dispatchPrintEvent):
+(WebCore::Page::dispatchBeforePrintEvent):
+(WebCore::Page::dispatchAfterPrintEvent):
+
 2022-04-28  Patrick Griffis  
 
 CSP: Fix mixing strict-dynamic and unsafe-inline policies


Modified: branches/safari-613-branch/Source/WebCore/page/Page.cpp (295315 => 295316)

--- branches/safari-613-branch/Source/WebCore/page/Page.cpp	2022-06-07 02:30:06 UTC (rev 295315)
+++ branches/safari-613-branch/Source/WebCore/page/Page.cpp	2022-06-07 02:30:09 UTC (rev 295316)
@@ -3518,7 +3518,8 @@
 }
 #endif // ENABLE(WHEEL_EVENT_LATCHING)
 
-static void dispatchPrintEvent(Frame& mainFrame, const AtomString& eventType)
+enum class DispatchedOnDocumentEventLoop : bool { No, Yes };
+static void dispatchPrintEvent(Frame& mainFrame, const AtomString& eventType, DispatchedOnDocumentEventLoop dispatchedOnDocumentEventLoop)
 {
 Vector> frames;
 for (auto* frame =  frame; frame = frame->tree().traverseNext())
@@ -3525,19 +3526,26 @@
 frames.append(*frame);
 
 for (auto& frame : frames) {
-if (auto* window = frame->window())
-window->dispatchEvent(Event::create(eventType, Event::CanBubble::No, Event::IsCancelable::No), window->document());
+if (RefPtr window = frame->window()) {
+auto dispatchEvent = [window = WTFMove(window), eventType] {
+window->dispatchEvent(Event::create(eventType, Event::CanBubble::No, Event::IsCancelable::No), window->document());
+};
+if (dispatchedOnDocumentEventLoop == DispatchedOnDocumentEventLoop::No)
+return dispatchEvent();
+if (auto* document = frame->document())
+document->eventLoop().queueTask(TaskSource::DOMManipulation, WTFMove(dispatchEvent));
+}
 }
 }
 
 void Page::dispatchBeforePrintEvent()
 {
-dispatchPrintEvent(m_mainFrame, eventNames().beforeprintEvent);
+dispatchPrintEvent(m_mainFrame, eventNames().beforeprintEvent, DispatchedOnDocumentEventLoop::No);
 }
 
 void Page::dispatchAfterPrintEvent()
 {
-dispatchPrintEvent(m_mainFrame, eventNames().afterprintEvent);
+dispatchPrintEvent(m_mainFrame, eventNames().afterprintEvent, DispatchedOnDocumentEventLoop::Yes);
 }
 
 #if ENABLE(APPLE_PAY)






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295313] branches/safari-7614.1.16-branch/Source/WebCore/accessibility/ AXObjectCache.h

2022-06-06 Thread alancoon
Title: [295313] branches/safari-7614.1.16-branch/Source/WebCore/accessibility/AXObjectCache.h








Revision 295313
Author alanc...@apple.com
Date 2022-06-06 18:32:27 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick r295165.

Unreviewed !ENABLE(ACCESSIBILITY) build fix for r295139.

* Source/WebCore/accessibility/AXObjectCache.h:
(WebCore::AXObjectCache::relatedObjectIDsFor):
(WebCore::AXObjectCache::relatedObjectsFor): Deleted.

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

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

Modified Paths

branches/safari-7614.1.16-branch/Source/WebCore/accessibility/AXObjectCache.h




Diff

Modified: branches/safari-7614.1.16-branch/Source/WebCore/accessibility/AXObjectCache.h (295312 => 295313)

--- branches/safari-7614.1.16-branch/Source/WebCore/accessibility/AXObjectCache.h	2022-06-07 01:27:14 UTC (rev 295312)
+++ branches/safari-7614.1.16-branch/Source/WebCore/accessibility/AXObjectCache.h	2022-06-07 01:32:27 UTC (rev 295313)
@@ -658,7 +658,7 @@
 inline void AXObjectCache::updateCacheAfterNodeIsAttached(Node*) { }
 inline void AXObjectCache::updateLoadingProgress(double) { }
 inline SimpleRange AXObjectCache::rangeForNodeContents(Node& node) { return makeRangeSelectingNodeContents(node); }
-inline std::optional> AXObjectCache::relatedObjectsFor(const AXCoreObject&, AXRelationType) { return std::nullopt; }
+inline std::optional> AXObjectCache::relatedObjectIDsFor(const AXCoreObject&, AXRelationType) { return std::nullopt; }
 inline void AXObjectCache::remove(AXID) { }
 inline void AXObjectCache::remove(RenderObject*) { }
 inline void AXObjectCache::remove(Node&) { }






___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295312] branches/safari-7614.1.16-branch/

2022-06-06 Thread alancoon
Title: [295312] branches/safari-7614.1.16-branch/








Revision 295312
Author alanc...@apple.com
Date 2022-06-06 18:27:14 -0700 (Mon, 06 Jun 2022)


Log Message
New branch.

Added Paths

branches/safari-7614.1.16-branch/




Diff




___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295311] tags/WebKit-7614.1.15.2/

2022-06-06 Thread alancoon
Title: [295311] tags/WebKit-7614.1.15.2/








Revision 295311
Author alanc...@apple.com
Date 2022-06-06 18:19:22 -0700 (Mon, 06 Jun 2022)


Log Message
Tag WebKit-7614.1.15.2.

Added Paths

tags/WebKit-7614.1.15.2/




Diff




___
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes


[webkit-changes] [295308] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295308] branches/safari-613-branch








Revision 295308
Author alanc...@apple.com
Date 2022-06-06 17:35:54 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 348b1a10ee87. rdar://problem/92449950

[CSS Cascade Layers] Endless recursion with revert-layer in other tree context
https://bugs.webkit.org/show_bug.cgi?id=239967


Reviewed by Alan Bujtas.

Source/WebCore:

We should only revert within a tree context (scope).

Adding more comprehensive WPTs separately.

Test: fast/css/revert-layer-tree-context-stack-overflow.html

* style/PropertyCascade.cpp:
(WebCore::Style::PropertyCascade::PropertyCascade):

Pass the property tree scope to the rollback cascade.

(WebCore::Style::PropertyCascade::addMatch):

Don't include properties from lower priority tree scopes to rollback cascade.
Reverse the logic for clarity.

* style/PropertyCascade.h:
(WebCore::Style::PropertyCascade::PropertyCascade):
* style/StyleBuilder.cpp:
(WebCore::Style::Builder::ensureRollbackCascadeForRevert):
(WebCore::Style::Builder::ensureRollbackCascadeForRevertLayer):
(WebCore::Style::Builder::makeRollbackCascadeKey):

Include tree scope to the key.

* style/StyleBuilder.h:

LayoutTests:

* fast/css/revert-layer-tree-context-stack-overflow-expected.html: Added.
* fast/css/revert-layer-tree-context-stack-overflow.html: Added.

Canonical link: https://commits.webkit.org/250213@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@293725 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/ChangeLog
branches/safari-613-branch/Source/WebCore/ChangeLog
branches/safari-613-branch/Source/WebCore/style/PropertyCascade.cpp
branches/safari-613-branch/Source/WebCore/style/PropertyCascade.h
branches/safari-613-branch/Source/WebCore/style/StyleBuilder.cpp
branches/safari-613-branch/Source/WebCore/style/StyleBuilder.h


Added Paths

branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow-expected.html
branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow.html




Diff

Modified: branches/safari-613-branch/LayoutTests/ChangeLog (295307 => 295308)

--- branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 00:35:49 UTC (rev 295307)
+++ branches/safari-613-branch/LayoutTests/ChangeLog	2022-06-07 00:35:54 UTC (rev 295308)
@@ -1,3 +1,14 @@
+2022-05-03  Antti Koivisto  
+
+[CSS Cascade Layers] Endless recursion with revert-layer in other tree context
+https://bugs.webkit.org/show_bug.cgi?id=239967
+
+
+Reviewed by Alan Bujtas.
+
+* fast/css/revert-layer-tree-context-stack-overflow-expected.html: Added.
+* fast/css/revert-layer-tree-context-stack-overflow.html: Added.
+
 2022-03-15  Gabriel Nava Marino  
 
 Crash in KeyframeList.cpp:183 in WebCore::KeyframeList::fillImplicitKeyframes


Added: branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow-expected.html (0 => 295308)

--- branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow-expected.html	(rev 0)
+++ branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow-expected.html	2022-06-07 00:35:54 UTC (rev 295308)
@@ -0,0 +1 @@
+


Added: branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow.html (0 => 295308)

--- branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow.html	(rev 0)
+++ branches/safari-613-branch/LayoutTests/fast/css/revert-layer-tree-context-stack-overflow.html	2022-06-07 00:35:54 UTC (rev 295308)
@@ -0,0 +1,6 @@
+
+  ::-webkit-input-placeholder {
+display: revert-layer;
+  }
+
+


Modified: branches/safari-613-branch/Source/WebCore/ChangeLog (295307 => 295308)

--- branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 00:35:49 UTC (rev 295307)
+++ branches/safari-613-branch/Source/WebCore/ChangeLog	2022-06-07 00:35:54 UTC (rev 295308)
@@ -1,3 +1,38 @@
+2022-05-03  Antti Koivisto  
+
+[CSS Cascade Layers] Endless recursion with revert-layer in other tree context
+https://bugs.webkit.org/show_bug.cgi?id=239967
+
+
+Reviewed by Alan Bujtas.
+
+We should only revert within a tree context (scope).
+
+Adding more comprehensive WPTs separately.
+
+Test: fast/css/revert-layer-tree-context-stack-overflow.html
+
+* style/PropertyCascade.cpp:
+(WebCore::Style::PropertyCascade::PropertyCascade):
+
+Pass the property tree scope to the rollback cascade.
+
+(WebCore::Style::PropertyCascade::addMatch):
+
+Don't include properties from lower priority tree scopes to rollback cascade.
+Reverse the logic for clarity.
+
+* style/PropertyCascade.h:
+

[webkit-changes] [295309] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295309] branches/safari-613-branch








Revision 295309
Author alanc...@apple.com
Date 2022-06-06 17:35:58 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick b8c770451902. rdar://problem/84570717

[Modern Media Controls] macCatalyst should not use touch events
https://bugs.webkit.org/show_bug.cgi?id=240704


Reviewed by Eric Carlson.

* Source/WebCore/Modules/modern-media-controls/controls/layout-traits.js:
(LayoutTraits.prototype.supportsTouches): Added.
* Source/WebCore/Modules/modern-media-controls/controls/macos-layout-traits.js:
(MacOSLayoutTraits.prototype.supportsTouches): Added.
Allow `LayoutTraits` to indicate whether touches are supported.

* Source/WebCore/Modules/modern-media-controls/controls/auto-hide-controller.js:
(AutoHideController):
* Source/WebCore/Modules/modern-media-controls/controls/button.js:
(Button):
* Source/WebCore/Modules/modern-media-controls/controls/range-button.js:
(RangeButton):
* Source/WebCore/Modules/modern-media-controls/controls/slider.js:
(Slider.prototype._interactionEndTarget):
* Source/WebCore/Modules/modern-media-controls/media/media-document-controller.js:
(MediaDocumentController):
Use `LayoutTraits.prototype.supportsTouches` instead of `GestureRecognizer.SupportsTouches` so that
macOS (including macCatalyst) can always act as though touches are not supported (which is fine
since mouse events are fully functional on macOS).

* LayoutTests/media/modern-media-controls/button/button-icon-name.html:
* LayoutTests/media/modern-media-controls/button/button.html:
* LayoutTests/media/modern-media-controls/buttons-container/buttons-container-buttons-property.html:
* LayoutTests/media/modern-media-controls/buttons-container/buttons-container-constructor.html:
* LayoutTests/media/modern-media-controls/buttons-container/buttons-container-layout.html:
Add `layoutDelegate`/`layoutTraits` where needed.

Canonical link: https://commits.webkit.org/250814@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@294573 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button-icon-name.html
branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button.html
branches/safari-613-branch/LayoutTests/media/modern-media-controls/buttons-container/buttons-container-buttons-property.html
branches/safari-613-branch/LayoutTests/media/modern-media-controls/buttons-container/buttons-container-constructor.html
branches/safari-613-branch/LayoutTests/media/modern-media-controls/buttons-container/buttons-container-layout.html
branches/safari-613-branch/Source/WebCore/Modules/modern-media-controls/controls/auto-hide-controller.js
branches/safari-613-branch/Source/WebCore/Modules/modern-media-controls/controls/button.js
branches/safari-613-branch/Source/WebCore/Modules/modern-media-controls/controls/layout-traits.js
branches/safari-613-branch/Source/WebCore/Modules/modern-media-controls/controls/macos-layout-traits.js
branches/safari-613-branch/Source/WebCore/Modules/modern-media-controls/controls/range-button.js
branches/safari-613-branch/Source/WebCore/Modules/modern-media-controls/media/media-document-controller.js




Diff

Modified: branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button-icon-name.html (295308 => 295309)

--- branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button-icon-name.html	2022-06-07 00:35:54 UTC (rev 295308)
+++ branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button-icon-name.html	2022-06-07 00:35:58 UTC (rev 295309)
@@ -8,7 +8,7 @@
 
 description("Testing the Button class iconName property.");
 
-const layoutDelegate = {};
+const layoutDelegate = { layoutTraits: new MacOSLayoutTraits(LayoutTraits.Mode.Inline) };
 
 const button = new Button({ layoutDelegate });
 
@@ -18,6 +18,7 @@
 
 debug("");
 debug("Setting an iconName with invalid layout traits should throw");
+layoutDelegate.layoutTraits = null;
 shouldThrow(function() { button.iconName = Icons.Pause });
 shouldBeEqualToString("button.iconName", "");
 


Modified: branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button.html (295308 => 295309)

--- branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button.html	2022-06-07 00:35:54 UTC (rev 295308)
+++ branches/safari-613-branch/LayoutTests/media/modern-media-controls/button/button.html	2022-06-07 00:35:58 UTC (rev 295309)
@@ -17,7 +17,9 @@
 
 description("Testing the Button class.");
 
-const button = new Button;
+const layoutDelegate = { layoutTraits: new MacOSLayoutTraits(LayoutTraits.Mode.Inline) };
+
+const button = new Button({ layoutDelegate });
 document.body.appendChild(button.element);
 
 debug("Default values");


Modified: 

[webkit-changes] [295307] branches/safari-613-branch

2022-06-06 Thread alancoon
Title: [295307] branches/safari-613-branch








Revision 295307
Author alanc...@apple.com
Date 2022-06-06 17:35:49 -0700 (Mon, 06 Jun 2022)


Log Message
Cherry-pick 077f4d227924. rdar://problem/94034984

AX: inert attribute doesn't cause display:contents element to be ignored
https://bugs.webkit.org/show_bug.cgi?id=241022

Reviewed by Chris Fleizach.

Prior to this patch, the inert attribute didn't cause node-only objects
(like those with display:contents) to be ignored. This was because
AccessibilityObject::defaultObjectInclusion only checked `effectiveInert`
for elements with renderers, even though you only need an element to
have style (not a renderer).

This patch fixes this by adding a new AccessibilityObject::style()
method which uses AccessibilityObject::element() to get
Element::computedStyle() and checking effectiveInert on that, which
works for both renderer and renderer-less objects.

* LayoutTests/accessibility/node-only-inert-object-expected.txt: Added.
* LayoutTests/accessibility/node-only-inert-object.html: Added.
* LayoutTests/platform/ios/TestExpectations: Enable new test.
* LayoutTests/platform/mac-wk1/TestExpectations: Skip new test.
* Source/WebCore/accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::style const): Added.
(WebCore::AccessibilityObject::defaultObjectInclusion const):
* Source/WebCore/accessibility/AccessibilityObject.h:

Canonical link: https://commits.webkit.org/251185@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295090 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

branches/safari-613-branch/LayoutTests/platform/ios/TestExpectations
branches/safari-613-branch/LayoutTests/platform/mac-wk1/TestExpectations
branches/safari-613-branch/LayoutTests/platform/win/TestExpectations
branches/safari-613-branch/Source/WebCore/accessibility/AccessibilityObject.cpp
branches/safari-613-branch/Source/WebCore/accessibility/AccessibilityObject.h


Added Paths

branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object-expected.txt
branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object.html




Diff

Added: branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object-expected.txt (0 => 295307)

--- branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object-expected.txt	(rev 0)
+++ branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object-expected.txt	2022-06-07 00:35:49 UTC (rev 295307)
@@ -0,0 +1,11 @@
+This test ensures that a node-only object (e.g. one with display:contents) that is inert is ignored.
+
+PASS: accessibilityController.accessibleElementById('button') === null
+
+Removing inert from #button
+PASS: accessibilityController.accessibleElementById('button').role.includes('Button') === true
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+Click me


Added: branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object.html (0 => 295307)

--- branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object.html	(rev 0)
+++ branches/safari-613-branch/LayoutTests/accessibility/node-only-inert-object.html	2022-06-07 00:35:49 UTC (rev 295307)
@@ -0,0 +1,31 @@
+
+
+
+
+
+
+
+
+