Bug 1287951: stylo: Implement ServoRestyleManager::AttributeWillChange. draft
authorEmilio Cobos Álvarez <ecoal95@gmail.com>
Tue, 19 Jul 2016 14:35:37 -0700
changeset 390260 ce43300226601cf28b1b7213a92891c5a3962def
parent 390259 d3854cad46cd58945143c7742ff8eb129e8624a0
child 525966 04f9b3097e72056cff5f40aa0639ac7a11bce1a0
push id23634
push userbmo:ealvarez@mozilla.com
push dateWed, 20 Jul 2016 22:07:19 +0000
bugs1287951
milestone50.0a1
Bug 1287951: stylo: Implement ServoRestyleManager::AttributeWillChange. MozReview-Commit-ID: 5CCleWo06Ow
layout/base/ServoRestyleManager.cpp
--- a/layout/base/ServoRestyleManager.cpp
+++ b/layout/base/ServoRestyleManager.cpp
@@ -292,17 +292,18 @@ ServoRestyleManager::ContentStateChanged
 
 void
 ServoRestyleManager::AttributeWillChange(Element* aElement,
                                          int32_t aNameSpaceID,
                                          nsIAtom* aAttribute,
                                          int32_t aModType,
                                          const nsAttrValue* aNewValue)
 {
-  NS_ERROR("stylo: ServoRestyleManager::AttributeWillChange not implemented");
+  ServoElementSnapshot* snapshot = SnapshotForElement(aElement);
+  snapshot->AddAttrs(aElement);
 }
 
 void
 ServoRestyleManager::AttributeChanged(Element* aElement,
                                       int32_t aNameSpaceID,
                                       nsIAtom* aAttribute,
                                       int32_t aModType,
                                       const nsAttrValue* aOldValue)