Open Bug 1947849 Opened 1 month ago Updated 1 month ago

Changing the value of BrowsingContext.forceDesktopViewport should trigger a call to MobileViewportManager::RefreshViewportSize

Categories

(Core :: Panning and Zooming, defect, P3)

defect

Tracking

()

People

(Reporter: botond, Unassigned)

Details

We have logic for using a different mobile viewport size when the forceDesktopViewport flag is set on the BrowsingContext.

That means the value of this flag is an input to the mobile viewport size computation, and so MobileViewportManager::RefreshViewportSize() should be triggered when the value of flag is changed.

Summary: Changing the default of forceDesktopViewport should trigger a call to RefreshViewportSize → Changing the value of forceDesktopViewport should trigger a call to RefreshViewportSize
Summary: Changing the value of forceDesktopViewport should trigger a call to RefreshViewportSize → Changing the value of BrowsingContext.forceDesktopViewport should trigger a call to MobileViewportManager::RefreshViewportSize

When I heard this, I thought BrowsingContext doesn't invalidate it, but in fact it does. So probably a bug exists in MobileViewportManager.

(In reply to Hiroyuki Ikezoe (:hiro) from comment #1)

When I heard this, I thought BrowsingContext doesn't invalidate it, but in fact it does. So probably a bug exists in MobileViewportManager.

Calling MaybeRecreateMobileViewportManager() doesn't perform the invalidation we want, it's more about creating an MVM if there isn't one. In this case, I expect it will take this early exit and be a no-op.

Oh right, that's it!

You need to log in before you can comment on or make changes to this bug.