Diff
Modified: trunk/LayoutTests/ChangeLog (102611 => 102612)
--- trunk/LayoutTests/ChangeLog 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/LayoutTests/ChangeLog 2011-12-12 20:58:15 UTC (rev 102612)
@@ -1,3 +1,17 @@
+2011-12-12 James Robinson <[email protected]>
+
+ Rename webkitCancelRequestAnimationFrame to webkitCancelAnimationFrame to match spec change
+ https://bugs.webkit.org/show_bug.cgi?id=74231
+
+ Reviewed by Simon Fraser.
+
+ Update requestAnimationFrame tests to refer to the new function name.
+
+ * fast/animation/request-animation-frame-missing-arguments.html:
+ * fast/animation/script-tests/request-animation-frame-cancel.js:
+ (window):
+ * fast/animation/script-tests/request-animation-frame-cancel2.js:
+
2011-12-12 Kenneth Russell <[email protected]>
Unreviewed Chromium gardening. Mark flaky crashing transitions/
Modified: trunk/LayoutTests/fast/animation/request-animation-frame-missing-arguments-expected.txt (102611 => 102612)
--- trunk/LayoutTests/fast/animation/request-animation-frame-missing-arguments-expected.txt 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/LayoutTests/fast/animation/request-animation-frame-missing-arguments-expected.txt 2011-12-12 20:58:15 UTC (rev 102612)
@@ -4,7 +4,7 @@
PASS webkitRequestAnimationFrame() threw exception TypeError: Not enough arguments.
-PASS webkitCancelRequestAnimationFrame() threw exception TypeError: Not enough arguments.
+PASS webkitCancelAnimationFrame() threw exception TypeError: Not enough arguments.
PASS successfullyParsed is true
TEST COMPLETE
Modified: trunk/LayoutTests/fast/animation/request-animation-frame-missing-arguments.html (102611 => 102612)
--- trunk/LayoutTests/fast/animation/request-animation-frame-missing-arguments.html 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/LayoutTests/fast/animation/request-animation-frame-missing-arguments.html 2011-12-12 20:58:15 UTC (rev 102612)
@@ -7,7 +7,7 @@
<script>
description('Test how animation methods react to too few arguments.');
shouldThrow("webkitRequestAnimationFrame()");
-shouldThrow("webkitCancelRequestAnimationFrame()");
+shouldThrow("webkitCancelAnimationFrame()");
</script>
<script src=""
</body>
Modified: trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-cancel.js (102611 => 102612)
--- trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-cancel.js 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-cancel.js 2011-12-12 20:58:15 UTC (rev 102612)
@@ -5,7 +5,7 @@
var id = window.webkitRequestAnimationFrame(function() {
}, e);
-window.webkitCancelRequestAnimationFrame(id);
+window.webkitCancelAnimationFrame(id);
if (window.layoutTestController)
layoutTestController.display();
Modified: trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-cancel2.js (102611 => 102612)
--- trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-cancel2.js 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/LayoutTests/fast/animation/script-tests/request-animation-frame-cancel2.js 2011-12-12 20:58:15 UTC (rev 102612)
@@ -7,7 +7,7 @@
window.webkitRequestAnimationFrame(function() {
cancelFired = true;
- window.webkitCancelRequestAnimationFrame(secondCallbackId);
+ window.webkitCancelAnimationFrame(secondCallbackId);
}, e);
secondCallbackId = window.webkitRequestAnimationFrame(function() {
Modified: trunk/Source/WebCore/ChangeLog (102611 => 102612)
--- trunk/Source/WebCore/ChangeLog 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/Source/WebCore/ChangeLog 2011-12-12 20:58:15 UTC (rev 102612)
@@ -1,3 +1,24 @@
+2011-12-12 James Robinson <[email protected]>
+
+ Rename webkitCancelRequestAnimationFrame to webkitCancelAnimationFrame to match spec change
+ https://bugs.webkit.org/show_bug.cgi?id=74231
+
+ Reviewed by Simon Fraser.
+
+ The RequestAnimationFrame spec has renamed cancelRequestAnimationFrame to cancelAnimationFrame in response to
+ feedback from Mozilla and Microsoft that the old name was too long and didn't parallel setTimeout/clearTimeout
+ and setInterval/clearInterval very well. This updates our IDL to match, while preserving the old name as an
+ alias to be compatible with current content.
+
+ * dom/Document.cpp:
+ (WebCore::Document::webkitCancelAnimationFrame):
+ * dom/Document.h:
+ * page/DOMWindow.cpp:
+ (WebCore::DOMWindow::webkitCancelAnimationFrame):
+ * page/DOMWindow.h:
+ (WebCore::DOMWindow::webkitCancelRequestAnimationFrame):
+ * page/DOMWindow.idl:
+
2011-12-12 Shawn Singh <[email protected]>
[chromium] Remove assumption that empty surface is always at end of list
Modified: trunk/Source/WebCore/dom/Document.cpp (102611 => 102612)
--- trunk/Source/WebCore/dom/Document.cpp 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/Source/WebCore/dom/Document.cpp 2011-12-12 20:58:15 UTC (rev 102612)
@@ -5145,7 +5145,7 @@
return m_scriptedAnimationController->registerCallback(callback, animationElement);
}
-void Document::webkitCancelRequestAnimationFrame(int id)
+void Document::webkitCancelAnimationFrame(int id)
{
if (!m_scriptedAnimationController)
return;
Modified: trunk/Source/WebCore/dom/Document.h (102611 => 102612)
--- trunk/Source/WebCore/dom/Document.h 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/Source/WebCore/dom/Document.h 2011-12-12 20:58:15 UTC (rev 102612)
@@ -1105,7 +1105,7 @@
#if ENABLE(REQUEST_ANIMATION_FRAME)
int webkitRequestAnimationFrame(PassRefPtr<RequestAnimationFrameCallback>, Element*);
- void webkitCancelRequestAnimationFrame(int id);
+ void webkitCancelAnimationFrame(int id);
void serviceScriptedAnimations(DOMTimeStamp);
#endif
Modified: trunk/Source/WebCore/page/DOMWindow.cpp (102611 => 102612)
--- trunk/Source/WebCore/page/DOMWindow.cpp 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/Source/WebCore/page/DOMWindow.cpp 2011-12-12 20:58:15 UTC (rev 102612)
@@ -1584,10 +1584,10 @@
return 0;
}
-void DOMWindow::webkitCancelRequestAnimationFrame(int id)
+void DOMWindow::webkitCancelAnimationFrame(int id)
{
if (Document* d = document())
- d->webkitCancelRequestAnimationFrame(id);
+ d->webkitCancelAnimationFrame(id);
}
#endif
Modified: trunk/Source/WebCore/page/DOMWindow.h (102611 => 102612)
--- trunk/Source/WebCore/page/DOMWindow.h 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/Source/WebCore/page/DOMWindow.h 2011-12-12 20:58:15 UTC (rev 102612)
@@ -254,7 +254,8 @@
// WebKit animation extensions
#if ENABLE(REQUEST_ANIMATION_FRAME)
int webkitRequestAnimationFrame(PassRefPtr<RequestAnimationFrameCallback>, Element*);
- void webkitCancelRequestAnimationFrame(int id);
+ void webkitCancelAnimationFrame(int id);
+ void webkitCancelRequestAnimationFrame(int id) { webkitCancelAnimationFrame(id); }
#endif
// Events
Modified: trunk/Source/WebCore/page/DOMWindow.idl (102611 => 102612)
--- trunk/Source/WebCore/page/DOMWindow.idl 2011-12-12 20:53:30 UTC (rev 102611)
+++ trunk/Source/WebCore/page/DOMWindow.idl 2011-12-12 20:58:15 UTC (rev 102612)
@@ -241,9 +241,10 @@
void clearInterval(in [Optional=CallWithDefaultValue] long handle);
#if defined(ENABLE_REQUEST_ANIMATION_FRAME)
- // WebKit animation extensions
+ // WebKit animation extensions, being standardized in the WebPerf WG
long webkitRequestAnimationFrame(in [Callback] RequestAnimationFrameCallback callback, in [Optional=CallWithDefaultValue] Element element);
- void webkitCancelRequestAnimationFrame(in long id);
+ void webkitCancelAnimationFrame(in long id);
+ void webkitCancelRequestAnimationFrame(in long id); // This is a deprecated alias for webkitCancelAnimationFrame(). Remove this when removing vendor prefix.
#endif
// Base64