Closed Bug 1223585 Opened 9 years ago Closed 9 years ago

Annotate ignoreEvent calls

Categories

(WebExtensions :: Untriaged, defect)

defect
Not set
normal

Tracking

(firefox45 fixed)

RESOLVED FIXED
mozilla45
Iteration:
45.1 - Nov 16
Tracking Status
firefox45 --- fixed

People

(Reporter: billm, Assigned: billm)

References

Details

Attachments

(2 files)

This reports something to the error console when an extension uses an event that's "implemented" using ignoreEvent.
Attachment #8685676 - Flags: review?(kmaglione+bmo)
This is useful for getting Ghostery to sort of run.
Attachment #8685679 - Flags: review?(kmaglione+bmo)
Attachment #8685676 - Attachment description: patch → annotate ignoreEvent
Attachment #8685679 - Attachment description: patch → add ignoreEvents for ghostery
Comment on attachment 8685676 [details] [diff] [review]
annotate ignoreEvent

Review of attachment 8685676 [details] [diff] [review]:
-----------------------------------------------------------------

::: toolkit/components/extensions/ExtensionUtils.jsm
@@ +249,5 @@
>  {
>    return {
> +    addListener: function(context, callback) {
> +      let id = context.extension.id;
> +      Cu.reportError(`In add-on ${id}, attempting to use listener "${name}", which is unimplemented.`);

It would be nice to have a filename/line number, if |Components.stack.caller| returns the right thing here.
Attachment #8685676 - Flags: review?(kmaglione+bmo) → review+
Attachment #8685679 - Flags: review?(kmaglione+bmo) → review+
https://hg.mozilla.org/mozilla-central/rev/00e0498e4200
https://hg.mozilla.org/mozilla-central/rev/be72540c9e57
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
Iteration: --- → 45.1 - Nov 16
Product: Toolkit → WebExtensions
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: