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

Use SafeArea in the Samples App #593

Closed
kazo0 opened this issue Jun 6, 2023 · 1 comment
Closed

Use SafeArea in the Samples App #593

kazo0 opened this issue Jun 6, 2023 · 1 comment
Assignees
Labels
area/sample-app kind/enhancement New feature or request. triage/untriaged Indicates an issue requires triaging or verification.

Comments

@kazo0
Copy link
Contributor

kazo0 commented Jun 6, 2023

We should be using the SafeArea in the Shell, rather than doing things like this:

/// <summary>
/// This method handles the top padding for phones like iPhone X.
/// </summary>
private void InitializeSafeArea()
{
#if !IS_WINUI
var full = XamlWindow.Current.Bounds;
var bounds = Windows.UI.ViewManagement.ApplicationView.GetForCurrentView().VisibleBounds;
var topPadding = Math.Abs(full.Top - bounds.Top);
if (topPadding > 0)
{
TopPaddingRow.Height = new GridLength(topPadding);
}
#endif
}

We should also be making sure the app content, including the runtime test runner page, all stay within the bounds of the safe area

@kazo0 kazo0 added kind/enhancement New feature or request. triage/untriaged Indicates an issue requires triaging or verification. area/sample-app labels Jun 6, 2023
@carlh98 carlh98 self-assigned this Jun 7, 2023
@carlh98
Copy link
Contributor

carlh98 commented Jun 27, 2023

@kazo0 when this PR is merged #616
We'll be able to close this issue

@carlh98 carlh98 closed this as completed Jun 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/sample-app kind/enhancement New feature or request. triage/untriaged Indicates an issue requires triaging or verification.
Projects
None yet
Development

No branches or pull requests

2 participants