Bug 1317856 - Make the Flash plugin Click-to-Activate by default on Nightly. r=bsmedberg
This also activates the Favor fallback mode to give preference for HTML <video> content over Flash objects, and to not load Flash when the page has not speficied a src url (as the data attribute).
MozReview-Commit-ID: Lo4eWGbWyOt
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -669,23 +669,32 @@ pref("accessibility.loadedInLastSession"
pref("plugins.click_to_play", true);
pref("plugins.testmode", false);
pref("plugin.default.state", 1);
// Plugins bundled in XPIs are enabled by default.
pref("plugin.defaultXpi.state", 2);
-// Flash is enabled by default, and Java is click-to-activate by default on
-// all channels.
-pref("plugin.state.flash", 2);
+// Java is Click-to-Activate by default on all channels.
pref("plugin.state.java", 1);
+// Flash is Click-to-Activate by default on Nightly,
+// Always-Activate on other channels.
#ifdef NIGHTLY_BUILD
pref("plugins.flashBlock.enabled", true);
+pref("plugin.state.flash", 1);
+
+// Prefer HTML5 video over Flash content, and don't
+// load plugin instances with no src declared.
+// These prefs are documented in details on all.js.
+pref("plugins.favorfallback.mode", "follow-ctp");
+pref("plugins.favorfallback.rules", "nosrc,video");
+#else
+pref("plugin.state.flash", 2);
#endif
#ifdef XP_WIN
pref("browser.preferences.instantApply", false);
#else
pref("browser.preferences.instantApply", true);
#endif
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -3003,22 +3003,20 @@ pref("idle_queue.min_period", 3);
// (0 is disabled)
// Disabled on all platforms per bug 705748 until the found issues are
// resolved.
pref("hangmonitor.timeout", 0);
pref("plugins.load_appdir_plugins", false);
// If true, plugins will be click to play
pref("plugins.click_to_play", false);
-#ifdef NIGHTLY_BUILD
+
// This only supports one hidden ctp plugin, edit nsPluginArray.cpp if adding a second
-pref("plugins.navigator.hidden_ctp_plugin", "Shockwave Flash");
-#else
pref("plugins.navigator.hidden_ctp_plugin", "");
-#endif
+
// The default value for nsIPluginTag.enabledState (STATE_ENABLED = 2)
pref("plugin.default.state", 2);
// The MIME type that should bind to legacy java-specific invocations like
// <applet> and <object data="java:foo">. Setting this to a non-java MIME type
// is undefined behavior.
pref("plugin.java.mime", "application/x-java-vm");