DescriptionMerge 78648 - 2011-02-15 James Robinson <jamesr@chromium.org>
Reviewed by Alexey Proskuryakov.
requestAnimationFrame callbacks should not fire within a modal dialog
https://bugs.webkit.org/show_bug.cgi?id=53188
Tests that requestAnimationFrame callbacks are suspended while a modal
dialog is showing.
* fast/animation/request-animation-frame-during-modal-expected.txt: Added.
* fast/animation/request-animation-frame-during-modal.html: Added.
2011-02-15 James Robinson <jamesr@chromium.org>
Reviewed by Alexey Proskuryakov.
requestAnimationFrame callbacks should not fire within a modal dialog
https://bugs.webkit.org/show_bug.cgi?id=53188
requestAnimationFrame callbacks shouldn't fire while a modal dialog is up (like a window.alert()).
This matches Firefox and other async APIs. This patch moves the callback servicing into its own
controller class which receives notifications on suspend/resume.
Test: fast/animation/request-animation-frame-during-modal.html
* WebCore.gypi:
* bindings/js/ScriptDebugServer.cpp:
(WebCore::ScriptDebugServer::setJavaScriptPaused):
* dom/Document.cpp:
(WebCore::Document::Document):
(WebCore::Document::suspendScriptedAnimationControllerCallbacks):
(WebCore::Document::resumeScriptedAnimationControllerCallbacks):
(WebCore::Document::webkitRequestAnimationFrame):
(WebCore::Document::webkitCancelRequestAnimationFrame):
(WebCore::Document::serviceScriptedAnimations):
* dom/Document.h:
* dom/ScriptExecutionContext.h:
(WebCore::ScriptExecutionContext::suspendScriptedAnimationControllerCallbacks):
(WebCore::ScriptExecutionContext::resumeScriptedAnimationControllerCallbacks):
* dom/ScriptedAnimationController.cpp: Added.
(WebCore::ScriptedAnimationController::ScriptedAnimationController):
(WebCore::ScriptedAnimationController::suspend):
(WebCore::ScriptedAnimationController::resume):
(WebCore::ScriptedAnimationController::registerCallback):
(WebCore::ScriptedAnimationController::cancelCallback):
(WebCore::ScriptedAnimationController::serviceScriptedAnimations):
* dom/ScriptedAnimationController.h: Added.
(WebCore::ScriptedAnimationController::create):
* history/CachedFrame.cpp:
(WebCore::CachedFrameBase::restore):
(WebCore::CachedFrame::CachedFrame):
* page/PageGroupLoadDeferrer.cpp:
(WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
(WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
TBR=jamesr@google.com
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=78733
Patch Set 1 #Messages
Total messages: 1 (0 generated)
|