From da4aff1c40f0066c645c3bcca2b899d3e7b93e2c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20Sua=CC=81rez?= Date: Mon, 23 Jan 2023 12:43:04 +0100 Subject: [PATCH 1/5] Fix the issue --- .../Handlers/Shell/iOS/ShellPageRendererTracker.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/ShellPageRendererTracker.cs b/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/ShellPageRendererTracker.cs index 323d5280baa6..9024f6ed3dfd 100644 --- a/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/ShellPageRendererTracker.cs +++ b/src/Controls/src/Core/Compatibility/Handlers/Shell/iOS/ShellPageRendererTracker.cs @@ -1,4 +1,4 @@ -#nullable disable +#nullable disable using System; using System.Collections.Generic; using System.Collections.Specialized; @@ -462,7 +462,7 @@ public override CGRect Frame public override void WillMoveToSuperview(UIView newSuper) { - if (newSuper != null) + if (newSuper != null && newSuper.Bounds != CGRect.Empty) { if (!(OperatingSystem.IsIOSVersionAtLeast(11) || OperatingSystem.IsTvOSVersionAtLeast(11))) Frame = new CGRect(Frame.X, newSuper.Bounds.Y, Frame.Width, newSuper.Bounds.Height); From b75e3adf7db43cabbba6da14d295ab22b91f90a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20Sua=CC=81rez?= Date: Mon, 23 Jan 2023 12:43:13 +0100 Subject: [PATCH 2/5] Added a sample in the Gallery --- .../Controls.Sample/Pages/AppShell.xaml | 32 +++++++++++++++++-- .../Controls.Sample/Pages/AppShell.xaml.cs | 10 ++++++ 2 files changed, 40 insertions(+), 2 deletions(-) diff --git a/src/Controls/samples/Controls.Sample/Pages/AppShell.xaml b/src/Controls/samples/Controls.Sample/Pages/AppShell.xaml index 474becca6092..389713023101 100644 --- a/src/Controls/samples/Controls.Sample/Pages/AppShell.xaml +++ b/src/Controls/samples/Controls.Sample/Pages/AppShell.xaml @@ -6,8 +6,36 @@ xmlns:pages="using:Maui.Controls.Sample.Pages" xmlns:shellPages="clr-namespace:Maui.Controls.Sample.Pages.ShellGalleries" FlyoutBackground="{AppThemeBinding Dark=Black, Light=White}" - Title="Welcome to Shell" - > + Title="{Binding ShellTitle}"> + + + + + + +