Bug 1271483 - p1. Optionally treat media.wmf.disabled as WMF failure for Decoder Doctor - r=cpearce

This can be used to test Decoder Doctor on Windows, but disabling WMF through
prefs, to trigger an Decoder Doctor infobar.

MozReview-Commit-ID: 1aRk111VFO7
This commit is contained in:
Gerald Squelart 2016-05-24 01:33:37 +10:00
parent 3983e48e1d
commit 2c4f274202
3 changed files with 4 additions and 1 deletions

View File

@ -93,6 +93,7 @@ private:
#endif
#ifdef XP_WIN
DECL_MEDIA_PREF("media.wmf.enabled", PDMWMFEnabled, bool, true);
DECL_MEDIA_PREF("media.decoder-doctor.wmf-disabled-is-failure", DecoderDoctorWMFDisabledIsFailure, bool, false);
DECL_MEDIA_PREF("media.webm.intel_decoder.enabled", PDMWMFIntelDecoderEnabled, bool, false);
DECL_MEDIA_PREF("media.wmf.low-latency.enabled", PDMWMFLowLatencyEnabled, bool, false);
DECL_MEDIA_PREF("media.wmf.decoder.thread-count", PDMWMFThreadCount, int32_t, -1);

View File

@ -257,7 +257,7 @@ PDMFactory::CreatePDMs()
m = new WMFDecoderModule();
mWMFFailedToLoad = !StartupPDM(m);
} else {
mWMFFailedToLoad = false;
mWMFFailedToLoad = MediaPrefs::DecoderDoctorWMFDisabledIsFailure();
}
#endif
#ifdef MOZ_FFVPX

View File

@ -374,6 +374,8 @@ pref("media.gmp.storage.version.expected", 1);
pref("media.decoder-doctor.notifications-allowed", "MediaWMFNeeded,MediaWidevineNoWMFNoSilverlight");
// Whether we report partial failures.
pref("media.decoder-doctor.verbose", false);
// Whether DD should consider WMF-disabled a WMF failure, useful for testing.
pref("media.decoder-doctor.wmf-disabled-is-failure", false);
// Whether to suspend decoding of videos in background tabs.
#ifdef NIGHTLY_BUILD