Title: [218351] trunk/Source/WebCore
Revision
218351
Author
commit-qu...@webkit.org
Date
2017-06-15 13:08:07 -0700 (Thu, 15 Jun 2017)

Log Message

Ensure we only log changes to the ScriptedAnimationController suspended state in debug builds
https://bugs.webkit.org/show_bug.cgi?id=173423

Patch by Antoine Quint <grao...@apple.com> on 2017-06-15
Reviewed by Tim Horton.

We added logging for when the suspended state of the scripted animation controller would change in
webkit.org/b/173326. It was meant to only be enabled in debug builds and we actually did the wrong
thing and enabled it in non-debug builds.

We also added a setting that wasn't used and that we are removing here.

* dom/ScriptedAnimationController.cpp:
(WebCore::ScriptedAnimationController::logSuspendCount):
* page/Settings.in:
* testing/InternalSettings.cpp:
(WebCore::InternalSettings::resetToConsistentState):
(WebCore::InternalSettings::shouldLogScritedAnimationControllerSuspensionChange): Deleted.
(WebCore::InternalSettings::setShouldLogScritedAnimationControllerSuspensionChange): Deleted.
* testing/InternalSettings.h:
* testing/InternalSettings.idl:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (218350 => 218351)


--- trunk/Source/WebCore/ChangeLog	2017-06-15 20:02:22 UTC (rev 218350)
+++ trunk/Source/WebCore/ChangeLog	2017-06-15 20:08:07 UTC (rev 218351)
@@ -1,3 +1,26 @@
+2017-06-15  Antoine Quint  <grao...@apple.com>
+
+        Ensure we only log changes to the ScriptedAnimationController suspended state in debug builds
+        https://bugs.webkit.org/show_bug.cgi?id=173423
+
+        Reviewed by Tim Horton.
+
+        We added logging for when the suspended state of the scripted animation controller would change in
+        webkit.org/b/173326. It was meant to only be enabled in debug builds and we actually did the wrong
+        thing and enabled it in non-debug builds.
+
+        We also added a setting that wasn't used and that we are removing here.
+
+        * dom/ScriptedAnimationController.cpp:
+        (WebCore::ScriptedAnimationController::logSuspendCount):
+        * page/Settings.in:
+        * testing/InternalSettings.cpp:
+        (WebCore::InternalSettings::resetToConsistentState):
+        (WebCore::InternalSettings::shouldLogScritedAnimationControllerSuspensionChange): Deleted.
+        (WebCore::InternalSettings::setShouldLogScritedAnimationControllerSuspensionChange): Deleted.
+        * testing/InternalSettings.h:
+        * testing/InternalSettings.idl:
+
 2017-06-15  David Kilzer  <ddkil...@apple.com>
 
         Build fix: [iOS] Generate a simulated crash when the WebThread starts in MobileSafari

Modified: trunk/Source/WebCore/dom/ScriptedAnimationController.cpp (218350 => 218351)


--- trunk/Source/WebCore/dom/ScriptedAnimationController.cpp	2017-06-15 20:02:22 UTC (rev 218350)
+++ trunk/Source/WebCore/dom/ScriptedAnimationController.cpp	2017-06-15 20:08:07 UTC (rev 218351)
@@ -91,10 +91,7 @@
 
 void ScriptedAnimationController::logSuspendCount()
 {
-#if defined NDEBUG
-    if (!m_document || !m_document->frame() || !m_document->frame()->settings().shouldLogScritedAnimationControllerSuspensionChange())
-        return;
-
+#if !defined(NDEBUG)
     WTFLogAlways("ScriptedAnimationController::m_suspendCount = %d", m_suspendCount);
     WTFReportBacktrace();
 #endif

Modified: trunk/Source/WebCore/page/Settings.in (218350 => 218351)


--- trunk/Source/WebCore/page/Settings.in	2017-06-15 20:02:22 UTC (rev 218350)
+++ trunk/Source/WebCore/page/Settings.in	2017-06-15 20:08:07 UTC (rev 218351)
@@ -277,8 +277,6 @@
 
 inputEventsEnabled initial=true
 
-shouldLogScritedAnimationControllerSuspensionChange initial=true
-
 quickTimePluginReplacementEnabled initial=defaultQuickTimePluginReplacementEnabled
 youTubeFlashPluginReplacementEnabled initial=defaultYouTubeFlashPluginReplacementEnabled
 

Modified: trunk/Source/WebCore/testing/InternalSettings.cpp (218350 => 218351)


--- trunk/Source/WebCore/testing/InternalSettings.cpp	2017-06-15 20:02:22 UTC (rev 218350)
+++ trunk/Source/WebCore/testing/InternalSettings.cpp	2017-06-15 20:08:07 UTC (rev 218351)
@@ -265,8 +265,6 @@
     m_page->mainFrame().setPageAndTextZoomFactors(1, 1);
     m_page->setCanStartMedia(true);
 
-    settings().setShouldLogScritedAnimationControllerSuspensionChange(true);
-
     settings().setForcePendingWebGLPolicy(false);
 #if ENABLE(WIRELESS_PLAYBACK_TARGET)
     settings().setAllowsAirPlayForMediaPlayback(false);
@@ -732,16 +730,6 @@
 #endif
 }
 
-bool InternalSettings::shouldLogScritedAnimationControllerSuspensionChange()
-{
-    return settings().shouldLogScritedAnimationControllerSuspensionChange();
-}
-
-void InternalSettings::setShouldLogScritedAnimationControllerSuspensionChange(bool shouldLogScritedAnimationControllerSuspensionChange)
-{
-    settings().setShouldLogScritedAnimationControllerSuspensionChange(shouldLogScritedAnimationControllerSuspensionChange);
-}
-
 ExceptionOr<String> InternalSettings::userInterfaceDirectionPolicy()
 {
     if (!m_page)

Modified: trunk/Source/WebCore/testing/InternalSettings.h (218350 => 218351)


--- trunk/Source/WebCore/testing/InternalSettings.h	2017-06-15 20:02:22 UTC (rev 218350)
+++ trunk/Source/WebCore/testing/InternalSettings.h	2017-06-15 20:08:07 UTC (rev 218351)
@@ -111,9 +111,6 @@
     ForcedAccessibilityValue forcedPrefersReducedMotionAccessibilityValue() const;
     void setForcedPrefersReducedMotionAccessibilityValue(ForcedAccessibilityValue);
 
-    bool shouldLogScritedAnimationControllerSuspensionChange();
-    void setShouldLogScritedAnimationControllerSuspensionChange(bool);
-
     // RuntimeEnabledFeatures.
     static void setIndexedDBWorkersEnabled(bool);
     static void setCSSGridLayoutEnabled(bool);

Modified: trunk/Source/WebCore/testing/InternalSettings.idl (218350 => 218351)


--- trunk/Source/WebCore/testing/InternalSettings.idl	2017-06-15 20:02:22 UTC (rev 218350)
+++ trunk/Source/WebCore/testing/InternalSettings.idl	2017-06-15 20:08:07 UTC (rev 218351)
@@ -96,9 +96,6 @@
     [MayThrowException] boolean deferredCSSParserEnabled();
     [MayThrowException] void setDeferredCSSParserEnabled(boolean enabled);
 
-    boolean shouldLogScritedAnimationControllerSuspensionChange();
-    void setShouldLogScritedAnimationControllerSuspensionChange(boolean shouldLogScritedAnimationControllerSuspensionChange);
-
     [MayThrowException] void setShouldMockBoldSystemFontForAccessibility(boolean shouldMock);
 
     attribute ForcedAccessibilityValue forcedColorsAreInvertedAccessibilityValue;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to