Closed
Bug 1189879
Opened 11 years ago
Closed 11 years ago
Fennec desktop mode temporarily uses a 480px viewport height
Categories
(Firefox for Android Graveyard :: Toolbar, defect)
Tracking
(firefox42 fixed)
RESOLVED
FIXED
Firefox 42
| Tracking | Status | |
|---|---|---|
| firefox42 | --- | fixed |
People
(Reporter: kats, Assigned: kats)
References
Details
Attachments
(1 file)
|
1.02 KB,
patch
|
snorp
:
review+
|
Details | Diff | Splinter Review |
If desktop mode is enabled in Fennec, and updateViewportSize gets called in browser.js, then there are two calls to setBrowserSize. The first call at [1] sets a viewport height of 480 (which comes from [2]), and the second call at [3] sets a more correct viewport height (which is based on the screen dimensions and maintains the right aspect ratio). The first viewport height is just bogus and we shouldn't be doing that. It causes an unnecessary reflow and introduces a potential for the scroll position to get incorrectly clamped for no good reason.
[1] http://mxr.mozilla.org/mozilla-central/source/mobile/android/chrome/content/browser.js?rev=8bdfb76f8a08#4882
[2] http://mxr.mozilla.org/mozilla-central/source/mobile/android/chrome/content/browser.js?rev=8bdfb76f8a08#6605
[3] http://mxr.mozilla.org/mozilla-central/source/mobile/android/chrome/content/browser.js?rev=8bdfb76f8a08#4947
| Assignee | ||
Comment 1•11 years ago
|
||
Setting it to -1 causes updateViewportSize to recompute it based on the screen aspect ratio, which is what we want here.
Attachment #8641794 -
Flags: review?(snorp)
Updated•11 years ago
|
Attachment #8641794 -
Flags: review?(snorp) → review+
Comment 2•11 years ago
|
||
purely fyi / not directly related here, I'd suspected this codepath causing issues in my initial implementation of a test for the new Gecko SelectionCarets ...
On-the-fly zoomContraints calcs during tab/page loads seemed to cause (random orange) event coords to be scaled wrong if the tests ran early.
Structuring the test as [0] allowed for stability.
[0] http://mxr.mozilla.org/mozilla-central/source/mobile/android/tests/browser/robocop/testSelectionCarets.js?rev=101feffdaed8&mark=160-164,170-173#156
| Assignee | ||
Comment 3•11 years ago
|
||
I'd find it strange if this patch fixed your test issues. Although yes, in general the initial load of pages causes pretty bad thrashing of the zoom constraints and and viewports and such. All that should be fixed by the move to APZ and the C++ counterparts to this code.
Comment 5•11 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
status-firefox42:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 42
Updated•5 years ago
|
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•