bug 369819 - Updates schema out-of-date error to include calendar app (Sb/Ln) name, rather than Tb. r1=ctalbert, r2=mvl, ui-r=mvl
git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@221411 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -37,6 +37,7 @@
|
||||
*
|
||||
* ***** END LICENSE BLOCK ***** */
|
||||
|
||||
const SUNBIRD_UID = "{718e30fb-e89b-41dd-9da7-e25a45638b28}";
|
||||
|
||||
const kStorageServiceContractID = "@mozilla.org/storage/service;1";
|
||||
const kStorageServiceIID = Components.interfaces.mozIStorageService;
|
||||
@@ -299,7 +300,19 @@ calCalendarManager.prototype = {
|
||||
var brandSb = sbs.createBundle("chrome://branding/locale/brand.properties");
|
||||
var calSb = sbs.createBundle("chrome://calendar/locale/calendar.properties");
|
||||
|
||||
var shortName = brandSb.GetStringFromName("brandShortName");
|
||||
var hostAppName = brandSb.GetStringFromName("brandShortName");
|
||||
|
||||
// If we're Lightning, we want to include the extension name
|
||||
// in the error message rather than blaming Thunderbird.
|
||||
var appInfo = Components.classes["@mozilla.org/xre/app-info;1"]
|
||||
.getService(Ci.nsIXULAppInfo);
|
||||
var calAppName;
|
||||
if (appInfo.ID == SUNBIRD_UID) {
|
||||
calAppName = hostAppName;
|
||||
} else {
|
||||
lightningSb = sbs.createBundle("chrome://lightning/locale/lightning.properties");
|
||||
calAppName = lightningSb.GetStringFromName("brandShortName");
|
||||
}
|
||||
|
||||
var promptSvc = Components.classes["@mozilla.org/embedcomp/prompt-service;1"]
|
||||
.getService(Components.interfaces.nsIPromptService);
|
||||
@@ -310,13 +323,13 @@ calCalendarManager.prototype = {
|
||||
|
||||
var choice = promptSvc.confirmEx(
|
||||
null,
|
||||
calSb.formatStringFromName("tooNewSchemaErrorTitle",
|
||||
[shortName], 1),
|
||||
calSb.formatStringFromName("tooNewSchemaErrorText",
|
||||
[shortName], 1),
|
||||
calSb.formatStringFromName("tooNewSchemaErrorBoxTitle",
|
||||
[calAppName], 1),
|
||||
calSb.formatStringFromName("tooNewSchemaErrorBoxText",
|
||||
[calAppName, hostAppName], 2),
|
||||
buttonFlags,
|
||||
calSb.formatStringFromName("tooNewSchemaButtonQuit",
|
||||
[shortName], 1),
|
||||
[hostAppName], 1),
|
||||
null, // No second button text
|
||||
null, // No third button text
|
||||
null, // No checkbox
|
||||
|
||||
@@ -94,8 +94,8 @@ None=None
|
||||
# Error strings
|
||||
## @name UID_NOT_FOUND
|
||||
## @loc none
|
||||
tooNewSchemaErrorTitle=Your data isn't compatible with this version of %1$S
|
||||
tooNewSchemaErrorText=The data in your profile was updated by a newer version of %1$S, and continuing will probably cause the information to be lost or corrupted. %1$S will now quit.
|
||||
tooNewSchemaErrorBoxTitle=Your calendar data isn't compatible with this version of %1$S
|
||||
tooNewSchemaErrorBoxText=The calendar data in your profile was updated by a newer version of %1$S, and continuing will probably cause the information to be lost or corrupted. %2$S will now quit.
|
||||
tooNewSchemaButtonQuit=Quit %1$S
|
||||
|
||||
# Editing repeating items strings
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
# Portions created by the Initial Developer are Copyright (C) 2006
|
||||
# the Initial Developer. All Rights Reserved.
|
||||
#
|
||||
# Contributor(s):
|
||||
# Contributor(s):
|
||||
# Matthew Willis <lilmatt@mozilla.com>
|
||||
#
|
||||
# Alternatively, the contents of this file may be used under the terms of
|
||||
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
||||
@@ -34,6 +35,9 @@
|
||||
#
|
||||
# ***** END LICENSE BLOCK *****
|
||||
|
||||
# Lightning branding
|
||||
brandShortName=Lightning
|
||||
|
||||
# Lightning specific strings
|
||||
|
||||
agendaToday=Today
|
||||
|
||||
Reference in New Issue
Block a user