Repository navigation
fix: step DevTools zoom through blink's preset zoom factors - #54349
Merged
Merged
Conversation
GetNextZoomLevel() kept its own copy of the browser zoom table, which had drifted from blink::kPresetBrowserZoomFactors (no 80% step, rounded 33%/67% values) and only moved when the stored level exactly matched an entry. Use the blink table and step to the nearest neighbouring preset so zooming also works from a level that is not in the table.
A level persisted from the old table's rounded 0.333 / 0.666 entries is a hair below the 1/3 / 2/3 preset in level space, so the first zoom-in from it was an invisible step. Compare factors with blink::ZoomValuesEqual instead.
MarshallOfSound
force-pushed
the
fix/devtools-zoom-presets
branch
from
September 25, 2026 10:30
d63c804 to
5e9b2f7
Compare
deepak1556
approved these changes
Sep 25, 2026
|
Release Notes Persisted
|
This was referenced Sep 25, 2026
Contributor
|
I have automatically backported this PR to "44-x-y", please check out #54387 |
Contributor
|
I have automatically backported this PR to "45-x-y", please check out #54388 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description of Change
DevTools zoom in/out kept its own copy of the browser zoom table, which had drifted from
blink::kPresetBrowserZoomFactors(no 80% step, rounded 33%/67% entries) and only moved when the stored level exactly matched a table entry. Step through the blink table to the nearest neighbouring preset instead, comparing factors so a level stored from the old rounded entries still counts as the 1/3 / 2/3 preset. Adds a spec that steps DevTools zoom in and out.Checklist
Release Notes
Notes: DevTools zoom in/out now uses the same zoom steps as Chromium.