Redesign nsIFolderListener to use specific types rather than nsISupports
Categories
(MailNews Core :: General, task)
Tracking
(thunderbird_esr91 wontfix)
Tracking | Status | |
---|---|---|
thunderbird_esr91 | --- | wontfix |
People
(Reporter: benc, Assigned: benc)
References
(Blocks 1 open bug)
Details
(Keywords: leave-open)
Attachments
(4 files)
nsIFolderListener OnItemAdded()
and OnItemRemoved()
both pass the subject item as nsISupports*
. Looking through the code, it seems it's always either a message (nsIMsgDbHdr) or a folder (nsIMsgFolder), so probably easiest to just split it up into onFolderAdded/onFolderRemoved/onMessageAdded/onMessageRemoved().
And, I guess, lowercase the method names while we're at it?
https://searchfox.org/comm-central/source/mailnews/base/public/nsIFolderListener.idl
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Comment 1•3 years ago
|
||
Removes .NotifyItemAdded() and .NotifyItemRemoved() which both used nsISupports
and replaces them with specific folder and nsIMsgDBHdr versions.
Still calls the nsISupports-based nsIFolderListener OnItemAdded/OnItemRemoved()
callbacks but lays the groundwork for doing the same thing there.
Assignee | ||
Comment 2•3 years ago
|
||
Breaks up OnItemAdded() and OnItemRemoved() into folder and message-specific
versions. Also lowercases the callback functions in the .idl while we're here
e.g. OnItemEvent() becomes onItemEvent().
Depends on D126579
Assignee | ||
Updated•3 years ago
|
Updated•3 years ago
|
Pushed by mkmelin@iki.fi:
https://hg.mozilla.org/comm-central/rev/1b9c89f7af3b
Remove nsISupport use in nsIMsgFolder.NotifyItemAdded/NotifyItemRemoved. r=mkmelin
https://hg.mozilla.org/comm-central/rev/89021f52292d
Remove nsISupport use in nsIFolderListener.OnItemAdded/Removed callbacks. r=mkmelin
Comment 4•3 years ago
|
||
Assignee | ||
Comment 5•3 years ago
|
||
Gaah - I ran tests locally and did a try build and everything!
https://treeherder.mozilla.org/jobs?repo=try-comm-central&revision=bf25eccea93426b114510be74cffd37f0fb61b5e
But I figured out what I screwed up - I had uncommitted fixes when I did my magic "empty" push to kick of the try run, so the try run included them and it worked (and then my "hg qpop && hg qdelete try" helpfully threw them all away again)...
Sorry about that. Should have done the function renaming in a separate patch.
Pushed by mkmelin@iki.fi: https://hg.mozilla.org/comm-central/rev/c59b95ce556f Remove nsISupport use in nsIFolderListener.OnItemAdded/Removed callbacks. r=mkmelin
Comment 7•2 years ago
|
||
This change seems to be causing an error on tests that create folders. Does not seem to affect the tests completing because its usually triggered in the cleanup function. It does add noise to debugging actual failures though.
https://treeherder.mozilla.org/logviewer?job_id=357745269&repo=comm-central&lineNumber=3458
Comment 8•2 years ago
|
||
Comment 10•2 years ago
|
||
Pushed by mkmelin@iki.fi: https://hg.mozilla.org/comm-central/rev/ee483e7bc11c Follow up - when logging do not assume all folders have a parent. r=mkmelin
Description
•