Page MenuHomePhabricator

Improve reliability of detecting small devices when loading Differential changesets
ClosedPublic

Authored by epriestley on Jan 29 2016, 1:00 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Dec 22, 9:06 AM
Unknown Object (File)
Fri, Dec 20, 2:10 PM
Unknown Object (File)
Thu, Dec 19, 7:49 AM
Unknown Object (File)
Wed, Dec 18, 6:18 AM
Unknown Object (File)
Tue, Dec 17, 3:38 AM
Unknown Object (File)
Fri, Dec 13, 10:36 PM
Unknown Object (File)
Fri, Dec 13, 7:19 AM
Unknown Object (File)
Thu, Dec 12, 3:06 PM
Subscribers
None

Details

Summary

Ref T10229. Fixes T9969. We make a decision about 1up vs 2up pretty early, and sometimes the viewport size reads as larger than the device, so we incorrectly select 2up when the proper setting would be 1up.

Test Plan

I can reproduce this by, e.g., reloading a lot on an iPhone 4s in iOS Simulator running iOS 9.2. Sometimes it picks 2-up. I added logging to show that the viewport dimension read was the issue.

After this change, it always selects 1-up (window.screen.availWidth is defined and sensible on the device).

Diff Detail

Repository
rP Phabricator
Branch
doubletouch1
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 10379
Build 12664: Run Core Tests
Build 12663: arc lint + arc unit

Event Timeline

epriestley retitled this revision from to Improve reliability of detecting small devices when loading Differential changesets.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
This revision is now accepted and ready to land.Jan 29 2016, 2:49 PM
This revision was automatically updated to reflect the committed changes.