mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-17 07:15:46 +00:00
Bug 1345695 - stylo: Assert that we have computed style in Servo_ResolveStyle when lazy computation is forbidden. r=bholley
MozReview-Commit-ID: Bul00XOpfxA --HG-- extra : rebase_source : 485668d0a92c9407c9dfeb5cd569aa1b07569a14
This commit is contained in:
parent
67201815a8
commit
43e68fc196
@ -171,9 +171,9 @@ ServoStyleSet::GetContext(nsIContent* aContent,
|
||||
Element* element = aContent->AsElement();
|
||||
|
||||
|
||||
PreTraverseSync();
|
||||
RefPtr<ServoComputedValues> computedValues;
|
||||
if (aMayCompute == LazyComputeBehavior::Allow) {
|
||||
PreTraverseSync();
|
||||
computedValues = ResolveStyleLazily(element, nullptr);
|
||||
} else {
|
||||
computedValues = ResolveServoStyle(element);
|
||||
|
@ -1654,7 +1654,8 @@ pub extern "C" fn Servo_ResolveStyle(element: RawGeckoElementBorrowed,
|
||||
};
|
||||
|
||||
if !valid_styles {
|
||||
warn!("Resolving style on element without current styles with lazy computation forbidden.");
|
||||
debug_assert!(false, "Resolving style on element without current styles with lazy \
|
||||
computation forbidden.");
|
||||
let per_doc_data = PerDocumentStyleData::from_ffi(raw_data).borrow();
|
||||
return per_doc_data.default_computed_values().clone().into_strong();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user