Adds UWP support to Shell (#6015)
authorMorten Nielsen <1378165+dotMorten@users.noreply.github.com>
Tue, 17 Sep 2019 22:26:56 +0000 (15:26 -0700)
committerRui Marinho <me@ruimarinho.net>
Tue, 17 Sep 2019 22:26:56 +0000 (23:26 +0100)
commitaeafec9ff672edd32e0968c0a39ec2c835765c3f
tree0380564cbbe9a128627987d3daae12ed4bad6541
parent86042a2dd45f2512ad7d42fc77121cbbc1062c1d
Adds UWP support to Shell (#6015)

* Some basics to get started

* more renderers

* Fix titlebar color

* More shell stuff working

* Hacked some more UI in

* Fix null ref issue

* Move renderer registration outside common code (for now)

* Re-write of the renderers to better use a cleaner UWP approach

* Moved functionality around, bug fixesetc

* Added null check

* Added null-check on appearance and use default colors as fallback

* Handle change in flyout behavior to correctly turn the flyout on/off

* Handle the TabBarIsVisible property

* code formatting

* Ensure FlyoutHeader isn't show if the app starts up with a minimal pane

*  Throw if used on versions lower than Windows 10 1809

* Added null-check for when ShellContent isn't set

* Support tabs in FlyoutItems with Display AsMultipleItems by using the generated FlyoutGroupings instead

* Improve pane behavior and styling

* Undo Android change used during testing

* Fix platform support check

* Use FileImageSourcePathConverter on NavigationViewItem instead of a custom control (so I deleted ShellNavigationViewItemRenderer which is no longer needed).
Ensure `FileImageSourcePathConverter` won't throw if it didn't get a FileImageSource.
Move the flyout data templates into a resource so they can be overridden and compiled.

* Delete renamed file

* Use a resource instead of parsing a string template

* Handle search box property changes

* Update page title on property change

* Update bottombar when shellitems change

* Guard against API usage not present

* Platform check comments

* Fix problem running in release mode (use Bindable to generate XamlMetadata

* Trigger rebind of menu items source when collection changes

* Added support for Toolbar

* Fix searchbox behavior (still lacks expand/collapse feature)

* Add overload for defining the navigation transition

* Use different navigation transitions based on navigatin direction

* Hides header with show / hide nav command

* collapses header area on hide nav

* Move to use WinUI

* Fix runtime issues after merge.

* - rebase fixes

* - rebase fixes

* - fix spaces/tabs

* - flags, hide apis, delete assembly info

* - set flag on UWP CG

* - expose renderer creations and make them all public

* - formatting fixes

* - address PR comments

* - fix header so it's full width and swappable
17 files changed:
.nuspec/Xamarin.Forms.nuspec
Xamarin.Forms.ControlGallery.WindowsUniversal/App.xaml.cs
Xamarin.Forms.Core/ExperimentalFlags.cs
Xamarin.Forms.Core/Shell/Shell.cs
Xamarin.Forms.Platform.UAP/ImageSourceIconElementConverter.cs
Xamarin.Forms.Platform.UAP/PageExtensions.cs
Xamarin.Forms.Platform.UAP/Properties/AssemblyInfo.cs
Xamarin.Forms.Platform.UAP/Resources.xaml
Xamarin.Forms.Platform.UAP/Shell/ShellFlyoutTemplateSelector.cs [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/Shell/ShellHeaderRenderer.cs [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/Shell/ShellItemRenderer.cs [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/Shell/ShellRenderer.cs [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/Shell/ShellSectionRenderer.cs [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/Shell/ShellStyles.xaml [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/Shell/ShellToolbarItemRenderer.cs [new file with mode: 0644]
Xamarin.Forms.Platform.UAP/ViewToRendererConverter.cs
Xamarin.Forms.Platform.UAP/Xamarin.Forms.Platform.UAP.csproj