Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use new DisplayMetrics object in
getDisplayMetrics
as to not overwr…
…ite Android global state Summary: The change in 8e60394 actually causes a super bad bug when `context.getResources().getDisplayMetrics()` is accessed in other parts of the application. It turns out that when you dive into the impl of `getRealMetrics`, it mutates whatever `DisplayMetrics` object is passed to it. In this case, `getDisplayMetrics` ends up mutating the `DisplayMetrics` object that sits on the application context's `Resources` instance. This PR makes that not so. /cc jesseruder ide jaysoo bestander astreet Closes #5764 Reviewed By: svcscm Differential Revision: D2902386 Pulled By: androidtrunkagent fb-gh-sync-id: 3f24b68bc7e6b4ca83808c03ef3637e1ac9a673e
- Loading branch information