Closed
Bug 629192
Opened 14 years ago
Closed 8 years ago
mozRequestAnimationFrame callbacks fire while a modal dialog is open
Categories
(Core :: DOM: Events, defect, P2)
Tracking
()
RESOLVED
FIXED
People
(Reporter: jamesr, Assigned: bzbarsky)
References
Details
User-Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:2.0b11pre) Gecko/20110126 Firefox/4.0b11pre
Build Identifier: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:2.0b11pre) Gecko/20110126 Firefox/4.0b11pre
mozRequestAnimationFrame callbacks will fire while a modal dialog (such as window.alert() is up, which violates javascript's general aversion to reentrancy. For example:
var startTime = Date.now();
window.mozRequestAnimationFrame(function(){window.endTime=Date.now();});
window.alert("hi");
if the user takes 2 seconds to dismiss the dialog, endTime-startTime should be >= 2000. Instead it's much shorter.
Reproducible: Always
Steps to Reproduce:
see script
The experimental WebKit implementation of requestAnimationFrame defers invoking the callback until the dialog is dismissed.
Assignee | ||
Comment 1•14 years ago
|
||
Hmm. I suppose we could do that, though of course declarative animations _do_ continue while the modal dialog is up...
Olli, is just checking EventHandlingSuppressed() on the document involved the right thing to do?
Assignee | ||
Updated•14 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 2•14 years ago
|
||
I'd check top windows modal state depth.
Assignee | ||
Comment 3•14 years ago
|
||
Talked to smaug. Sounds like we need to do both, actually.
We need to add a sane accessor for IsInModalState().
Assignee | ||
Updated•14 years ago
|
Assignee: nobody → bzbarsky
Priority: -- → P2
Comment 4•14 years ago
|
||
James, does webkit fire animation callbacks while there is a sync XHR being processed?
Comment 5•14 years ago
|
||
Apparently it does not.
Assignee | ||
Comment 6•8 years ago
|
||
Fixeed by bug 675121.
You need to log in
before you can comment on or make changes to this bug.
Description
•