Closed Bug 1617919 Opened 5 years ago Closed 5 years ago

Check if setTimeout call is needed in HTMLTooltip#show

Categories

(DevTools :: Shared Components, task, P3)

task

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: nchevobbe, Unassigned)

References

Details

In the HTMLTooltip#show function, we're waiting for a tick (by calling setTimeout with an interval of 0) before setting some click handlers on the window and emitting the shown event.

From quick testing on my local OSX machine, doing the same thing directly, not in a setTimeout callback, does not seem to change anything.

We should check if there's an impact on other OSes. If not, the code can be changed; if there's an impact, we should add a comment explaining why this is needed.

it is needed : https://treeherder.mozilla.org/#/jobs?repo=try&revision=78a5988726fa97768d5991eaf04bf5f19512fd45
Our guess about the event listeners callback being called right away if the tooltip is shown from a click was right for Windows and Linux.
I'll add a comment before the setTimeout in the patch I'm currently working on.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.