Restrictions on orientation and resizability are ignored when targeting Android 17
Categories
(Firefox for Android :: General, task)
Tracking
()
People
(Reporter: mcarare, Assigned: mcarare)
References
Details
(Whiteboard: [fxdroid][group6] )
See https://developer.android.com/about/versions/17/changes/ff-restrictions-ignored.
One note, I thought the orientation restriction were already imposed in Android 16: https://developer.android.com/about/versions/16/behavior-changes-16#ignore-orientation.
We need to see if there are additional possible issues.
Updated•9 months ago
|
| Assignee | ||
Updated•6 months ago
|
| Assignee | ||
Comment 1•6 months ago
|
||
Analysis result: No direct changes are required for Android 17 orientation/resizability behavior.
-
The Android 16 Precedent
Android 16 (API 36) introduced the same large-screen enforcement. It included a temporary developer opt-out mechanism via theUNIVERSAL_RESIZABLE_BY_DEFAULTcompat flag. Android 17 simply removes that opt-out — the underlying runtime behavior is identical.
Fenix and Focus currently target API 36 (targetSdkVersion: 36) and never used the opt-out. This means the full enforcement has been active on every Android 16 device running the apps since that OS shipped and we targeted 36. The app has already been shipping and operating correctly under these exact constraints. Or at least, no new "bugs" would be introduced by the target update. -
Both Fenix and Focus declare
android:resizeableActivity="true"on their main activities. The app has already explicitly opted into resizability, making it a non-issue regardless of platform enforcement. There is nothing to change in the manifests.
The only concern is the orientation locking API that only reports allow or deny with no Exceptions - NotSupportedError would be the specific exception in this case.
Comment 2•6 months ago
•
|
||
agree with this analysis. i checked that we're not using the resizable opt-out here. According to the docs this means any deprecated orientation / resizability flags in use would not have worked anyway.
However, i did find that we are setting requestedOrientation here in ScreenOrientationFeature. The docs say that this will be ignored on large screen devices running in full-screen and multi-window mode.
I think more investigation into how this currently works would be good. If the api is no longer doing anything, we can remove it. Or if it works in only some circumstances, maybe it would benefit from some restrictions or rewording.
i guess this is what your last sentence was referring to as well? are you suggesting we throw an Exception if the API doesn't work in some scenarios?
| Assignee | ||
Comment 3•6 months ago
|
||
Yes, https://bugzilla.mozilla.org/show_bug.cgi?id=2037807 will cover the ScreenOrientationFeature.
| Assignee | ||
Updated•6 months ago
|
| Assignee | ||
Updated•6 months ago
|
Description
•