diff options
author | Kangho Hur <kangho.hur@samsung.com> | 2017-01-19 09:22:48 +0900 |
---|---|---|
committer | Kangho Hur <kangho.hur@samsung.com> | 2017-04-24 13:36:50 +0900 |
commit | a0336a7783ee77ca8cf44a1c67c67672e0b455f5 (patch) | |
tree | 21c4f303b1669afa45f9aabea5917c8340418366 | |
parent | 1e4cc606776fd8e64f76226882000a07c1a7beff (diff) | |
download | xamarin-forms-a0336a7783ee77ca8cf44a1c67c67672e0b455f5.tar.gz xamarin-forms-a0336a7783ee77ca8cf44a1c67c67672e0b455f5.tar.bz2 xamarin-forms-a0336a7783ee77ca8cf44a1c67c67672e0b455f5.zip |
Apply to default layout for the forms application
Change-Id: Ieb55d1b2f1a3deb29db9a7ccc8c3009d7553ed2e
-rw-r--r-- | Xamarin.Forms.Platform.Tizen/Native/Window.cs | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/Xamarin.Forms.Platform.Tizen/Native/Window.cs b/Xamarin.Forms.Platform.Tizen/Native/Window.cs index 87a54cd3..7587e17c 100644 --- a/Xamarin.Forms.Platform.Tizen/Native/Window.cs +++ b/Xamarin.Forms.Platform.Tizen/Native/Window.cs @@ -1,11 +1,13 @@ using System; using ElmSharp; using EWindow = ElmSharp.Window; +using ELayout = ElmSharp.Layout; namespace Xamarin.Forms.Platform.Tizen.Native { public class Window : EWindow { + ELayout _layout; Conformant _conformant; /// <summary> @@ -69,13 +71,26 @@ namespace Xamarin.Forms.Platform.Tizen.Native } } + public ELayout BaseLayout + { + get + { + return _layout; + } + + private set + { + _layout = value; + } + } + /// <summary> /// Sets the main page of Window. /// </summary> /// <param name="content">ElmSharp.EvasObject type page to be set.</param> public void SetMainPage(EvasObject content) { - _conformant.SetContent(content); + _layout.SetContent(content); } void Initialize() @@ -112,6 +127,15 @@ namespace Xamarin.Forms.Platform.Tizen.Native _conformant.SetWeight(1.0, 1.0); // expand _conformant.Show(); + // Create the base (default) layout for the application + _layout = new ELayout(_conformant); + _layout.SetAlignment(-1.0, -1.0); // fill + _layout.SetWeight(1.0, 1.0); // expand + _layout.SetTheme("layout", "application", "default"); + _layout.Show(); + + _conformant.SetContent(_layout); + BaseLayout = _layout; AvailableOrientations = DisplayOrientations.Portrait | DisplayOrientations.Landscape | DisplayOrientations.PortraitFlipped | DisplayOrientations.LandscapeFlipped; } DisplayOrientations GetDisplayOrientation() |