summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Core/PlatformConfiguration/WindowsSpecific/Page.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Xamarin.Forms.Core/PlatformConfiguration/WindowsSpecific/Page.cs')
-rw-r--r--Xamarin.Forms.Core/PlatformConfiguration/WindowsSpecific/Page.cs43
1 files changed, 43 insertions, 0 deletions
diff --git a/Xamarin.Forms.Core/PlatformConfiguration/WindowsSpecific/Page.cs b/Xamarin.Forms.Core/PlatformConfiguration/WindowsSpecific/Page.cs
new file mode 100644
index 00000000..59e53b5f
--- /dev/null
+++ b/Xamarin.Forms.Core/PlatformConfiguration/WindowsSpecific/Page.cs
@@ -0,0 +1,43 @@
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace Xamarin.Forms.PlatformConfiguration.WindowsSpecific
+{
+ using FormsElement = Forms.Page;
+
+ public static class Page
+ {
+ #region ToolbarPlacement
+
+ public static readonly BindableProperty ToolbarPlacementProperty =
+ BindableProperty.CreateAttached("ToolbarPlacement", typeof(ToolbarPlacement),
+ typeof(Page), ToolbarPlacement.Default);
+
+ public static ToolbarPlacement GetToolbarPlacement(BindableObject element)
+ {
+ return (ToolbarPlacement)element.GetValue(ToolbarPlacementProperty);
+ }
+
+ public static void SetToolbarPlacement(BindableObject element, ToolbarPlacement toolbarPlacement)
+ {
+ element.SetValue(ToolbarPlacementProperty, toolbarPlacement);
+ }
+
+ public static ToolbarPlacement GetToolbarPlacement(this IPlatformElementConfiguration<Windows, FormsElement> config)
+ {
+ return (ToolbarPlacement)config.Element.GetValue(ToolbarPlacementProperty);
+ }
+
+ public static IPlatformElementConfiguration<Windows, FormsElement> SetToolbarPlacement(
+ this IPlatformElementConfiguration<Windows, FormsElement> config, ToolbarPlacement value)
+ {
+ config.Element.SetValue(ToolbarPlacementProperty, value);
+ return config;
+ }
+
+ #endregion
+ }
+}