Title: [237925] trunk/Source/WebCore
- Revision
- 237925
- Author
- [email protected]
- Date
- 2018-11-07 07:21:03 -0800 (Wed, 07 Nov 2018)
Log Message
TileController::tileSize() should not have side effects
https://bugs.webkit.org/show_bug.cgi?id=191349
Reviewed by Zalan Bujtas.
Calling TileController::tileSize() would recompute a new tile size and set m_tileSizeLocked,
which caused test failures if logging was enabled when running tests.
* platform/graphics/ca/TileController.cpp:
(WebCore::TileController::tileSize const):
(WebCore::TileController::computeTileSize):
* platform/graphics/ca/TileController.h:
* platform/graphics/ca/TileGrid.cpp:
(WebCore::TileGrid::revalidateTiles):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (237924 => 237925)
--- trunk/Source/WebCore/ChangeLog 2018-11-07 14:57:40 UTC (rev 237924)
+++ trunk/Source/WebCore/ChangeLog 2018-11-07 15:21:03 UTC (rev 237925)
@@ -1,3 +1,20 @@
+2018-11-07 Simon Fraser <[email protected]>
+
+ TileController::tileSize() should not have side effects
+ https://bugs.webkit.org/show_bug.cgi?id=191349
+
+ Reviewed by Zalan Bujtas.
+
+ Calling TileController::tileSize() would recompute a new tile size and set m_tileSizeLocked,
+ which caused test failures if logging was enabled when running tests.
+
+ * platform/graphics/ca/TileController.cpp:
+ (WebCore::TileController::tileSize const):
+ (WebCore::TileController::computeTileSize):
+ * platform/graphics/ca/TileController.h:
+ * platform/graphics/ca/TileGrid.cpp:
+ (WebCore::TileGrid::revalidateTiles):
+
2018-11-07 Charlie Turner <[email protected]>
[EME][GStreamer] Ensure key id buffers are present and simplify lifetime management of ClearKey class.
Modified: trunk/Source/WebCore/platform/graphics/ca/TileController.cpp (237924 => 237925)
--- trunk/Source/WebCore/platform/graphics/ca/TileController.cpp 2018-11-07 14:57:40 UTC (rev 237924)
+++ trunk/Source/WebCore/platform/graphics/ca/TileController.cpp 2018-11-07 15:21:03 UTC (rev 237925)
@@ -528,6 +528,11 @@
IntSize TileController::tileSize() const
{
+ return tileGrid().tileSize();
+}
+
+IntSize TileController::computeTileSize()
+{
if (m_inLiveResize || m_tileSizeLocked)
return tileGrid().tileSize();
Modified: trunk/Source/WebCore/platform/graphics/ca/TileController.h (237924 => 237925)
--- trunk/Source/WebCore/platform/graphics/ca/TileController.h 2018-11-07 14:57:40 UTC (rev 237924)
+++ trunk/Source/WebCore/platform/graphics/ca/TileController.h 2018-11-07 15:21:03 UTC (rev 237925)
@@ -123,6 +123,8 @@
void adjustTileCoverageRect(FloatRect& coverageRect, const FloatSize& newSize, const FloatRect& previousVisibleRect, const FloatRect& currentVisibleRect, float contentsScale) const override;
bool scrollingPerformanceLoggingEnabled() const override { return m_scrollingPerformanceLoggingEnabled; }
+ IntSize computeTileSize();
+
IntRect boundsAtLastRevalidate() const { return m_boundsAtLastRevalidate; }
IntRect boundsAtLastRevalidateWithoutMargin() const;
void didRevalidateTiles();
@@ -229,7 +231,7 @@
bool m_tilesAreOpaque { false };
bool m_hasTilesWithTemporaryScaleFactor { false }; // Used to make low-res tiles when zooming.
bool m_inLiveResize { false };
- mutable bool m_tileSizeLocked { false };
+ bool m_tileSizeLocked { false };
bool m_isTileSizeUpdateDelayDisabledForTesting { false };
Color m_tileDebugBorderColor;
Modified: trunk/Source/WebCore/platform/graphics/ca/TileGrid.cpp (237924 => 237925)
--- trunk/Source/WebCore/platform/graphics/ca/TileGrid.cpp 2018-11-07 14:57:40 UTC (rev 237924)
+++ trunk/Source/WebCore/platform/graphics/ca/TileGrid.cpp 2018-11-07 15:21:03 UTC (rev 237925)
@@ -368,7 +368,7 @@
Seconds minimumRevalidationTimerDuration = Seconds::infinity();
bool needsTileRevalidation = false;
- auto tileSize = m_controller.tileSize();
+ auto tileSize = m_controller.computeTileSize();
if (tileSize != m_tileSize) {
removeAllTiles();
m_tileSize = tileSize;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes