Closed Bug 856478 Opened 11 years ago Closed 11 years ago

remove nsISupportsArray from mailnews/extensions/mailviews/src/nsMsgMailViewList.cpp

Categories

(MailNews Core :: Search, defect)

defect
Not set
trivial

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 23.0

People

(Reporter: aceman, Assigned: aceman)

References

Details

Attachments

(1 file, 2 obsolete files)

Defined as a variable in:

    mailnews/extensions/mailviews/src/nsMsgMailViewList.cpp (View Hg log or Hg annotations)
        line 139 -- m_mailViews->Count(aCount);
        line 151 -- m_mailViews->Count(&mailViewCount);
        line 154 -- return m_mailViews->QueryElementAt(aMailViewIndex, NS_GET_IID(nsIMsgMailView),
        line 163 -- m_mailViews->AppendElement(static_cast<nsISupports*>(aMailView));
        line 172 -- m_mailViews->RemoveElement(static_cast<nsISupports*>(aMailView));
        line 213 -- m_mailViews->Count(&mailViewCount); 
    mailnews/extensions/mailviews/src/nsMsgMailViewList.h (View Hg log or Hg annotations)
        line 49 -- nsCOMPtr<nsISupportsArray> m_mailViews; 

Referenced in:

    mailnews/extensions/mailviews/src/nsMsgMailViewList.cpp (View Hg log or Hg annotations)
        line 138 -- if (m_mailViews)
        line 148 -- NS_ENSURE_TRUE(m_mailViews, NS_ERROR_FAILURE);
        line 161 -- NS_ENSURE_TRUE(m_mailViews, NS_ERROR_FAILURE);
        line 170 -- NS_ENSURE_TRUE(m_mailViews, NS_ERROR_FAILURE);
        line 212 -- if (m_mailViews)
        line 274 -- ConvertFilterListToMailView(mFilterList, getter_AddRefs(m_mailViews));
Attached patch patch (obsolete) (deleted) — Splinter Review
Attachment #731722 - Flags: review?(neil)
Comment on attachment 731722 [details] [diff] [review]
patch

>     // now convert the filter list into our mail view objects, stripping out just the info we need
>-    ConvertFilterListToMailView(mFilterList, getter_AddRefs(m_mailViews));
>+    ConvertFilterListToMailView(mFilterList, &m_mailViews);
If this is the only caller, then we shouldn't be passing members (compare ConvertMailViewListToFilterList). [Failing that, my preference would have been to pass the nsCOMArray by reference.]
Attached patch patch v2 (obsolete) (deleted) — Splinter Review
Thanks.
Attachment #731722 - Attachment is obsolete: true
Attachment #731722 - Flags: review?(neil)
Attachment #732464 - Flags: review?(neil)
Comment on attachment 732464 [details] [diff] [review]
patch v2

[aFilterList could have become mFilterList too]
Attachment #732464 - Flags: review?(neil) → review+
Attached patch patch v3 (deleted) — Splinter Review
OK, done.
Attachment #732464 - Attachment is obsolete: true
Attachment #732506 - Flags: review+
Keywords: checkin-needed
https://hg.mozilla.org/comm-central/rev/bbdfb610ba02
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 23.0
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: