Bug 1527811 - Hide OpenH264 by default on Windows on ARM. r=dminor,r=Gijs
authorChris Pearce <cpearce@mozilla.com>
Fri, 15 Feb 2019 13:25:38 +1300
changeset 461693 56d43815607853dacf7ae7d272912ef3e8927229
parent 461692 4afca6b3252ee9a327eaf3c2ecfdaaf432025621
child 461694 f7dc130bc082c84c77df9ed0d52fa0fa04488992
push id35626
push usercsabou@mozilla.com
push dateThu, 28 Feb 2019 11:31:08 +0000
treeherdermozilla-central@2ea0c1db7e60 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersdminor, Gijs
bugs1527811
milestone67.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1527811 - Hide OpenH264 by default on Windows on ARM. r=dminor,r=Gijs We don't have an aarch64 build of OpenH264 yet, and WebRTC on aarch64 is blocked by DirectShow support from MS, so just hide OpenH264 from the addons manager UI for now. We achieve this by moving the isEME() check in GMPUtils.isPluginHidden() down to after the isPluginSupported()||isPluginVisible() check, so we can use the media.gmp-gmpopenh264.visible pref to hide OpenH264 in the addons manager. When we are ready to enable WebRTC, we can flip the pref. Differential Revision: https://phabricator.services.mozilla.com/D19903
browser/app/profile/firefox.js
toolkit/modules/GMPUtils.jsm
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -1463,16 +1463,25 @@ pref("media.gmp.trial-create.enabled", t
 // to enable the CDM if its disabled; it's as if the keysystem is completely
 // unsupported.
 
 #ifdef MOZ_WIDEVINE_EME
 pref("media.gmp-widevinecdm.visible", true);
 pref("media.gmp-widevinecdm.enabled", true);
 #endif
 
+#if defined(_ARM64_) && defined(XP_WIN)
+// Windows on ARM64, OpenH264 not available yet.
+pref("media.gmp-gmpopenh264.visible", false);
+pref("media.gmp-gmpopenh264.enabled", false);
+#else
+// Not Windows on ARM64
+pref("media.gmp-gmpopenh264.visible", true);
+pref("media.gmp-gmpopenh264.enabled", true);
+#endif
 // Switch block autoplay logic to v2, and enable UI.
 pref("media.autoplay.enabled.user-gestures-needed", true);
 
 #ifdef NIGHTLY_BUILD
 // Set Firefox to block autoplay, asking for permission by default.
 pref("media.autoplay.default", 1); // 0=Allowed, 1=Blocked
 #else
 // Set Firefox to block autoplay, asking for permission by default.
--- a/toolkit/modules/GMPUtils.jsm
+++ b/toolkit/modules/GMPUtils.jsm
@@ -27,25 +27,26 @@ var GMPUtils = {
    *          The plugin to check.
    */
   isPluginHidden(aPlugin) {
     if (this._is32bitModeMacOS()) {
       // GMPs are hidden on MacOS when running in 32 bit mode.
       // See bug 1291537.
       return true;
     }
-    if (!aPlugin.isEME) {
-      return false;
-    }
 
     if (!this._isPluginSupported(aPlugin) ||
         !this._isPluginVisible(aPlugin)) {
       return true;
     }
 
+    if (!aPlugin.isEME) {
+      return false;
+    }
+
     if (!GMPPrefs.getBool(GMPPrefs.KEY_EME_ENABLED, true)) {
       return true;
     }
 
     return false;
   },
 
   /**