summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.ControlGallery.WindowsPhone
diff options
context:
space:
mode:
authorJason Smith <jason.smith@xamarin.com>2016-03-22 13:02:25 -0700
committerJason Smith <jason.smith@xamarin.com>2016-03-22 16:13:41 -0700
commit17fdde66d94155fc62a034fa6658995bef6fd6e5 (patch)
treeb5e5073a2a7b15cdbe826faa5c763e270a505729 /Xamarin.Forms.ControlGallery.WindowsPhone
downloadxamarin-forms-17fdde66d94155fc62a034fa6658995bef6fd6e5.tar.gz
xamarin-forms-17fdde66d94155fc62a034fa6658995bef6fd6e5.tar.bz2
xamarin-forms-17fdde66d94155fc62a034fa6658995bef6fd6e5.zip
Initial import
Diffstat (limited to 'Xamarin.Forms.ControlGallery.WindowsPhone')
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml7
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml.cs134
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Logo.scale-240.pngbin0 -> 2516 bytes
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SmallLogo.scale-240.pngbin0 -> 753 bytes
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SplashScreen.scale-240.pngbin0 -> 14715 bytes
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Square71x71Logo.scale-240.pngbin0 -> 1122 bytes
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Assets/StoreLogo.scale-240.pngbin0 -> 2200 bytes
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Assets/WideLogo.scale-240.pngbin0 -> 4530 bytes
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/BrokenNativeControl.cs65
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml11
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml.cs108
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Package.appxmanifest34
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Properties/AssemblyInfo.cs29
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/StringProvider.cs15
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/Xamarin.Forms.ControlGallery.WindowsPhone.csproj187
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/app.config11
-rw-r--r--Xamarin.Forms.ControlGallery.WindowsPhone/toolbar_close.pngbin0 -> 463 bytes
17 files changed, 601 insertions, 0 deletions
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml b/Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml
new file mode 100644
index 00000000..7be404c7
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml
@@ -0,0 +1,7 @@
+<Application
+ x:Class="Xamarin.Forms.ControlGallery.WindowsPhone.App"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:local="using:Xamarin.Forms.ControlGallery.WindowsPhone">
+
+</Application> \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml.cs b/Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml.cs
new file mode 100644
index 00000000..1842bb86
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/App.xaml.cs
@@ -0,0 +1,134 @@
+using System;
+using System.Collections.Generic;
+using System.IO;
+using System.Linq;
+using System.Runtime.InteropServices.WindowsRuntime;
+using Windows.ApplicationModel;
+using Windows.ApplicationModel.Activation;
+using Windows.Foundation;
+using Windows.Foundation.Collections;
+using Windows.UI.Xaml;
+using Windows.UI.Xaml.Controls;
+using Windows.UI.Xaml.Controls.Primitives;
+using Windows.UI.Xaml.Data;
+using Windows.UI.Xaml.Input;
+using Windows.UI.Xaml.Media;
+using Windows.UI.Xaml.Media.Animation;
+using Windows.UI.Xaml.Navigation;
+
+// The Blank Application template is documented at http://go.microsoft.com/fwlink/?LinkId=391641
+
+namespace Xamarin.Forms.ControlGallery.WindowsPhone
+{
+ /// <summary>
+ /// Provides application-specific behavior to supplement the default Application class.
+ /// </summary>
+ public sealed partial class App
+ {
+ TransitionCollection _transitions;
+
+ /// <summary>
+ /// Initializes the singleton application object. This is the first line of authored code
+ /// executed, and as such is the logical equivalent of main() or WinMain().
+ /// </summary>
+ public App()
+ {
+ InitializeComponent();
+ Suspending += OnSuspending;
+ }
+
+ /// <summary>
+ /// Invoked when the application is launched normally by the end user. Other entry points
+ /// will be used when the application is launched to open a specific file, to display
+ /// search results, and so forth.
+ /// </summary>
+ /// <param name="e">Details about the launch request and process.</param>
+ protected override void OnLaunched(LaunchActivatedEventArgs e)
+ {
+#if DEBUG
+ if (System.Diagnostics.Debugger.IsAttached)
+ {
+ DebugSettings.EnableFrameRateCounter = true;
+ }
+#endif
+
+ var rootFrame = Window.Current.Content as global::Windows.UI.Xaml.Controls.Frame;
+
+ // Do not repeat app initialization when the Window already has content,
+ // just ensure that the window is active
+ if (rootFrame == null)
+ {
+ // Create a Frame to act as the navigation context and navigate to the first page
+ rootFrame = new global::Windows.UI.Xaml.Controls.Frame();
+
+ // TODO: change this value to a cache size that is appropriate for your application
+ rootFrame.CacheSize = 1;
+
+ Forms.Init (e);
+ FormsMaps.Init (Controls.App.Secrets["WinPhoneMapsAuthKey"]);
+
+ if (e.PreviousExecutionState == ApplicationExecutionState.Terminated)
+ {
+ // TODO: Load state from previously suspended application
+ }
+
+ // Place the frame in the current Window
+ Window.Current.Content = rootFrame;
+ }
+
+ if (rootFrame.Content == null)
+ {
+ // Removes the turnstile navigation for startup.
+ if (rootFrame.ContentTransitions != null)
+ {
+ _transitions = new TransitionCollection();
+ foreach (var c in rootFrame.ContentTransitions)
+ {
+ _transitions.Add(c);
+ }
+ }
+
+ rootFrame.ContentTransitions = null;
+ rootFrame.Navigated += RootFrame_FirstNavigated;
+
+ // When the navigation stack isn't restored navigate to the first page,
+ // configuring the new page by passing required information as a navigation
+ // parameter
+ if (!rootFrame.Navigate(typeof(MainPage), e.Arguments))
+ {
+ throw new Exception("Failed to create initial page");
+ }
+ }
+
+ // Ensure the current window is active
+ Window.Current.Activate();
+ }
+
+ /// <summary>
+ /// Restores the content transitions after the app has launched.
+ /// </summary>
+ /// <param name="sender">The object where the handler is attached.</param>
+ /// <param name="e">Details about the navigation event.</param>
+ void RootFrame_FirstNavigated(object sender, global::Windows.UI.Xaml.Navigation.NavigationEventArgs e)
+ {
+ var rootFrame = sender as global::Windows.UI.Xaml.Controls.Frame;
+ rootFrame.ContentTransitions = _transitions ?? new TransitionCollection() { new NavigationThemeTransition() };
+ rootFrame.Navigated -= RootFrame_FirstNavigated;
+ }
+
+ /// <summary>
+ /// Invoked when application execution is being suspended. Application state is saved
+ /// without knowing whether the application will be terminated or resumed with the contents
+ /// of memory still intact.
+ /// </summary>
+ /// <param name="sender">The source of the suspend request.</param>
+ /// <param name="e">Details about the suspend request.</param>
+ void OnSuspending(object sender, SuspendingEventArgs e)
+ {
+ var deferral = e.SuspendingOperation.GetDeferral();
+
+ // TODO: Save application state and stop any background activity
+ deferral.Complete();
+ }
+ }
+} \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Logo.scale-240.png b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Logo.scale-240.png
new file mode 100644
index 00000000..76921ca9
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Logo.scale-240.png
Binary files differ
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SmallLogo.scale-240.png b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SmallLogo.scale-240.png
new file mode 100644
index 00000000..31663012
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SmallLogo.scale-240.png
Binary files differ
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SplashScreen.scale-240.png b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SplashScreen.scale-240.png
new file mode 100644
index 00000000..33f26b33
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/SplashScreen.scale-240.png
Binary files differ
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Square71x71Logo.scale-240.png b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Square71x71Logo.scale-240.png
new file mode 100644
index 00000000..cfa54bee
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/Square71x71Logo.scale-240.png
Binary files differ
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/StoreLogo.scale-240.png b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/StoreLogo.scale-240.png
new file mode 100644
index 00000000..47e084b5
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/StoreLogo.scale-240.png
Binary files differ
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/WideLogo.scale-240.png b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/WideLogo.scale-240.png
new file mode 100644
index 00000000..6249d29d
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Assets/WideLogo.scale-240.png
Binary files differ
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/BrokenNativeControl.cs b/Xamarin.Forms.ControlGallery.WindowsPhone/BrokenNativeControl.cs
new file mode 100644
index 00000000..5be6db25
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/BrokenNativeControl.cs
@@ -0,0 +1,65 @@
+using Windows.Foundation;
+using Windows.Graphics.Display;
+using Windows.UI;
+using Windows.UI.Xaml;
+using Windows.UI.Xaml.Controls;
+using Windows.UI.Xaml.Media;
+using WSize = Windows.Foundation.Size;
+
+namespace Xamarin.Forms.ControlGallery.WindowsPhone
+{
+ internal class BrokenNativeControl : Panel
+ {
+ public BrokenNativeControl ()
+ {
+ _textBlock = new TextBlock {
+ MinHeight = 0,
+ MaxHeight = double.PositiveInfinity,
+ MinWidth = 0,
+ MaxWidth = double.PositiveInfinity,
+ FontSize = 24,
+ HorizontalAlignment = HorizontalAlignment.Center
+ };
+
+ Children.Add (_textBlock);
+
+ Background =
+ new LinearGradientBrush (
+ new GradientStopCollection { new GradientStop { Color = Colors.Green, Offset = 0.5}, new GradientStop { Color = Colors.Blue, Offset = 1} }, 0);
+ }
+
+ public static readonly DependencyProperty TextProperty = DependencyProperty.Register (
+ "Text", typeof(string), typeof(BrokenNativeControl), new PropertyMetadata (default(string), PropertyChangedCallback));
+
+ static void PropertyChangedCallback (DependencyObject dependencyObject,
+ DependencyPropertyChangedEventArgs dependencyPropertyChangedEventArgs)
+ {
+ ((BrokenNativeControl)dependencyObject)._textBlock.Text = (string)dependencyPropertyChangedEventArgs.NewValue;
+ }
+
+ public string Text
+ {
+ get { return (string)GetValue (TextProperty); }
+ set { SetValue (TextProperty, value); }
+ }
+
+ readonly TextBlock _textBlock;
+
+ protected override WSize ArrangeOverride(WSize finalSize)
+ {
+ _textBlock.Arrange(new Rect(0, 0, finalSize.Width, finalSize.Height));
+ return finalSize;
+ }
+
+ protected override WSize MeasureOverride (WSize availableSize)
+ {
+ _textBlock.Measure (availableSize);
+
+ // This deliberately does something wrong so we can demo fixing it
+ var width = Window.Current.Bounds.Width * (int)DisplayProperties.ResolutionScale / 100;
+
+ // This deliberately does something wrong so we can demo fixing it
+ return new WSize (width, _textBlock.DesiredSize.Height);
+ }
+ }
+} \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml b/Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml
new file mode 100644
index 00000000..0ce7c4aa
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml
@@ -0,0 +1,11 @@
+<winRt:WindowsPhonePage
+ x:Class="Xamarin.Forms.ControlGallery.WindowsPhone.MainPage"
+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:local="using:Xamarin.Forms.ControlGallery.WindowsPhone"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:winRt="using:Xamarin.Forms.Platform.WinRT"
+ mc:Ignorable="d">
+
+</winRt:WindowsPhonePage>
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml.cs b/Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml.cs
new file mode 100644
index 00000000..1c34efd6
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/MainPage.xaml.cs
@@ -0,0 +1,108 @@
+using System;
+using Windows.Foundation;
+using Windows.Graphics.Display;
+using Windows.UI.Xaml;
+using Windows.UI.Xaml.Controls;
+using Windows.UI.Xaml.Media;
+using Xamarin.Forms.Controls;
+using WControls = Windows.UI.Xaml.Controls;
+using Xamarin.Forms.Platform.WinRT;
+
+// The Blank Page item template is documented at http://go.microsoft.com/fwlink/?LinkId=391641
+
+namespace Xamarin.Forms.ControlGallery.WindowsPhone
+{
+ /// <summary>
+ /// An empty page that can be used on its own or navigated to within a Frame.
+ /// </summary>
+ public sealed partial class MainPage
+ {
+ public MainPage ()
+ {
+ InitializeComponent ();
+
+ var app = new Controls.App ();
+
+ var mdp = app.MainPage as MasterDetailPage;
+
+ var detail = mdp?.Detail as NavigationPage;
+ if (detail != null) {
+ detail.Pushed += (sender, args) => {
+ var nncgPage = args.Page as NestedNativeControlGalleryPage;
+
+ if (nncgPage != null) {
+ AddNativeControls (nncgPage);
+ }
+ };
+ }
+
+ LoadApplication (app);
+ }
+
+ void AddNativeControls (NestedNativeControlGalleryPage page)
+ {
+ if (page.NativeControlsAdded) {
+ return;
+ }
+
+ StackLayout sl = page.Layout;
+
+ // Create and add a native TextBlock
+ var originalText = "I am a native TextBlock";
+ var textBlock = new TextBlock {
+ Text = originalText,
+ FontSize = 14,
+ FontFamily = new FontFamily ("HelveticaNeue")
+ };
+
+ sl?.Children.Add (textBlock);
+
+ // Create and add a native Button
+ var button = new WControls.Button { Content = "Click to toggle font size", Height = 80 };
+ button.Click += (sender, args) => { textBlock.FontSize = textBlock.FontSize == 14 ? 24 : 14; };
+
+ sl?.Children.Add (button.ToView ());
+
+ // Create a control which we know doesn't behave correctly with regard to measurement
+ var difficultControl = new BrokenNativeControl {
+ Text = "Not Sized/Arranged Properly"
+ };
+
+ var difficultControl2 = new BrokenNativeControl {
+ Text = "Fixed"
+ };
+
+ // Add the misbehaving controls, one with a custom delegate for ArrangeOverrideDelegate
+ sl?.Children.Add (difficultControl);
+ sl?.Children.Add (difficultControl2,
+ arrangeOverrideDelegate: (renderer, finalSize) => {
+ if (finalSize.Width <= 0 || double.IsInfinity (finalSize.Width)) {
+ return null;
+ }
+
+ FrameworkElement frameworkElement = renderer.Control;
+
+ frameworkElement.Measure (finalSize);
+
+ // The broken control tries sizes itself to be the width of the screen
+ var wrongSize = Window.Current.Bounds.Width * (int)DisplayProperties.ResolutionScale / 100;
+
+ // The broken control always sizes itself to be 600 wide
+ // We can re-center it by offsetting it during the Arrange call
+ double diff = Math.Abs(finalSize.Width - wrongSize) / -2;
+ frameworkElement.Arrange (new Rect (diff, 0, finalSize.Width - diff, finalSize.Height));
+
+ // Arranging the control to the left will make it show up past the edge of the master page
+ // We can fix that by clipping it manually
+ var clip = new RectangleGeometry { Rect = new Rect (-diff, 0, finalSize.Width, finalSize.Height) };
+ frameworkElement.Clip = clip;
+
+ return finalSize;
+ }
+ );
+
+ page.NativeControlsAdded = true;
+ }
+
+ }
+}
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Package.appxmanifest b/Xamarin.Forms.ControlGallery.WindowsPhone/Package.appxmanifest
new file mode 100644
index 00000000..b47c1316
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Package.appxmanifest
@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Package xmlns="http://schemas.microsoft.com/appx/2010/manifest" xmlns:m2="http://schemas.microsoft.com/appx/2013/manifest" xmlns:m3="http://schemas.microsoft.com/appx/2014/manifest" xmlns:mp="http://schemas.microsoft.com/appx/2014/phone/manifest">
+ <Identity Name="7d1da7bc-9b18-4581-9184-6b674b7a3dbe" Publisher="CN=Eric" Version="1.0.0.0" />
+ <mp:PhoneIdentity PhoneProductId="7d1da7bc-9b18-4581-9184-6b674b7a3dbe" PhonePublisherId="00000000-0000-0000-0000-000000000000" />
+ <Properties>
+ <DisplayName>Xamarin.Forms.ControlGallery.WindowsPhone</DisplayName>
+ <PublisherDisplayName>Eric</PublisherDisplayName>
+ <Logo>Assets\StoreLogo.png</Logo>
+ </Properties>
+ <Prerequisites>
+ <OSMinVersion>6.3.1</OSMinVersion>
+ <OSMaxVersionTested>6.3.1</OSMaxVersionTested>
+ </Prerequisites>
+ <Resources>
+ <Resource Language="x-generate" />
+ </Resources>
+ <Applications>
+ <Application Id="App" Executable="$targetnametoken$.exe" EntryPoint="Xamarin.Forms.ControlGallery.WindowsPhone.App">
+ <m3:VisualElements DisplayName="Xamarin.Forms.ControlGallery.WindowsPhone" Square150x150Logo="Assets\Logo.png" Square44x44Logo="Assets\SmallLogo.png" Description="Xamarin.Forms.ControlGallery.WindowsPhone" ForegroundText="light" BackgroundColor="transparent">
+ <m3:DefaultTile Wide310x150Logo="Assets\WideLogo.png" Square71x71Logo="Assets\Square71x71Logo.png">
+ </m3:DefaultTile>
+ <m3:SplashScreen Image="Assets\SplashScreen.png" />
+ <m3:InitialRotationPreference>
+ <m3:Rotation Preference="portrait" />
+ <m3:Rotation Preference="landscape" />
+ <m3:Rotation Preference="landscapeFlipped" />
+ </m3:InitialRotationPreference>
+ </m3:VisualElements>
+ </Application>
+ </Applications>
+ <Capabilities>
+ <Capability Name="internetClientServer" />
+ </Capabilities>
+</Package> \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Properties/AssemblyInfo.cs b/Xamarin.Forms.ControlGallery.WindowsPhone/Properties/AssemblyInfo.cs
new file mode 100644
index 00000000..7be28e92
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Properties/AssemblyInfo.cs
@@ -0,0 +1,29 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+
+// General Information about an assembly is controlled through the following
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("Xamarin.Forms.ControlGallery.WindowsPhone")]
+[assembly: AssemblyDescription("")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("Xamarin.Forms.ControlGallery.WindowsPhone")]
+[assembly: AssemblyCopyright("Copyright © 2015")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Version information for an assembly consists of the following four values:
+//
+// Major Version
+// Minor Version
+// Build Number
+// Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
+[assembly: ComVisible(false)] \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/StringProvider.cs b/Xamarin.Forms.ControlGallery.WindowsPhone/StringProvider.cs
new file mode 100644
index 00000000..f6baddfa
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/StringProvider.cs
@@ -0,0 +1,15 @@
+using Xamarin.Forms;
+using Xamarin.Forms.ControlGallery.Windows;
+using Xamarin.Forms.Controls;
+
+[assembly: Dependency (typeof (StringProvider))]
+
+namespace Xamarin.Forms.ControlGallery.Windows
+{
+ public class StringProvider : IStringProvider
+ {
+ public string CoreGalleryTitle {
+ get { return "Windows Core Gallery"; }
+ }
+ }
+}
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/Xamarin.Forms.ControlGallery.WindowsPhone.csproj b/Xamarin.Forms.ControlGallery.WindowsPhone/Xamarin.Forms.ControlGallery.WindowsPhone.csproj
new file mode 100644
index 00000000..50c990ce
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/Xamarin.Forms.ControlGallery.WindowsPhone.csproj
@@ -0,0 +1,187 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
+ <PropertyGroup>
+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+ <ProjectGuid>{8CDEC974-E6BE-4424-BC77-0B87400A08AF}</ProjectGuid>
+ <OutputType>AppContainerExe</OutputType>
+ <AppDesignerFolder>Properties</AppDesignerFolder>
+ <RootNamespace>Xamarin.Forms.ControlGallery.WindowsPhone</RootNamespace>
+ <AssemblyName>Xamarin.Forms.ControlGallery.WindowsPhone</AssemblyName>
+ <DefaultLanguage>en-US</DefaultLanguage>
+ <TargetPlatformVersion>8.1</TargetPlatformVersion>
+ <MinimumVisualStudioVersion>12</MinimumVisualStudioVersion>
+ <FileAlignment>512</FileAlignment>
+ <ProjectTypeGuids>{76F1466A-8B6D-4E39-A767-685A06062A39};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <DebugSymbols>true</DebugSymbols>
+ <DebugType>full</DebugType>
+ <Optimize>false</Optimize>
+ <OutputPath>bin\Debug\</OutputPath>
+ <DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_PHONE_APP</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+ <PlatformTarget>AnyCPU</PlatformTarget>
+ <DebugType>pdbonly</DebugType>
+ <Optimize>true</Optimize>
+ <OutputPath>bin\Release\</OutputPath>
+ <DefineConstants>TRACE;NETFX_CORE;WINDOWS_PHONE_APP</DefineConstants>
+ <ErrorReport>prompt</ErrorReport>
+ <WarningLevel>4</WarningLevel>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|ARM'">
+ <DebugSymbols>true</DebugSymbols>
+ <OutputPath>bin\ARM\Debug\</OutputPath>
+ <DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_PHONE_APP</DefineConstants>
+ <NoWarn>;2008</NoWarn>
+ <DebugType>full</DebugType>
+ <PlatformTarget>ARM</PlatformTarget>
+ <UseVSHostingProcess>false</UseVSHostingProcess>
+ <ErrorReport>prompt</ErrorReport>
+ <Prefer32Bit>true</Prefer32Bit>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|ARM'">
+ <OutputPath>bin\ARM\Release\</OutputPath>
+ <DefineConstants>TRACE;NETFX_CORE;WINDOWS_PHONE_APP</DefineConstants>
+ <Optimize>true</Optimize>
+ <NoWarn>;2008</NoWarn>
+ <DebugType>pdbonly</DebugType>
+ <PlatformTarget>ARM</PlatformTarget>
+ <UseVSHostingProcess>false</UseVSHostingProcess>
+ <ErrorReport>prompt</ErrorReport>
+ <Prefer32Bit>true</Prefer32Bit>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
+ <DebugSymbols>true</DebugSymbols>
+ <OutputPath>bin\x86\Debug\</OutputPath>
+ <DefineConstants>DEBUG;TRACE;NETFX_CORE;WINDOWS_PHONE_APP</DefineConstants>
+ <NoWarn>;2008</NoWarn>
+ <DebugType>full</DebugType>
+ <PlatformTarget>x86</PlatformTarget>
+ <UseVSHostingProcess>false</UseVSHostingProcess>
+ <ErrorReport>prompt</ErrorReport>
+ <Prefer32Bit>true</Prefer32Bit>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
+ <OutputPath>bin\x86\Release\</OutputPath>
+ <DefineConstants>TRACE;NETFX_CORE;WINDOWS_PHONE_APP</DefineConstants>
+ <Optimize>true</Optimize>
+ <NoWarn>;2008</NoWarn>
+ <DebugType>pdbonly</DebugType>
+ <PlatformTarget>x86</PlatformTarget>
+ <UseVSHostingProcess>false</UseVSHostingProcess>
+ <ErrorReport>prompt</ErrorReport>
+ <Prefer32Bit>true</Prefer32Bit>
+ </PropertyGroup>
+ <ItemGroup>
+ <!-- A reference to the entire .Net Framework and Windows SDK are automatically included -->
+ <ProjectReference Include="..\Xamarin.Forms.Controls\Xamarin.Forms.Controls.csproj">
+ <Project>{cb9c96ce-125c-4a68-b6a1-c3ff1fbf93e1}</Project>
+ <Name>Xamarin.Forms.Controls</Name>
+ </ProjectReference>
+ <ProjectReference Include="..\Xamarin.Forms.Core\Xamarin.Forms.Core.csproj">
+ <Project>{57b8b73d-c3b5-4c42-869e-7b2f17d354ac}</Project>
+ <Name>Xamarin.Forms.Core</Name>
+ </ProjectReference>
+ <ProjectReference Include="..\Xamarin.Forms.Maps.WinRT.Phone\Xamarin.Forms.Maps.WinRT.Phone.csproj">
+ <Project>{2633af57-f2cb-442a-ac19-f97bd8a06571}</Project>
+ <Name>Xamarin.Forms.Maps.WinRT.Phone</Name>
+ </ProjectReference>
+ <ProjectReference Include="..\Xamarin.Forms.Platform.WinRT.Phone\Xamarin.Forms.Platform.WinRT.Phone.csproj">
+ <Project>{3361d52c-2e74-433e-8285-9c9a5c485977}</Project>
+ <Name>Xamarin.Forms.Platform.WinRT.Phone</Name>
+ </ProjectReference>
+ <ProjectReference Include="..\Xamarin.Forms.Platform.WinRT\Xamarin.Forms.Platform.WinRT.csproj">
+ <Project>{f3fdd7ac-8899-4e41-bfd7-ec83403e736d}</Project>
+ <Name>Xamarin.Forms.Platform.WinRT</Name>
+ </ProjectReference>
+ </ItemGroup>
+ <ItemGroup>
+ <Compile Include="App.xaml.cs">
+ <DependentUpon>App.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="BrokenNativeControl.cs" />
+ <Compile Include="MainPage.xaml.cs">
+ <DependentUpon>MainPage.xaml</DependentUpon>
+ </Compile>
+ <Compile Include="Properties\AssemblyInfo.cs" />
+ <Compile Include="StringProvider.cs" />
+ </ItemGroup>
+ <ItemGroup>
+ <AppxManifest Include="Package.appxmanifest">
+ <SubType>Designer</SubType>
+ </AppxManifest>
+ </ItemGroup>
+ <ItemGroup>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\bank.png">
+ <Link>bank.png</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\cover1.jpg">
+ <Link>cover1.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\cover1small.jpg">
+ <Link>cover1small.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\crimson.jpg">
+ <Link>crimson.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\crimsonsmall.jpg">
+ <Link>crimsonsmall.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\menuIcon.png">
+ <Link>menuIcon.png</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\oasis.jpg">
+ <Link>oasis.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\oasissmall.jpg">
+ <Link>oasissmall.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\photo.jpg">
+ <Link>photo.jpg</Link>
+ </Content>
+ <Content Include="..\Xamarin.Forms.ControlGallery.WP8\seth.png">
+ <Link>seth.png</Link>
+ </Content>
+ <Content Include="Assets\Logo.scale-240.png" />
+ <Content Include="Assets\SmallLogo.scale-240.png" />
+ <Content Include="Assets\SplashScreen.scale-240.png" />
+ <Content Include="Assets\Square71x71Logo.scale-240.png" />
+ <Content Include="Assets\StoreLogo.scale-240.png" />
+ <Content Include="Assets\WideLogo.scale-240.png" />
+ <Content Include="toolbar_close.png" />
+ </ItemGroup>
+ <ItemGroup>
+ <ApplicationDefinition Include="App.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </ApplicationDefinition>
+ <Page Include="MainPage.xaml">
+ <Generator>MSBuild:Compile</Generator>
+ <SubType>Designer</SubType>
+ </Page>
+ </ItemGroup>
+ <ItemGroup>
+ <None Include="app.config" />
+ </ItemGroup>
+ <PropertyGroup Condition=" '$(VisualStudioVersion)' == '' or '$(VisualStudioVersion)' &lt; '12.0' ">
+ <VisualStudioVersion>12.0</VisualStudioVersion>
+ </PropertyGroup>
+ <PropertyGroup Condition=" '$(TargetPlatformIdentifier)' == '' ">
+ <TargetPlatformIdentifier>WindowsPhoneApp</TargetPlatformIdentifier>
+ </PropertyGroup>
+ <Import Project="$(MSBuildExtensionsPath)\Microsoft\WindowsXaml\v$(VisualStudioVersion)\Microsoft.Windows.UI.Xaml.CSharp.targets" />
+ <Import Project="$(XamlSpyInstallPath)MSBuild\FirstFloor.XamlSpy.WindowsPhone.targets" Condition="'$(XamlSpyInstallPath)' != '' and '$(Configuration)' == 'DEBUG'" />
+ <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
+ Other similar extension points exist, see Microsoft.Common.targets.
+ <Target Name="BeforeBuild">
+ </Target>
+ <Target Name="AfterBuild">
+ </Target>
+ -->
+</Project> \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/app.config b/Xamarin.Forms.ControlGallery.WindowsPhone/app.config
new file mode 100644
index 00000000..b1d2a5a3
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/app.config
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<configuration>
+ <runtime>
+ <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
+ <dependentAssembly>
+ <assemblyIdentity name="Mono.Cecil" publicKeyToken="0738eb9f132ed756" culture="neutral" />
+ <bindingRedirect oldVersion="0.0.0.0-0.9.6.0" newVersion="0.9.6.0" />
+ </dependentAssembly>
+ </assemblyBinding>
+ </runtime>
+</configuration> \ No newline at end of file
diff --git a/Xamarin.Forms.ControlGallery.WindowsPhone/toolbar_close.png b/Xamarin.Forms.ControlGallery.WindowsPhone/toolbar_close.png
new file mode 100644
index 00000000..12f82abb
--- /dev/null
+++ b/Xamarin.Forms.ControlGallery.WindowsPhone/toolbar_close.png
Binary files differ