Closed
Bug 1448992
Opened 7 years ago
Closed 5 years ago
Get rid of nsXPCComponentsBase
Categories
(Core :: XPConnect, enhancement, P2)
Core
XPConnect
Tracking
()
RESOLVED
FIXED
mozilla75
Tracking | Status | |
---|---|---|
firefox75 | --- | fixed |
People
(Reporter: bzbarsky, Assigned: bzbarsky)
References
Details
Attachments
(1 file, 1 obsolete file)
It's unused once bug 1389581 is fixed.
![]() |
Assignee | |
Comment 1•7 years ago
|
||
Attachment #8962506 -
Flags: review?(kmaglione+bmo)
![]() |
Assignee | |
Comment 2•7 years ago
|
||
Comment on attachment 8962506 [details] [diff] [review]
Get rid of nsXPCComponentsBase
This isn't right yet.
Attachment #8962506 -
Attachment is obsolete: true
Attachment #8962506 -
Flags: review?(kmaglione+bmo)
Updated•7 years ago
|
Priority: -- → P2
![]() |
Assignee | |
Comment 3•7 years ago
|
||
My patch for this makes layout/reftests/bugs/498228-1.xul fail.
The reason for that is that in toolkit/content/widgets/listbox.xml in the "control" getter of the "listitem" binding we have:
if (parent instanceof Ci.nsIDOMXULSelectControlElement)
and that throws with this patch (because there is no more Ci in the content XBL scope).
Brian, do we have a plan yet for those nsIDOMXUL* interfaces implemented via XBL implements=""?
Flags: needinfo?(bgrinstead)
Comment 4•7 years ago
|
||
(In reply to Boris Zbarsky [:bz] (no decent commit message means r-) from comment #3)
> My patch for this makes layout/reftests/bugs/498228-1.xul fail.
>
> The reason for that is that in toolkit/content/widgets/listbox.xml in the
> "control" getter of the "listitem" binding we have:
>
> if (parent instanceof Ci.nsIDOMXULSelectControlElement)
>
> and that throws with this patch (because there is no more Ci in the content
> XBL scope).
>
> Brian, do we have a plan yet for those nsIDOMXUL* interfaces implemented via
> XBL implements=""?
Yes, Neil is trying out two different approaches for [implements] in Bug 1446961. Forwarding ni? to see if they might work for nsIDOMXULSelectControlElement. I also wonder if in practice this getter is only ever called in certain scenarios, such that we could change the instanceof check into a tag name check or look for some own property like `getIndexOfItem` or something like that.
Flags: needinfo?(bgrinstead) → needinfo?(enndeakin)
Comment 5•7 years ago
|
||
This pattern looks to be used in a few other places, but is pretty infrequent overall: https://searchfox.org/mozilla-central/search?q=instanceof+Ci.&case=true&path=xml
Comment 6•7 years ago
|
||
In this case, the code could be changed to look for specific tags rather than the interface. Note also that the methods are inherited so it will need to deal with both listbox and richlistbox related tags.
Although the work in bug 1446961 could handle some specific cases, it won't be able to handle most of the interface usage. I think you will still have some cases where methods implemented in script will be needed.
Flags: needinfo?(enndeakin)
![]() |
Assignee | |
Comment 7•7 years ago
|
||
I know I can use specific tags here. I was trying to figure out whether there is something else that would be better based on what we plan to do to replace nsIDOMXULSelectControlElement.
Comment 8•7 years ago
|
||
I remember you mentioned that we can't right now have a Custom Element use QueryInterface: https://bugzilla.mozilla.org/show_bug.cgi?id=1404420#c15. Is that something that we could change to make `this.QueryInterface` work on DOM nodes, or store some metadata about the interface into the Custom Element registration? That would make migration easier.. but are there downsides to that approach?
Flags: needinfo?(bzbarsky)
![]() |
Assignee | |
Comment 9•6 years ago
|
||
Sorry, I had thought this was a self-needinfo...
Brian, is the question in comment 8 still relevant given our current plans for custom elements implementing interfaces?
Flags: needinfo?(bzbarsky) → needinfo?(bgrinstead)
Comment 10•6 years ago
|
||
(In reply to Boris Zbarsky [:bzbarsky, bz on IRC] from comment #9)
> Sorry, I had thought this was a self-needinfo...
>
> Brian, is the question in comment 8 still relevant given our current plans
> for custom elements implementing interfaces?
No, this is now possible as of Bug 1478372. Going to ship the first CE using this in Bug 1481949.
Flags: needinfo?(bgrinstead)
![]() |
Assignee | |
Comment 11•5 years ago
|
||
Comment 12•5 years ago
|
||
Pushed by bzbarsky@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/f6f02d0b050d
Get rid of nsXPCComponentsBase. r=bholley
Comment 13•5 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 5 years ago
status-firefox75:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla75
You need to log in
before you can comment on or make changes to this bug.
Description
•