Closed
Bug 465985
Opened 16 years ago
Closed 16 years ago
nsMessengerOSXIntegration registers for root folder changes twice
Categories
(MailNews Core :: Backend, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
Thunderbird 3.0b1
People
(Reporter: humph, Assigned: humph)
Details
Attachments
(1 file, 2 obsolete files)
1.73 KB,
patch
|
standard8
:
superreview+
|
Details | Diff | Splinter Review |
I've noticed that we get two BiffState notifications in the past, but as I was working on bug 465381 I saw that this is a more general problem. Here's nsMessengerOSXIntegration::Init() // because we care if the default server changes rv = accountManager->AddRootFolderListener(this); NS_ENSURE_SUCCESS(rv,rv); nsCOMPtr<nsIMsgMailSession> mailSession = do_GetService(NS_MSGMAILSESSION_CONTRACTID, &rv); NS_ENSURE_SUCCESS(rv,rv); // because we care if the unread total count changes return mailSession->AddFolderListener(this, nsIFolderListener::boolPropertyChanged | nsIFolderListener::intPropertyChanged); If I get rid of the call to accountManager->AddRootFolderListener(this), the problem goes away. I think this is the case because when we biff on a folder, we pass back the root folder vs. the inbox, therefore we don't lose anything by not getting ItemInt changes from the account/root itself. I notice that nsMessengerUnixIntegration doesn't have this duplication, but nsMessengerWinIntegration does, since you watch for the DefaultServerAtom in nsMessengerWinIntegration::OnItemBoolPropertyChanged. I favour ripping out the AddRootFolderListener call, since I currently don't care if the server changes. I'm not sure if I should, like Windows. Let me know and I'll do the patch.
Comment 1•16 years ago
|
||
On Windows, we do seem to care if the default server changes, because that causes us to do a bunch of things with registry keys where we store unread counts for the servers. I'm not sure why we care about the default server differently than we do for other servers, though. I don't think MacOSX integration cares, like you say, so I think we can rip that out.
Assignee | ||
Comment 2•16 years ago
|
||
Attachment #349273 -
Flags: superreview?(bugzilla)
Attachment #349273 -
Flags: review?(bienvenu)
Updated•16 years ago
|
Attachment #349273 -
Flags: review?(bienvenu) → review+
Comment 3•16 years ago
|
||
Comment on attachment 349273 [details] [diff] [review] Removes first root folder listener is it now the case that we don't have to include "nsIMsgAccountManager.h"?
Assignee | ||
Comment 4•16 years ago
|
||
Indeed, that can safely come out. Thanks for spotting that.
Attachment #349273 -
Attachment is obsolete: true
Attachment #349273 -
Flags: superreview?(bugzilla)
Assignee | ||
Comment 5•16 years ago
|
||
Sorry, left in a comment. This one is right.
Attachment #349337 -
Attachment is obsolete: true
Attachment #349338 -
Flags: superreview?(bugzilla)
Updated•16 years ago
|
Attachment #349338 -
Flags: superreview?(bugzilla) → superreview+
Comment 6•16 years ago
|
||
Checked in: http://hg.mozilla.org/comm-central/rev/06aafa6c4646
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 3.0b1
You need to log in
before you can comment on or make changes to this bug.
Description
•