Closed Bug 1391261 Opened 7 years ago Closed 3 years ago

Remove usage of wildcard "*" event listeners in devtools

Categories

(DevTools :: General, enhancement, P3)

enhancement

Tracking

(firefox57 wontfix, firefox99 fixed)

RESOLVED FIXED
99 Branch
Tracking Status
firefox57 --- wontfix
firefox99 --- fixed

People

(Reporter: jdescottes, Assigned: nchevobbe)

References

Details

(Whiteboard: [reserve-nosdk])

Attachments

(1 file)

The old SDK event emitter API allowed to listen to all events on a given target via the special "*" type. The call sites can be found with the two following queries: - http://searchfox.org/mozilla-central/search?q=on(%22*%22&case=false&regexp=false&path=devtools - http://searchfox.org/mozilla-central/search?q=on%5C(%5B%5E%2C%5D%2B%2C%5Cs*%22%5C*%22&case=false&regexp=true&path=devtools Currently the feature is used in the following files: - devtools/client/framework/toolbox.js - devtools/client/performance/performance-controller.js - devtools/client/webaudioeditor/models.js - devtools/client/webaudioeditor/views/context.js - devtools/server/actors/performance.js - devtools/server/actors/profiler.js - devtools/server/actors/timeline.js - devtools/server/performance/recorder.js - devtools/shared/fronts/profiler.js We are adding additional backward compatibility code to devtools/shared/event-emitter.js in order to support the feature while we are migrating out of using SDK APIs in devtools. Ultimately we should try to get rid of this feature. and remove the dedicated implementation in event-emitter.js
Forgot to add this non-blocking follow up to the no-sdk triage.
Whiteboard: [reserve-nosdk]
Product: Firefox → DevTools
Blocks: 1755682
Assignee: nobody → nchevobbe
Status: NEW → ASSIGNED

Callsites are updated to listen to individual events instead.

Depends on D139016

Pushed by nchevobbe@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/2d398eeb8841 [devtools] Remove support for wildcard in EventEmitter. r=jdescottes.
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 99 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: