From d4938148ade89957061a7c3fcfc1023199d0f068 Mon Sep 17 00:00:00 2001 From: Jon Date: Fri, 18 Sep 2015 23:49:42 -0400 Subject: [PATCH] Update the app to use XAML because...XAML --- FakeDemo/App.cs | 16 +--------------- FakeDemo/FakeDemo.csproj | 8 ++++++++ FakeDemo/MainPage.xaml | 8 ++++++++ FakeDemo/MainPage.xaml.cs | 12 ++++++++++++ 4 files changed, 29 insertions(+), 15 deletions(-) create mode 100644 FakeDemo/MainPage.xaml create mode 100644 FakeDemo/MainPage.xaml.cs diff --git a/FakeDemo/App.cs b/FakeDemo/App.cs index 506f7e3..a987928 100644 --- a/FakeDemo/App.cs +++ b/FakeDemo/App.cs @@ -7,21 +7,7 @@ public class App : Application public App() { // The root page of your application - MainPage = new ContentPage - { - Content = new StackLayout - { - VerticalOptions = LayoutOptions.Center, - Children = - { - new Label - { - XAlign = TextAlignment.Center, - Text = "Welcome to Xamarin Forms!" - } - } - } - }; + MainPage = new MainPage(); } protected override void OnStart() diff --git a/FakeDemo/FakeDemo.csproj b/FakeDemo/FakeDemo.csproj index d28da64..4ebd1aa 100644 --- a/FakeDemo/FakeDemo.csproj +++ b/FakeDemo/FakeDemo.csproj @@ -32,6 +32,9 @@ + + MainPage.xaml + @@ -49,4 +52,9 @@ + + + MSBuild:UpdateDesignTimeXaml + + \ No newline at end of file diff --git a/FakeDemo/MainPage.xaml b/FakeDemo/MainPage.xaml new file mode 100644 index 0000000..e965be3 --- /dev/null +++ b/FakeDemo/MainPage.xaml @@ -0,0 +1,8 @@ + + + + diff --git a/FakeDemo/MainPage.xaml.cs b/FakeDemo/MainPage.xaml.cs new file mode 100644 index 0000000..004ac86 --- /dev/null +++ b/FakeDemo/MainPage.xaml.cs @@ -0,0 +1,12 @@ +using Xamarin.Forms; + +namespace FakeDemo +{ + public partial class MainPage : ContentPage + { + public MainPage() + { + InitializeComponent(); + } + } +}