Bug 1164178 - Use an empty value by default for lightweightThemes.selectedThemeID;r=dao

This commit is contained in:
Brian Grinstead 2015-05-14 18:31:21 -07:00
Родитель 58d31221f5
Коммит 547df33bde
3 изменённых файлов: 4 добавлений и 2 удалений

Просмотреть файл

@ -1332,6 +1332,8 @@ pref("services.sync.prefs.sync.xpinstall.whitelist.required", true);
#ifdef MOZ_DEV_EDITION #ifdef MOZ_DEV_EDITION
sticky_pref("lightweightThemes.selectedThemeID", "firefox-devedition@mozilla.org"); sticky_pref("lightweightThemes.selectedThemeID", "firefox-devedition@mozilla.org");
sticky_pref("browser.devedition.theme.enabled", true); sticky_pref("browser.devedition.theme.enabled", true);
#else
sticky_pref("lightweightThemes.selectedThemeID", "");
#endif #endif
// Developer edition promo preferences // Developer edition promo preferences

Просмотреть файл

@ -51,7 +51,7 @@ add_task(function () {
let defaultTheme = header.nextSibling; let defaultTheme = header.nextSibling;
defaultTheme.doCommand(); defaultTheme.doCommand();
is(Services.prefs.prefHasUserValue("lightweightThemes.selectedThemeID"), false, "No lwtheme should be selected"); is(Services.prefs.getCharPref("lightweightThemes.selectedThemeID"), "", "No lwtheme should be selected");
}); });
add_task(function asyncCleanup() { add_task(function asyncCleanup() {

Просмотреть файл

@ -302,7 +302,7 @@ this.LightweightThemeManager = {
if (aData) if (aData)
_prefs.setCharPref("selectedThemeID", aData.id); _prefs.setCharPref("selectedThemeID", aData.id);
else else
_prefs.deleteBranch("selectedThemeID"); _prefs.setCharPref("selectedThemeID", "");
_notifyWindows(aData); _notifyWindows(aData);
Services.obs.notifyObservers(null, "lightweight-theme-changed", null); Services.obs.notifyObservers(null, "lightweight-theme-changed", null);