Bug 1753772 - Don't call SetDynamicToolbarMaxHeight for non-root BrowserParent. r=hiro

Differential Revision: https://phabricator.services.mozilla.com/D138326
This commit is contained in:
Agi Sferro 2022-02-10 01:09:49 +00:00
parent 37e94b914c
commit 878bb38005

View File

@ -939,8 +939,10 @@ void BrowserParent::InitRendering() {
#if defined(MOZ_WIDGET_ANDROID)
MOZ_ASSERT(widget);
Unused << SendDynamicToolbarMaxHeightChanged(
widget->GetDynamicToolbarMaxHeight());
if (GetBrowsingContext()->IsTopContent()) {
Unused << SendDynamicToolbarMaxHeightChanged(
widget->GetDynamicToolbarMaxHeight());
}
#endif
}