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

Revert WinUI to use Layout Renderer #1264

Merged
merged 3 commits into from
Jun 11, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,8 @@ static IAppHostBuilder SetupDefaults(this IAppHostBuilder builder)
handlers.TryAddCompatibilityRenderer(typeof(TabbedPage), typeof(TabbedPageRenderer));
handlers.TryAddCompatibilityRenderer(typeof(Shell), typeof(ShellRenderer));
handlers.TryAddCompatibilityRenderer(typeof(OpenGLView), typeof(OpenGLViewRenderer));
#else
handlers.TryAddCompatibilityRenderer(typeof(Layout), typeof(LayoutRenderer));
#endif
handlers.TryAddCompatibilityRenderer(typeof(NavigationPage), typeof(NavigationPageRenderer));
handlers.TryAddCompatibilityRenderer(typeof(CarouselPage), typeof(CarouselPageRenderer));
Expand Down
6 changes: 5 additions & 1 deletion src/Controls/src/Core/AppHostBuilderExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ public static class AppHostBuilderExtensions
{ typeof(GraphicsView), typeof(GraphicsViewHandler) },
{ typeof(Image), typeof(ImageHandler) },
{ typeof(Label), typeof(LabelHandler) },
{ typeof(Layout), typeof(LayoutHandler) },
{ typeof(Layout2.Layout), typeof(LayoutHandler) },
{ typeof(Picker), typeof(PickerHandler) },
{ typeof(ProgressBar), typeof(ProgressBarHandler) },
Expand All @@ -41,6 +40,11 @@ public static class AppHostBuilderExtensions
{ typeof(Shapes.Polygon), typeof(ShapeViewHandler) },
{ typeof(Shapes.Polyline), typeof(ShapeViewHandler) },
{ typeof(Shapes.Rectangle), typeof(ShapeViewHandler) },

#if !WINDOWS
{ typeof(Layout), typeof(LayoutHandler) },
#endif

};

public static IMauiHandlersCollection AddMauiControlsHandlers(this IMauiHandlersCollection handlersCollection)
Expand Down