Stop creating nsFrameSelection with CreateInstance

RESOLVED FIXED in mozilla6

Status

()

defect
RESOLVED FIXED
8 years ago
8 years ago

People

(Reporter: craig.topper, Assigned: craig.topper)

Tracking

Trunk
mozilla6
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(3 attachments, 2 obsolete attachments)

nsFrameSelection is created in two places with createInstance. Both places are inside the layout module and can just create nsFrameSelection directly.

This removes the need to be able to create nsFrameSelection with createInstance. Then nsFrameSelection no longer needs an IID since there are no other QIs.
Attachment #533515 - Attachment is obsolete: true
Attachment #533517 - Flags: review?(roc)
Attachment #533537 - Flags: review?(roc)
Attachment #533539 - Flags: review?(roc)
Comment on attachment 533517 [details] [diff] [review]
Part 1: Changes nsCOMPtr<nsFrameSelection> to nsRefPtr.

Review of attachment 533517 [details] [diff] [review]:
-----------------------------------------------------------------
Attachment #533517 - Flags: review?(roc) → review+
Comment on attachment 533537 [details] [diff] [review]
Part 2: Don't use createInstance for nsFrameSelection.

Review of attachment 533537 [details] [diff] [review]:
-----------------------------------------------------------------
Attachment #533537 - Flags: review?(roc) → review+
Comment on attachment 533539 [details] [diff] [review]
Part 3: Remove nsFrameSelection QI and createInstance support.

Review of attachment 533539 [details] [diff] [review]:
-----------------------------------------------------------------
Attachment #533539 - Flags: review?(roc) → review+
Attachment #533539 - Attachment is obsolete: true
Comment on attachment 533891 [details] [diff] [review]
Part 3: Remove nsFrameSelection QI and createInstance support.

Somehow the nsLayoutCID.h change was applied against another patch in my tree. This version fixes that. Carrying forward r+
Attachment #533891 - Flags: review+
Keywords: checkin-needed
I love it. Does nsFrameSelection still need to inherit from nsISupports?
(In reply to comment #11)
> I love it. Does nsFrameSelection still need to inherit from nsISupports?

I don't think so.
I'll look into that and de-virtualizing its methods. Also going to remove the IID define I forgot to remove.
I think the cycle collecting stuff requires the nsISupports inheritance. :(
nevermind clearly i don't really understand cycle collecting.
Blocks: 658750
You need to log in before you can comment on or make changes to this bug.