when upgrading, correct mail_notification_type if msg count type is 'new messages'

This commit is contained in:
foudfou 2012-03-02 11:11:47 +01:00
parent 803143a535
commit da2c98633b
1 changed files with 8 additions and 0 deletions

View File

@ -103,6 +103,7 @@ firetray.Handler = {
let welcome = function(ver) {
firetray.Handler.openTab(FIRETRAY_SPLASH_PAGE+"#"+ver);
firetray.Handler.tryEraseOldOptions();
firetray.Handler.correctMailNotificationType();
};
VersionChange.setInstallHook(welcome);
VersionChange.setUpgradeHook(welcome);
@ -340,6 +341,13 @@ firetray.Handler = {
}
},
correctMailNotificationType: function() {
if (firetray.Utils.prefService.getIntPref('message_count_type') ===
FIRETRAY_MESSAGE_COUNT_TYPE_NEW)
firetray.Utils.prefService.setIntPref('mail_notification_type',
FIRETRAY_NOTIFICATION_NEWMAIL_ICON);
},
quitApplication: function() {
try {
firetray.Utils.timer(function() {