diff --git a/editor/ui/dialogs/content/EdSpellCheck.js b/editor/ui/dialogs/content/EdSpellCheck.js index f30f1d1409..57d6efc066 100644 --- a/editor/ui/dialogs/content/EdSpellCheck.js +++ b/editor/ui/dialogs/content/EdSpellCheck.js @@ -451,29 +451,17 @@ function EditDictionary() function SelectLanguage() { - try { - var item = gDialog.LanguageMenulist.selectedItem; - if (item.value != "more-cmd") { - gSpellChecker.SetCurrentDictionary(item.value); - gLastSelectedLang = item; - } - else { - openURL(getDictionaryURL()); - - if (gLastSelectedLang) - gDialog.LanguageMenulist.selectedItem = gLastSelectedLang; - } - } catch (ex) { - dump(ex); + var item = gDialog.LanguageMenulist.selectedItem; + if (item.value != "more-cmd") { + gSpellChecker.SetCurrentDictionary(item.value); + gLastSelectedLang = item; } -} + else { + openDictionaryList(); -function getDictionaryURL() -{ - var formatter = Components.classes["@mozilla.org/toolkit/URLFormatterService;1"] - .getService(Components.interfaces.nsIURLFormatter); - - return formatter.formatURLPref("spellchecker.dictionaries.download.url"); + if (gLastSelectedLang) + gDialog.LanguageMenulist.selectedItem = gLastSelectedLang; + } } function Recheck() diff --git a/suite/browser/navigator.js b/suite/browser/navigator.js index 79615f2e61..f3bd35cbda 100644 --- a/suite/browser/navigator.js +++ b/suite/browser/navigator.js @@ -2188,9 +2188,7 @@ function getNewThemes() { // get URL for more themes from prefs try { - var formatter = Components.classes["@mozilla.org/toolkit/URLFormatterService;1"] - .getService(Components.interfaces.nsIURLFormatter); - openTopWin(formatter.formatURLPref("extensions.getMoreThemesURL")); + openTopWin(Services.urlFormatter.formatURLPref("extensions.getMoreThemesURL")); } catch (ex) { dump(ex); diff --git a/suite/common/contentAreaContextOverlay.xul b/suite/common/contentAreaContextOverlay.xul index 6bc5d07774..0012b72b7c 100644 --- a/suite/common/contentAreaContextOverlay.xul +++ b/suite/common/contentAreaContextOverlay.xul @@ -315,7 +315,7 @@ + oncommand="openDictionaryList();"/> @@ -324,7 +324,7 @@ + oncommand="openDictionaryList();"/>