Closed Bug 774556 Opened 8 years ago Closed 8 years ago

Remove nsIDOMWindowPerformance* XPCOM interfaces

Categories

(Core :: DOM: Core & HTML, defect)

x86
macOS
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla17

People

(Reporter: ehsan, Assigned: ehsan)

Details

(Keywords: dev-doc-needed)

Attachments

(1 file, 1 obsolete file)

This is a follow-up to bug 749101.  We don't have any native code which depends on these interfaces, so we should just kill them.
Attached patch Patch (v1) (obsolete) — Splinter Review
This patch removes these interfaces, but with it, window.performance returns undefined.  I guess that happens because nsIDOMWindow::GetPerformance now returns an nsISupports*.  Boris, do you know what I need to do in order to fix that?
Assignee: nobody → ehsan
Status: NEW → ASSIGNED
Attachment #642840 - Flags: feedback?(bzbarsky)
Comment on attachment 642840 [details] [diff] [review]
Patch (v1)

This looks fine in general.  The undefined bit is due to this change:

-  DOM_CLASSINFO_MAP_CONDITIONAL_ENTRY(nsIDOMWindowPerformance,                 \
-                                      nsGlobalWindow::HasPerformanceSupport()) \

which makes Window not implement that interface as far as script is concerned.  You should revert it that part.
Attachment #642840 - Flags: feedback?(bzbarsky) → feedback+
(In reply to comment #2)
> Comment on attachment 642840 [details] [diff] [review]
>   --> https://bugzilla.mozilla.org/attachment.cgi?id=642840
> Patch (v1)
> 
> This looks fine in general.  The undefined bit is due to this change:
> 
> -  DOM_CLASSINFO_MAP_CONDITIONAL_ENTRY(nsIDOMWindowPerformance,                
> \
> -                                      nsGlobalWindow::HasPerformanceSupport())
> \
> 
> which makes Window not implement that interface as far as script is concerned. 
> You should revert it that part.

I tried to put that part back in using nsISupports, but window.performance is still undefined...
(In reply to comment #2)
> Comment on attachment 642840 [details] [diff] [review]
>   --> https://bugzilla.mozilla.org/attachment.cgi?id=642840
> Patch (v1)
> 
> This looks fine in general.  The undefined bit is due to this change:
> 
> -  DOM_CLASSINFO_MAP_CONDITIONAL_ENTRY(nsIDOMWindowPerformance,                
> \
> -                                      nsGlobalWindow::HasPerformanceSupport())
> \
> 
> which makes Window not implement that interface as far as script is concerned. 
> You should revert it that part.

I tried to put that part back in using nsISupports, but window.performance is still undefined...
Just put it back exactly the way it was.  nsIDOMWindowPerformance is not one of the interfaces you're removing...
Keywords: dev-doc-needed
Attached patch Patch (v1)Splinter Review
Oops, you're right!
Attachment #642840 - Attachment is obsolete: true
Attachment #642859 - Flags: review?(bzbarsky)
Comment on attachment 642859 [details] [diff] [review]
Patch (v1)

It might not be a bad idea to put the constants in the mozilla::dom::PerformanceNavigation namespace or the nsPerformanceNavigation class or something.

r=me
Attachment #642859 - Flags: review?(bzbarsky) → review+
Done!

https://hg.mozilla.org/integration/mozilla-inbound/rev/b722257d15b3
Target Milestone: --- → mozilla17
https://hg.mozilla.org/mozilla-central/rev/b722257d15b3
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.