SIGN IN SIGN UP
facebook / react-native UNCLAIMED

A framework for building native applications using React

0 0 94 C++

Remove getWindowDisplayMetrics from DisplayMetricsHolder (#56635)

Summary:
Following https://github.com/facebook/react-native/pull/53254

Removes the deprecated `getWindowDisplayMetrics` / `setWindowDisplayMetrics` / `getDisplayMetricsWritableMap` APIs from `DisplayMetricsHolder`. These were marked `TODO(0.87)` for removal once the non-breaking window closed.

## Changelog:

[ANDROID] [REMOVED] - Remove `DisplayMetricsHolder.getWindowDisplayMetrics`, `setWindowDisplayMetrics`, and `getDisplayMetricsWritableMap`

Pull Request resolved: https://github.com/facebook/react-native/pull/56635

Test Plan:
- `./gradlew :packages:react-native:ReactAndroid:test` passes (removed `DisplayMetricsHolderTest` window-metrics cases and the `PixelUtilTest` references)
- checked prefetching logs with VR
    - `./arvr/apps/LivingRoom/build_and_run.sh`
        - `CometPrefetchers        com.oculus.tv                        D  Found entrypoints to prefetch for: LivingRoomHomeSurface.entrypoint. Custom variables: react_native_pixel_ratio = 1.25`
    - `./arvr/apps/Store/build_and_run.sh`
        - `CometPrefetchers        com.oculus.store                     D  Found entrypoints to prefetch for: StoreHome.entrypoint. Custom variables: react_native_pixel_ratio = 1.25`

Reviewed By: javache

Differential Revision: D103695359

Pulled By: alanleedev

fbshipit-source-id: fdcf2f74b56323e9a7474c6aea09d3dcbaa4fd7f
M
Mathieu Acthernoene committed
82536f230fc14d9433fc006224e3b3da24d5838f
Parent: 8636cad
Committed by meta-codesync[bot] <215208954+meta-codesync[bot]@users.noreply.github.com> on 5/16/2026, 6:44:36 PM