Fix Dimensions window values on Android < 15#53254
Fix Dimensions window values on Android < 15#53254zoontek wants to merge 4 commits intofacebook:mainfrom
Conversation
22726c1 to
c95b5aa
Compare
|
@alanleedev has imported this pull request. If you are a Meta employee, you can view this in D80237818. |
c95b5aa to
47d8ed5
Compare
|
|
@alanleedev has imported this pull request. If you are a Meta employee, you can view this in D80237818. |
|
@zoontek There was a question if we could to" keep initDisplayMetrics as a backwards-compat API and have it call both". I haven't quite figured out the internal crash yet. And it does seem like new API does make things bit more fragile. Do you have any thoughts here? |
|
@alanleedev One alternative could be to extract the is UI thread method from AndroidX, set both screen and window dimensions when |
|
This PR is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
|
This PR is stale because it has been open for 180 days with no activity. It will be closed in 7 days unless you comment on it or remove the "Stale" label. |
9e4c7de to
6ccb1ef
Compare
|
As |
|
8b4c84a to
84d709e
Compare
9e07deb to
9ffbd21
Compare
e3c04d5 to
569b3e0
Compare
|
@alanleedev has imported this pull request. If you are a Meta employee, you can view this in D80237818. |
569b3e0 to
b247afd
Compare
# Conflicts: # packages/react-native/ReactAndroid/src/main/java/com/facebook/react/ReactRootView.java
b247afd to
8c427b6
Compare
|
Warning JavaScript API change detected This PR commits an update to
This change was flagged as: |
|
This pull request was successfully merged by @zoontek in 44a4b1b When will my fix make it into a release? | How to file a pick request? |
|
@alanleedev merged this pull request in 44a4b1b. |
Summary:
This PR (initially created for edge-to-edge opt-in support, rebased multiple times) fixes the
DimensionsAPIwindowvalues on Android < 15, when edge-to-edge is enabled.Currently the window height doesn't include the status and navigation bar heights (but it does on Android >= 15):
Using
WindowMetricsCalculatorfrom AndroidX:Fixes #47080
Changelog:
[Android] [Fixed] Fix
Dimensionswindowvalues on Android < 15 when edge-to-edge is enabledTest Plan:
Run the example app on an Android < 15 device.