From 0b51dcf211cb286b5acd7522c48ebd1c008101dc Mon Sep 17 00:00:00 2001 From: "simon.fraser@apple.com" Date: Thu, 8 May 2014 01:16:53 +0000 Subject: [PATCH] Put a better version of the assertion back, and add one when we ensureBackingStore. Reviewed by Tim Horton. * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp: (WebKit::PlatformCALayerRemote::recursiveBuildTransaction): (WebKit::PlatformCALayerRemote::ensureBackingStore): git-svn-id: https://svn.webkit.org/repository/webkit/trunk@168456 268f45cc-cd09-0410-ab3c-d52691b4dbfc --- Source/WebKit2/ChangeLog | 10 ++++++++++ .../WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp | 4 ++++ 2 files changed, 14 insertions(+) diff --git a/Source/WebKit2/ChangeLog b/Source/WebKit2/ChangeLog index 77c2fbd..3c3baed 100644 --- a/Source/WebKit2/ChangeLog +++ b/Source/WebKit2/ChangeLog @@ -1,5 +1,15 @@ 2014-05-07 Simon Fraser + Put a better version of the assertion back, and add one when we ensureBackingStore. + + Reviewed by Tim Horton. + + * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp: + (WebKit::PlatformCALayerRemote::recursiveBuildTransaction): + (WebKit::PlatformCALayerRemote::ensureBackingStore): + +2014-05-07 Simon Fraser + This assertion was wrong and fired every time. Remove it. * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp: diff --git a/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp b/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp index 4d45797..3735e23 100644 --- a/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp +++ b/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp @@ -118,6 +118,8 @@ PlatformCALayerRemote::~PlatformCALayerRemote() void PlatformCALayerRemote::recursiveBuildTransaction(RemoteLayerTreeTransaction& transaction) { + ASSERT(!m_properties.backingStore || owner()); + if (m_properties.backingStore && (!owner() || !owner()->platformCALayerDrawsContent())) { m_properties.backingStore = nullptr; m_properties.notePropertiesChanged(RemoteLayerTreeTransaction::BackingStoreChanged); @@ -167,6 +169,8 @@ void PlatformCALayerRemote::animationStarted(CFTimeInterval beginTime) void PlatformCALayerRemote::ensureBackingStore() { + ASSERT(owner()); + if (!m_properties.backingStore) m_properties.backingStore = std::make_unique(m_context); -- 1.8.3.1