Merge pull request #60551 from madmiraal/implement-3466

Add a method for obtaining display cutouts on Android
This commit is contained in:
Rémi Verschelde 2022-05-02 07:56:41 +02:00 committed by GitHub
commit bc7ccc909b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 67 additions and 0 deletions

View file

@ -104,6 +104,13 @@
<description>
</description>
</method>
<method name="get_display_cutouts" qualifiers="const">
<return type="Array" />
<description>
Returns an [Array] of [Rect2], each of which is the bounding rectangle for a display cutout or notch. These are non-functional areas on edge-to-edge screens used by cameras and sensors. Returns an empty array if the device does not have cutouts. See also [method screen_get_usable_rect].
[b]Note:[/b] Currently only implemented on Android. Other platforms will return an empty array even if they do have display cutouts or notches.
</description>
</method>
<method name="get_name" qualifiers="const">
<return type="String" />
<description>