Web Inspector: Timelines: don't show event dispatches for non-JS event listeners
https://bugs.webkit.org/show_bug.cgi?id=191902
Summary Web Inspector: Timelines: don't show event dispatches for non-JS event listeners
Devin Rousso
Reported 2018-11-21 19:05:56 PST
See <https://webkit.org/b/191625#c14> for an explanation of why this is needed. tl;dr, in the case of media events, we add event listeners to <audio> and <video> elements in C++, which are considered an event listener, meaning that the Timelines tab picks up on that and shows event dispatch records. We should only show event dispatch records for event listeners added by the page.
Attachments
Devin Rousso
Comment 1 2018-11-21 22:56:17 PST
Looking more into this, it appears that we show all activity for the media controls (and theoretically any other evaluated scripts added by WebKit), so this might need to be expanded to more than just event listeners. The more I've thought about it, the more I can see arguments both for and against including/showing this information. On one hand, it provides a more "accurate" view of what's happening on the page. On the other, there's nothing really that a developer can do (AFAIK) to disable/remove the media controls code, so showing in the timelines (it might even be confusing since it's code not written by the developer, so they may see it in the timelines and wonder where it came from). Not sure which approach is more "reasonable"/expected.
Note You need to log in before you can comment on or make changes to this bug.