Title: [97803] trunk/Source/WebCore
Revision
97803
Author
[email protected]
Date
2011-10-18 16:05:10 -0700 (Tue, 18 Oct 2011)

Log Message

Scroll animator tracing
https://bugs.webkit.org/show_bug.cgi?id=70280

Patch by Scott Byer <[email protected]> on 2011-10-18
Reviewed by James Robinson.

No functional difference, no test needed.

* platform/ScrollAnimatorNone.cpp:
(WebCore::ScrollAnimatorNone::scroll):
(WebCore::ScrollAnimatorNone::animationTimerFired):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (97802 => 97803)


--- trunk/Source/WebCore/ChangeLog	2011-10-18 23:02:02 UTC (rev 97802)
+++ trunk/Source/WebCore/ChangeLog	2011-10-18 23:05:10 UTC (rev 97803)
@@ -1,3 +1,16 @@
+2011-10-18  Scott Byer  <[email protected]>
+
+        Scroll animator tracing
+        https://bugs.webkit.org/show_bug.cgi?id=70280
+
+        Reviewed by James Robinson.
+
+        No functional difference, no test needed.
+
+        * platform/ScrollAnimatorNone.cpp:
+        (WebCore::ScrollAnimatorNone::scroll):
+        (WebCore::ScrollAnimatorNone::animationTimerFired):
+
 2011-10-18  James Robinson  <[email protected]>
 
         [chromium] Remove USE(THREADED_COMPOSITING) from the tree, this is controlled by a runtime setting

Modified: trunk/Source/WebCore/platform/ScrollAnimatorNone.cpp (97802 => 97803)


--- trunk/Source/WebCore/platform/ScrollAnimatorNone.cpp	2011-10-18 23:02:02 UTC (rev 97802)
+++ trunk/Source/WebCore/platform/ScrollAnimatorNone.cpp	2011-10-18 23:05:10 UTC (rev 97803)
@@ -40,11 +40,14 @@
 #include "PlatformGestureEvent.h"
 #include "ScrollableArea.h"
 #include "ScrollbarTheme.h"
-#include "TraceEvent.h"
 #include <algorithm>
 #include <wtf/CurrentTime.h>
 #include <wtf/PassOwnPtr.h>
 
+#if PLATFORM(CHROMIUM)
+#include "TraceEvent.h"
+#endif
+
 using namespace std;
 
 namespace WebCore {
@@ -411,6 +414,10 @@
     if (!m_scrollableArea->scrollAnimatorEnabled())
         return ScrollAnimator::scroll(orientation, granularity, step, multiplier);
 
+#if PLATFORM(CHROMIUM)
+    TRACE_EVENT("ScrollAnimatorNone::scroll", this, 0);
+#endif
+
     // FIXME: get the type passed in. MouseWheel could also be by line, but should still have different
     // animation parameters than the keyboard.
     Parameters parameters;
@@ -542,6 +549,10 @@
 
 void ScrollAnimatorNone::animationTimerFired(Timer<ScrollAnimatorNone>* timer)
 {
+#if PLATFORM(CHROMIUM)
+    TRACE_EVENT("ScrollAnimatorNone::animationTimerFired", this, 0);
+#endif
+
     double currentTime = WTF::monotonicallyIncreasingTime();
     double deltaToNextFrame = ceil((currentTime - m_startTime) * kFrameRate) / kFrameRate - (currentTime - m_startTime);
 
@@ -552,6 +563,9 @@
         continueAnimation = true;
 
     if (m_zoomData.m_isAnimating) {
+#if PLATFORM(CHROMIUM)
+        TRACE_EVENT("ScrollAnimatorNone::notifyZoomChanged", this, 0);
+#endif
         if (m_zoomData.m_startTime && m_zoomData.animateZoom(currentTime + deltaToNextFrame)) {
             continueAnimation = true;
             notifyZoomChanged(ZoomAnimationContinuing);
@@ -565,6 +579,10 @@
         double nextTimerInterval = max(kMinimumTimerInterval, deltaToNextFrame);
         timer->startOneShot(nextTimerInterval);
     }
+
+#if PLATFORM(CHROMIUM)
+    TRACE_EVENT("ScrollAnimatorNone::notifyPositionChanged", this, 0);
+#endif
     notifyPositionChanged();
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to