Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android - Foldables #391

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

AndrewEQ
Copy link
Contributor

@AndrewEQ AndrewEQ commented Mar 26, 2021

Added support for Multi-Window and related properties needed to support foldable devices:
https://developer.android.com/guide/topics/ui/foldables
https://developer.android.com/guide/topics/ui/multi-window
https://developer.android.com/guide/topics/ui/picture-in-picture
https://developer.samsung.com/galaxy/foldable/techdocs
https://stackoverflow.com/questions/14111052/adding-samsung-multi-window-support-to-android-application
https://program.developer.samsung.com/2019/04/05/seven-mistakes-to-avoid-when-developing-for-foldable-displays

Sample project settings:

"Android": {
"MultiWindow": {
"Enabled": true,
"DefaultSizeWidth": "320p",
"DefaultSizeHeight": "640p",
"MultiInstance": true
},
"PenWindow": true,
"AllowMultipleResumedActivities": true,
"ResizeableActivity": true,
"SupportsPictureInPicture": true,
"WindowLayoutInDisplayCutoutMode": 'default',
"MaxAspect": "21:9",
"Layout": {
"DefaultHeight": "640dp",
"DefaultWidth": "320dp",
"Gravity": "top|end",
"MinHeight": "300dp",
"MinWidth": "280dp"
},

Added support for Multi-Window and related properties:
https://developer.android.com/guide/topics/ui/foldables
https://developer.android.com/guide/topics/ui/multi-window
https://developer.android.com/guide/topics/ui/picture-in-picture
https://developer.samsung.com/galaxy/foldable/techdocs
https://stackoverflow.com/questions/14111052/adding-samsung-multi-window-support-to-android-application
https://program.developer.samsung.com/2019/04/05/seven-mistakes-to-avoid-when-developing-for-foldable-displays

Sample project settings:
```
"Android": {
"MultiWindow": {
"Enabled": true,
"DefaultSizeWidth": "320p",
"DefaultSizeHeight": "640p",
"MultiInstance": true
},
"PenWindow": true,
"AllowMultipleResumedActivities": true,
"ResizeableActivity": true,
"SupportsPictureInPicture": true,
"WindowLayoutInDisplayCutoutMode": 'default',
"MaxAspect": "21:9",
"Layout": {
"DefaultHeight": "640dp",
"DefaultWidth": "320dp",
"Gravity": "top|end",
"MinHeight": "300dp",
"MinWidth": "280dp"
},
```
@AndrewEQ AndrewEQ requested a review from mortend March 26, 2021 11:33
Copy link
Member

@mortend mortend left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I found one small thing to nitpick on. Otherwise looks fine. :)

@@ -13,6 +13,9 @@
#endif
<item name="android:windowContentOverlay">@null</item>
<item name="android:windowIsTranslucent">@(Project.Android.WindowIsTranslucent || 'false')</item>
#if @(Project.Android.WindowLayoutInDisplayCutoutMode:IsSet)
<item name="android:windowLayoutInDisplayCutoutMode">@(Project.Android.WindowLayoutInDisplayCutoutMode || 'default')</item>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Looks like mixed/incorrect indentation on this line? Compare with <item ... two lines above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants