diff --git a/layout/style/nsComputedDOMStyle.cpp b/layout/style/nsComputedDOMStyle.cpp index e9424340cb82..f0aebce35c91 100644 --- a/layout/style/nsComputedDOMStyle.cpp +++ b/layout/style/nsComputedDOMStyle.cpp @@ -766,7 +766,7 @@ void nsComputedDOMStyle::SetFrameComputedStyle(mozilla::ComputedStyle* aStyle, mPresShellId = mPresShell->GetPresShellId(); } -bool nsComputedDOMStyle::NeedsToFlush() const { +bool nsComputedDOMStyle::NeedsToFlushStyle() const { // We always compute styles from the element's owner document. if (ElementNeedsRestyle(mElement, mPseudo)) { return true; @@ -800,7 +800,7 @@ void nsComputedDOMStyle::UpdateCurrentStyleSources(bool aNeedsLayoutFlush) { // * https://github.com/w3c/csswg-drafts/issues/1548 // If the property we are computing relies on layout, then we must flush. - const bool needsToFlush = aNeedsLayoutFlush || NeedsToFlush(); + const bool needsToFlush = aNeedsLayoutFlush || NeedsToFlushStyle(); if (needsToFlush) { // Flush _before_ getting the presshell, since that could create a new // presshell. Also note that we want to flush the style on the document diff --git a/layout/style/nsComputedDOMStyle.h b/layout/style/nsComputedDOMStyle.h index 55e06e728808..af4cc39e19cd 100644 --- a/layout/style/nsComputedDOMStyle.h +++ b/layout/style/nsComputedDOMStyle.h @@ -338,8 +338,8 @@ class nsComputedDOMStyle final : public nsDOMCSSDeclaration, bool GetFrameBorderRectHeight(nscoord& aHeight); // Find out if we can safely skip flushing (i.e. pending restyles do not - // affect mElement). - bool NeedsToFlush() const; + // affect our element). + bool NeedsToFlushStyle() const; static ComputedStyleMap* GetComputedStyleMap();