Title: [222533] trunk/Source/WebKit
Revision
222533
Author
[email protected]
Date
2017-09-26 16:35:41 -0700 (Tue, 26 Sep 2017)

Log Message

[Cocoa] Add a modern WKPreferences switch to disable WebRTC
https://bugs.webkit.org/show_bug.cgi?id=176638
<rdar://problem/34335158>

Patch by Youenn Fablet <[email protected]> on 2017-09-26
Reviewed by Alex Christensen.

* UIProcess/API/Cocoa/WKPreferences.mm:
(-[WKPreferences _peerConnectionEnabled]):
(-[WKPreferences _setPeerConnectionEnabled:]):
* UIProcess/API/Cocoa/WKPreferencesPrivate.h:

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (222532 => 222533)


--- trunk/Source/WebKit/ChangeLog	2017-09-26 23:05:29 UTC (rev 222532)
+++ trunk/Source/WebKit/ChangeLog	2017-09-26 23:35:41 UTC (rev 222533)
@@ -1,3 +1,16 @@
+2017-09-26  Youenn Fablet  <[email protected]>
+
+        [Cocoa] Add a modern WKPreferences switch to disable WebRTC
+        https://bugs.webkit.org/show_bug.cgi?id=176638
+        <rdar://problem/34335158>
+
+        Reviewed by Alex Christensen.
+
+        * UIProcess/API/Cocoa/WKPreferences.mm:
+        (-[WKPreferences _peerConnectionEnabled]):
+        (-[WKPreferences _setPeerConnectionEnabled:]):
+        * UIProcess/API/Cocoa/WKPreferencesPrivate.h:
+
 2017-09-26  Brent Fulgham  <[email protected]>
 
         Harden our access to the vector of URL schemes.

Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm (222532 => 222533)


--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm	2017-09-26 23:05:29 UTC (rev 222532)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferences.mm	2017-09-26 23:35:41 UTC (rev 222533)
@@ -562,6 +562,16 @@
     _preferences->setLoadsImagesAutomatically(loadsImagesAutomatically);
 }
 
+- (BOOL)_peerConnectionEnabled
+{
+    return _preferences->peerConnectionEnabled();
+}
+
+- (void)_setPeerConnectionEnabled:(BOOL)enabled
+{
+    _preferences->setPeerConnectionEnabled(enabled);
+}
+
 - (BOOL)_mediaDevicesEnabled
 {
     return _preferences->mediaDevicesEnabled();

Modified: trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h (222532 => 222533)


--- trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h	2017-09-26 23:05:29 UTC (rev 222532)
+++ trunk/Source/WebKit/UIProcess/API/Cocoa/WKPreferencesPrivate.h	2017-09-26 23:35:41 UTC (rev 222533)
@@ -102,6 +102,7 @@
 
 @property (nonatomic, setter=_setLoadsImagesAutomatically:) BOOL _loadsImagesAutomatically WK_API_AVAILABLE(macosx(10.13), ios(11.0));
 
+@property (nonatomic, setter=_setPeerConnectionEnabled:) BOOL _peerConnectionEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
 @property (nonatomic, setter=_setMediaDevicesEnabled:) BOOL _mediaDevicesEnabled WK_API_AVAILABLE(macosx(10.13), ios(11.0));
 @property (nonatomic, setter=_setMockCaptureDevicesEnabled:) BOOL _mockCaptureDevicesEnabled WK_API_AVAILABLE(macosx(10.13), ios(11.0));
 @property (nonatomic, setter=_setMockCaptureDevicesPromptEnabled:) BOOL _mockCaptureDevicesPromptEnabled WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA));
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to