Bug 1733384 - Make inert not modify the computed style. r=sefeng,layout-reviewers,jfkthame

Differential Revision: https://phabricator.services.mozilla.com/D127422
This commit is contained in:
Emilio Cobos Álvarez
2021-10-07 11:47:34 +00:00
parent df603f1d44
commit 671a086845
28 changed files with 169 additions and 141 deletions

View File

@@ -4010,7 +4010,8 @@ nsresult nsCSSFrameConstructor::GetAnonymousContent(
StaticPrefs::layout_css_cached_scrollbar_styles_enabled() &&
aParentFrame->StyleVisibility()->mVisible == StyleVisibility::Visible &&
#ifndef ANDROID
aParentFrame->StyleUI()->mPointerEvents == StylePointerEvents::Auto &&
aParentFrame->StyleUI()->ComputedPointerEvents() ==
StylePointerEvents::Auto &&
#endif
mPresShell->GetPresContext()->Medium() == nsGkAtoms::screen;
@@ -4066,7 +4067,8 @@ nsresult nsCSSFrameConstructor::GetAnonymousContent(
"cached anonymous content styles should be identical to those we "
"would compute normally");
# ifdef ANDROID
MOZ_ASSERT(cs->StyleUI()->mPointerEvents == StylePointerEvents::None);
MOZ_ASSERT(cs->StyleUI()->ComputedPointerEvents() ==
StylePointerEvents::None);
# endif
#endif
Servo_SetExplicitStyle(elements[i], cachedStyles[i]);