Changeset 168175 in webkit
- Timestamp:
- May 2, 2014 10:29:22 AM (10 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r168174 r168175 1 2014-05-01 Simon Fraser <simon.fraser@apple.com> 2 3 [iOS WK2] Animations on vox.com look wrong 4 https://bugs.webkit.org/show_bug.cgi?id=132462 5 <rdar://problem/16731884> 6 7 Reviewed by Sam Weinig. 8 9 PlatformCALayerRemote was managing animations incorrectly; aninations 10 would stick around in m_properties.addedAnimations and get added a second 11 time by mistake. 12 13 Animations have to be managed a little differently to other properties, 14 since they are not steady-state things. A given commit has to send over 15 the added and removed animations, and then clear the layer properties. 16 17 Do this by adding PlatformCALayerRemote::didCommit(), which is called 18 after the layer properties have been encoded, and have it clear the lists 19 of added and removed animations. 20 21 removeAnimationForKey() also has to remove the animation from addedAnimations 22 so that an add/remove in the same commit doesn't send the animation to the 23 UI process. 24 25 * WebProcess/WebPage/mac/PlatformCALayerRemote.cpp: 26 (WebKit::PlatformCALayerRemote::recursiveBuildTransaction): 27 (WebKit::PlatformCALayerRemote::didCommit): 28 (WebKit::PlatformCALayerRemote::removeAnimationForKey): 29 * WebProcess/WebPage/mac/PlatformCALayerRemote.h: 30 * WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm: 31 (WebKit::RemoteLayerTreeDrawingArea::flushLayers): 32 1 33 2014-05-01 Simon Fraser <simon.fraser@apple.com> 2 34 -
trunk/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.cpp
r167980 r168175 136 136 if (m_layerType == LayerTypeCustom) { 137 137 RemoteLayerTreePropertyApplier::applyProperties(platformLayer(), nullptr, m_properties, RemoteLayerTreePropertyApplier::RelatedLayerMap()); 138 m_properties.resetChangedProperties();138 didCommit(); 139 139 return; 140 140 } … … 151 151 if (m_maskLayer) 152 152 m_maskLayer->recursiveBuildTransaction(transaction); 153 } 154 155 void PlatformCALayerRemote::didCommit() 156 { 157 m_properties.addedAnimations.clear(); 158 m_properties.keyPathsOfAnimationsToRemove.clear(); 159 m_properties.resetChangedProperties(); 153 160 } 154 161 … … 298 305 void PlatformCALayerRemote::removeAnimationForKey(const String& key) 299 306 { 300 // FIXME: remove from m_properties.addedAnimations ?307 m_properties.addedAnimations.remove(key); 301 308 m_properties.keyPathsOfAnimationsToRemove.add(key); 302 309 m_properties.notePropertiesChanged(RemoteLayerTreeTransaction::AnimationsChanged); -
trunk/Source/WebKit2/WebProcess/WebPage/mac/PlatformCALayerRemote.h
r167553 r168175 158 158 RemoteLayerTreeTransaction::LayerProperties& properties() { return m_properties; } 159 159 160 void didCommit(); 161 160 162 void clearContext() { m_context = nullptr; } 161 163 -
trunk/Source/WebKit2/WebProcess/WebPage/mac/RemoteLayerTreeDrawingArea.mm
r167792 r168175 279 279 if (layer->properties().changedProperties & RemoteLayerTreeTransaction::LayerChanges::BackingStoreChanged) 280 280 hadAnyChangedBackingStore = true; 281 layer-> properties().resetChangedProperties();281 layer->didCommit(); 282 282 } 283 283
Note: See TracChangeset
for help on using the changeset viewer.