Title: [247008] releases/WebKitGTK/webkit-2.24/Source/WebCore
- Revision
- 247008
- Author
- carlo...@webkit.org
- Date
- 2019-07-01 06:45:57 -0700 (Mon, 01 Jul 2019)
Log Message
Merge r247007 - REGRESSION(r246963) GTK's debug build is broken
https://bugs.webkit.org/show_bug.cgi?id=199358
Reviewed by Michael Catanzaro.
Add traits to be able to downcast AnimatedBackingStoreClient.
* platform/graphics/nicosia/NicosiaAnimatedBackingStoreClient.h:
(Nicosia::AnimatedBackingStoreClient::AnimatedBackingStoreClient):
(Nicosia::AnimatedBackingStoreClient::type const):
* platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
(WebCore::CoordinatedGraphicsLayer::updateContentBuffers):
Modified Paths
Diff
Modified: releases/WebKitGTK/webkit-2.24/Source/WebCore/ChangeLog (247007 => 247008)
--- releases/WebKitGTK/webkit-2.24/Source/WebCore/ChangeLog 2019-07-01 13:42:25 UTC (rev 247007)
+++ releases/WebKitGTK/webkit-2.24/Source/WebCore/ChangeLog 2019-07-01 13:45:57 UTC (rev 247008)
@@ -1,3 +1,18 @@
+2019-07-01 Miguel Gomez <mago...@igalia.com>
+
+ REGRESSION(r246963) GTK's debug build is broken
+ https://bugs.webkit.org/show_bug.cgi?id=199358
+
+ Reviewed by Michael Catanzaro.
+
+ Add traits to be able to downcast AnimatedBackingStoreClient.
+
+ * platform/graphics/nicosia/NicosiaAnimatedBackingStoreClient.h:
+ (Nicosia::AnimatedBackingStoreClient::AnimatedBackingStoreClient):
+ (Nicosia::AnimatedBackingStoreClient::type const):
+ * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
+ (WebCore::CoordinatedGraphicsLayer::updateContentBuffers):
+
2019-07-01 Carlos Garcia Campos <cgar...@igalia.com>
Unreviewed. Fix GTK build with GSTREAMER_GL disabled after r246710
Modified: releases/WebKitGTK/webkit-2.24/Source/WebCore/platform/graphics/nicosia/NicosiaAnimatedBackingStoreClient.h (247007 => 247008)
--- releases/WebKitGTK/webkit-2.24/Source/WebCore/platform/graphics/nicosia/NicosiaAnimatedBackingStoreClient.h 2019-07-01 13:42:25 UTC (rev 247007)
+++ releases/WebKitGTK/webkit-2.24/Source/WebCore/platform/graphics/nicosia/NicosiaAnimatedBackingStoreClient.h 2019-07-01 13:45:57 UTC (rev 247008)
@@ -40,10 +40,28 @@
class AnimatedBackingStoreClient : public ThreadSafeRefCounted<AnimatedBackingStoreClient> {
public:
+ enum class Type {
+ Coordinated
+ };
+
+ explicit AnimatedBackingStoreClient(Type type)
+ : m_type(type)
+ {
+ }
+
+ Type type() const { return m_type; }
virtual ~AnimatedBackingStoreClient() = default;
virtual void requestBackingStoreUpdateIfNeeded(const WebCore::TransformationMatrix&) = 0;
+
+private:
+ Type m_type;
};
} // namespace Nicosia
+#define SPECIALIZE_TYPE_TRAITS_ANIMATEDBACKINGSTORECLIENT(ToValueTypeName, predicate) \
+SPECIALIZE_TYPE_TRAITS_BEGIN(ToValueTypeName) \
+ static bool isType(const Nicosia::AnimatedBackingStoreClient& client) { return client.predicate; } \
+SPECIALIZE_TYPE_TRAITS_END()
+
#endif // USE(COORDINATED_GRAPHICS)
Modified: releases/WebKitGTK/webkit-2.24/Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp (247007 => 247008)
--- releases/WebKitGTK/webkit-2.24/Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp 2019-07-01 13:42:25 UTC (rev 247007)
+++ releases/WebKitGTK/webkit-2.24/Source/WebCore/platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp 2019-07-01 13:45:57 UTC (rev 247008)
@@ -699,7 +699,8 @@
private:
CoordinatedAnimatedBackingStoreClient(RefPtr<CoordinatedGraphicsLayer::AnimatedBackingStoreHost>&& host, const FloatRect& visibleRect, const FloatRect& coverRect, const FloatSize& size, float contentsScale)
- : m_host(WTFMove(host))
+ : Nicosia::AnimatedBackingStoreClient(Type::Coordinated)
+ , m_host(WTFMove(host))
, m_visibleRect(visibleRect)
, m_coverRect(coverRect)
, m_size(size)
@@ -1004,9 +1005,9 @@
layerState.mainBackingStore->createTilesIfNeeded(transformedVisibleRect(), IntRect(0, 0, m_size.width(), m_size.height()));
}
- if (m_nicosia.animatedBackingStoreClient) {
+ if (is<CoordinatedAnimatedBackingStoreClient>(m_nicosia.animatedBackingStoreClient)) {
// Determine the coverRect and set it to the client.
- downcast<CoordinatedAnimatedBackingStoreClient>(m_nicosia.animatedBackingStoreClient.get())->setCoverRect(layerState.mainBackingStore->coverRect());
+ downcast<CoordinatedAnimatedBackingStoreClient>(*m_nicosia.animatedBackingStoreClient).setCoverRect(layerState.mainBackingStore->coverRect());
}
ASSERT(m_coordinator && m_coordinator->isFlushingLayerChanges());
@@ -1303,4 +1304,6 @@
} // namespace WebCore
+SPECIALIZE_TYPE_TRAITS_ANIMATEDBACKINGSTORECLIENT(WebCore::CoordinatedAnimatedBackingStoreClient, type() == Nicosia::AnimatedBackingStoreClient::Type::Coordinated)
+
#endif // USE(COORDINATED_GRAPHICS)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes