Merge pull request #3962 from henrikhorluck/fix/no-autoplay-mac

Disable audio autoplay on macOS
This commit is contained in:
Brent Simmons authored and GitHub committed 2023-05-13 12:27:24 -07:00
commit ca84a5d2f4
1 file changed
+1
@@ -90,6 +90,7 @@ protocol DetailWebViewControllerDelegate: AnyObject {
configuration.defaultWebpagePreferences = webpagePrefs
configuration.preferences = preferences
configuration.setURLSchemeHandler(detailIconSchemeHandler, forURLScheme: ArticleRenderer.imageIconScheme)
configuration.mediaTypesRequiringUserActionForPlayback = .audio
let userContentController = WKUserContentController()
userContentController.add(self, name: MessageName.windowDidScroll)