Do not expose getDisplayMedia on Android by default
getDisplayMedia is not fully implemented on Android, throwing an Invalid
State error if the appropriate flags are not set. This change hides the
feature on Android so that JavaScript feature detection will work.
The earlier changes to runtime_enabled_features were not sufficient as
the RTCGetDisplayMedia feature *was* enabled by default. Since that
feature has been enabled for a long time now, this change removes it and
the kill-switch for getDisplayMedia for platforms other than Android.
In order to use the kUserMediaScreenCapturing feature which gates part
of the implementation of this feature, that feature is moved out of
chrome_feature_list, and into content_features so that it can be used
both by the underlying implementation, as well as to map the status of
the blink Runtime feature.
As a result, the existing kill-switch kRTCGetDisplayMedia
Bug: 1038244
Change-Id: Id8b0f053f992c2b85c1b32ad8e7c158f02fd8b22
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2503826
Commit-Queue: Alexander Cooper <[email protected]>
Reviewed-by: Guido Urdaneta <[email protected]>
Reviewed-by: Kinuko Yasuda <[email protected]>
Cr-Commit-Position: refs/heads/master@{#822324}
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc
index 8d180a60..a51a294 100644
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -4411,7 +4411,7 @@
{"screen-capture-android", flag_descriptions::kUserMediaScreenCapturingName,
flag_descriptions::kUserMediaScreenCapturingDescription, kOsAndroid,
- FEATURE_VALUE_TYPE(chrome::android::kUserMediaScreenCapturing)},
+ FEATURE_VALUE_TYPE(features::kUserMediaScreenCapturing)},
#endif
#if defined(OS_ANDROID)