Title: [273427] branches/safari-612.1.5-branch
Revision
273427
Author
repst...@apple.com
Date
2021-02-24 12:32:37 -0800 (Wed, 24 Feb 2021)

Log Message

Cherry-pick r273424. rdar://problem/74708164

    Revert r272735. rdar://problem/74674837

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

Modified Paths

Diff

Modified: branches/safari-612.1.5-branch/Source/WebKit/ChangeLog (273426 => 273427)


--- branches/safari-612.1.5-branch/Source/WebKit/ChangeLog	2021-02-24 20:32:33 UTC (rev 273426)
+++ branches/safari-612.1.5-branch/Source/WebKit/ChangeLog	2021-02-24 20:32:37 UTC (rev 273427)
@@ -1,5 +1,17 @@
 2021-02-24  Russell Epstein  <repst...@apple.com>
 
+        Cherry-pick r273424. rdar://problem/74708164
+
+    Revert r272735. rdar://problem/74674837
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273424 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-02-24  Russell Epstein  <repst...@apple.com>
+
+            Revert r272735. rdar://problem/74674837
+
+2021-02-24  Russell Epstein  <repst...@apple.com>
+
         Cherry-pick r273423. rdar://problem/74708164
 
     Revert r272810. rdar://problem/74674837

Modified: branches/safari-612.1.5-branch/Source/WebKit/Shared/WebPreferencesDefaultValues.cpp (273426 => 273427)


--- branches/safari-612.1.5-branch/Source/WebKit/Shared/WebPreferencesDefaultValues.cpp	2021-02-24 20:32:33 UTC (rev 273426)
+++ branches/safari-612.1.5-branch/Source/WebKit/Shared/WebPreferencesDefaultValues.cpp	2021-02-24 20:32:37 UTC (rev 273427)
@@ -183,13 +183,15 @@
 
 bool defaultCaptureAudioInGPUProcessEnabled()
 {
+#if HAVE(SYSTEM_FEATURE_FLAGS)
 #if PLATFORM(MAC)
-    return true;
-#elif HAVE(SYSTEM_FEATURE_FLAGS)
+    return isFeatureFlagEnabled("gpu_process_webrtc");
+#elif PLATFORM(IOS_FAMILY)
     return isFeatureFlagEnabled("gpu_process_media");
-#else
+#endif
+#endif
+
     return false;
-#endif
 }
 
 bool defaultCaptureAudioInUIProcessEnabled()

Modified: branches/safari-612.1.5-branch/Source/WebKit/UIProcess/UserMediaPermissionRequestManagerProxy.cpp (273426 => 273427)


--- branches/safari-612.1.5-branch/Source/WebKit/UIProcess/UserMediaPermissionRequestManagerProxy.cpp	2021-02-24 20:32:33 UTC (rev 273426)
+++ branches/safari-612.1.5-branch/Source/WebKit/UIProcess/UserMediaPermissionRequestManagerProxy.cpp	2021-02-24 20:32:37 UTC (rev 273427)
@@ -239,13 +239,11 @@
 #if ENABLE(MEDIA_STREAM)
     ALWAYS_LOG(LOGIDENTIFIER, request.userMediaID(), ", video: ", request.videoDevice().label(), ", audio: ", request.audioDevice().label());
 
-    if (request.requestType() == MediaStreamRequest::Type::UserMedia)
-        m_grantedRequests.append(makeRef(request));
-
     if (auto callback = request.decisionCompletionHandler()) {
         m_page.willStartCapture(request, [callback = WTFMove(callback)]() mutable {
             callback(true);
         });
+        m_grantedRequests.append(makeRef(request));
         return;
     }
 
@@ -274,6 +272,11 @@
         if (!weakThis)
             return;
 
+        auto& request = strongRequest.get();
+
+        if (request.requestType() == MediaStreamRequest::Type::UserMedia)
+            m_grantedRequests.append(makeRef(request));
+
         // FIXME: m_hasFilteredDeviceList will trigger ondevicechange events for various documents from different origins.
         if (m_hasFilteredDeviceList)
             captureDevicesChanged(PermissionInfo::Granted);
@@ -289,7 +292,6 @@
         }
 #endif
 
-        auto& request = strongRequest.get();
         m_page.sendWithAsyncReply(Messages::WebPage::UserMediaAccessWasGranted { request.userMediaID(), request.audioDevice(), request.videoDevice(), request.deviceIdentifierHashSalt(), handle }, [this, weakThis = WTFMove(weakThis)] {
             if (!weakThis)
                 return;

Modified: branches/safari-612.1.5-branch/Tools/ChangeLog (273426 => 273427)


--- branches/safari-612.1.5-branch/Tools/ChangeLog	2021-02-24 20:32:33 UTC (rev 273426)
+++ branches/safari-612.1.5-branch/Tools/ChangeLog	2021-02-24 20:32:37 UTC (rev 273427)
@@ -1,3 +1,15 @@
+2021-02-24  Russell Epstein  <repst...@apple.com>
+
+        Cherry-pick r273424. rdar://problem/74708164
+
+    Revert r272735. rdar://problem/74674837
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@273424 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2021-02-24  Russell Epstein  <repst...@apple.com>
+
+            Revert r272735. rdar://problem/74674837
+
 2021-02-21  Andres Gonzalez  <andresg...@apple.com>
 
         Add [WebAccessibilityObjectWrapper textMarkerRangeForNSRange] to allow clients to efficiently get a TextMarkerRange from an NSRange.

Modified: branches/safari-612.1.5-branch/Tools/TestWebKitAPI/Tests/WebKit/GetUserMediaReprompt.mm (273426 => 273427)


--- branches/safari-612.1.5-branch/Tools/TestWebKitAPI/Tests/WebKit/GetUserMediaReprompt.mm	2021-02-24 20:32:33 UTC (rev 273426)
+++ branches/safari-612.1.5-branch/Tools/TestWebKitAPI/Tests/WebKit/GetUserMediaReprompt.mm	2021-02-24 20:32:37 UTC (rev 273427)
@@ -45,7 +45,7 @@
 @implementation GetUserMediaRepromptTestView
 - (BOOL)haveStream:(BOOL)expected
 {
-    int retryCount = 1000;
+    int retryCount = 10;
     while (retryCount--) {
         auto result = [self stringByEvaluatingJavaScript:@"haveStream()"];
         if (result.boolValue == expected)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to