Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Heads up: Removal of nsIDOMNSUIEvent, nsIDOMNSMouseEvent, nsIDOMNSEvent interfaces

13 views
Skip to first unread message

Ms2ger

unread,
Aug 24, 2011, 4:52:56 PM8/24/11
to
Hi all,

In our continuing effort to remove unnecessary interfaces, I'll be
removing nsIDOMNSUIEvent, nsIDOMNSMouseEvent, and nsIDOMNSEvent, and
moving their members into nsIDOMUIEvent, nsIDOMMouseEvent, and
nsIDOMEvent respectively. Note that, thanks to classinfo, it is not
necessary to QI to these interfaces when using them from script.

If I read MXR correctly, no changes to comm-central will be required.

You can follow along in bug 672054. [1]

Ms2ger

[1] https://bugzilla.mozilla.org/show_bug.cgi?id=672054

Benjamin Smedberg

unread,
Aug 25, 2011, 8:17:26 AM8/25/11
to Ms2ger, dev-pl...@lists.mozilla.org
On 8/24/2011 4:52 PM, Ms2ger wrote:
> Hi all,
>
> In our continuing effort to remove unnecessary interfaces, I'll be
> removing nsIDOMNSUIEvent, nsIDOMNSMouseEvent, and nsIDOMNSEvent, and
> moving their members into nsIDOMUIEvent, nsIDOMMouseEvent, and
> nsIDOMEvent respectively. Note that, thanks to classinfo, it is not
> necessary to QI to these interfaces when using them from script.
Have you checked extensions to see if this will cause incompatibilities?
I can't imagine that most extensions would be using these, since they
are automatically flattened, but we should check and perhaps keep a stub
name around just for compatibility if there are major issues.

--BDS

Christian Legnitto

unread,
Aug 25, 2011, 8:29:52 PM8/25/11
to Ms2ger, Benjamin Smedberg, dev-pl...@lists.mozilla.org
On Aug 25, 2011, at 5:17 AM, Benjamin Smedberg wrote:

> On 8/24/2011 4:52 PM, Ms2ger wrote:

>> Hi all,
>>
>> In our continuing effort to remove unnecessary interfaces, I'll be removing nsIDOMNSUIEvent, nsIDOMNSMouseEvent, and nsIDOMNSEvent, and moving their members into nsIDOMUIEvent, nsIDOMMouseEvent, and nsIDOMEvent respectively. Note that, thanks to classinfo, it is not necessary to QI to these interfaces when using them from script.

> Have you checked extensions to see if this will cause incompatibilities? I can't imagine that most extensions would be using these, since they are automatically flattened, but we should check and perhaps keep a stub name around just for compatibility if there are major issues.
>

Is it a big deal just keeping the stub name around? If not, let's just do it by default so we don't have to worry about the compat issue.

Thanks,
Christian

Jonas Sicking

unread,
Aug 25, 2011, 11:04:10 PM8/25/11
to Christian Legnitto, Benjamin Smedberg, Ms2ger, dev-pl...@lists.mozilla.org
On Thu, Aug 25, 2011 at 5:29 PM, Christian Legnitto
<cleg...@mozilla.com> wrote:
> On Aug 25, 2011, at 5:17 AM, Benjamin Smedberg wrote:
>
>> On 8/24/2011 4:52 PM, Ms2ger wrote:
>>> Hi all,
>>>
>>> In our continuing effort to remove unnecessary interfaces, I'll be removing nsIDOMNSUIEvent, nsIDOMNSMouseEvent, and nsIDOMNSEvent, and moving their members into nsIDOMUIEvent, nsIDOMMouseEvent, and nsIDOMEvent respectively. Note that, thanks to classinfo, it is not necessary to QI to these interfaces when using them from script.
>> Have you checked extensions to see if this will cause incompatibilities? I can't imagine that most extensions would be using these, since they are automatically flattened, but we should check and perhaps keep a stub name around just for compatibility if there are major issues.
>>
>
> Is it a big deal just keeping the stub name around? If not, let's just do it by default so we don't have to worry about the compat issue.

It would be a big deal to do that for all interfaces that we're
deprecating, yes. So some sort of migration strategy is needed.

Additionally, i'm not sure how much we increase the compatibility by
keeping empty interfaces around. Not very much I'd imagine. I could
see it hurting as much as helping if addons QI to interfaces and do
proper nullchecking.

/ Jonas

Benjamin Smedberg

unread,
Aug 26, 2011, 7:55:05 AM8/26/11
to Jonas Sicking, Ms2ger, dev-pl...@lists.mozilla.org, Christian Legnitto
On 8/25/2011 11:04 PM, Jonas Sicking wrote:
> It would be a big deal to do that for all interfaces that we're
> deprecating, yes. So some sort of migration strategy is needed.
Why? Is that because they are implemented with tearoffs?

>
> Additionally, i'm not sure how much we increase the compatibility by
> keeping empty interfaces around. Not very much I'd imagine. I could
> see it hurting as much as helping if addons QI to interfaces and do
> proper nullchecking.
Ignoring binary extensions, in the past we've seen patterns such as
obj.QueryInterface(nsIDOMWindowInternal) which we tried to remove. I
expect that we might see the same thing here: the JS code will still
work correctly as long as it doesn't throw because of a missing
interface name.

--BDS

Jonas Sicking

unread,
Aug 31, 2011, 11:15:51 PM8/31/11
to Benjamin Smedberg, Ms2ger, dev-pl...@lists.mozilla.org, Christian Legnitto
On Fri, Aug 26, 2011 at 4:55 AM, Benjamin Smedberg
<benj...@smedbergs.us> wrote:
> On 8/25/2011 11:04 PM, Jonas Sicking wrote:
>>
>> It would be a big deal to do that for all interfaces that we're
>> deprecating, yes. So some sort of migration strategy is needed.
>
> Why? Is that because they are implemented with tearoffs?

It's just going to leave too much cruft over time. I'm fine with
leaving things in for a few releases, but not indefinitely.

/ Jonas

0 new messages