Bug 1322570 Part 6 - Use GetParentAllowServo() in RestyleManager. draft
authorTing-Yu Lin <tlin@mozilla.com>
Mon, 20 Mar 2017 14:14:01 +0800
changeset 504314 6e585573c65944ed4f9cda2fbbf121b6a9ed6ed4
parent 504313 af997c214f2861aab9d1666e22cf423a11fc85b9
child 504315 7a183183e8561c99c7d6e943be04cae4986312ad
push id50776
push userbmo:tlin@mozilla.com
push dateFri, 24 Mar 2017 06:09:16 +0000
bugs1322570, 670226
milestone55.0a1
Bug 1322570 Part 6 - Use GetParentAllowServo() in RestyleManager. Fixed tests like layout/reftests/bidi/670226-1.html. MozReview-Commit-ID: DuEXNZhFC7M
layout/base/RestyleManager.cpp
--- a/layout/base/RestyleManager.cpp
+++ b/layout/base/RestyleManager.cpp
@@ -1335,17 +1335,18 @@ RestyleManager::GetNextContinuationWithS
   }
 
   NS_ASSERTION(nextContinuation->GetContent() == aFrame->GetContent(),
                "unexpected content mismatch");
 
   nsStyleContext* nextStyle = nextContinuation->StyleContext();
   if (nextStyle != aOldStyleContext) {
     NS_ASSERTION(aOldStyleContext->GetPseudo() != nextStyle->GetPseudo() ||
-                 aOldStyleContext->GetParent() != nextStyle->GetParent(),
+                 aOldStyleContext->GetParentAllowServo() !=
+                   nextStyle->GetParentAllowServo(),
                  "continuations should have the same style context");
     nextContinuation = nullptr;
     if (aHaveMoreContinuations) {
       *aHaveMoreContinuations = true;
     }
   }
   return nextContinuation;
 }