maui-linux/Xamarin.Forms.Platform.Tizen/PreloadedWindow.cs

43 строки
756 B
C#
Исходник Обычный вид История

using ElmSharp;
using Xamarin.Forms.Platform.Tizen.Native;
using ELayout = ElmSharp.Layout;
namespace Xamarin.Forms.Platform.Tizen
{
public class PreloadedWindow : Window
{
static PreloadedWindow s_precreated;
public PreloadedWindow() : base("FormsWindow-pre")
{
s_precreated = this;
Initialize();
}
public ELayout BaseLayout
{
get;
protected set;
}
protected void Initialize()
{
var conformant = new Conformant(this);
conformant.Show();
var layout = new ApplicationLayout(conformant);
layout.Show();
BaseLayout = layout;
conformant.SetContent(BaseLayout);
}
public static PreloadedWindow GetInstance()
{
var instance = s_precreated;
s_precreated = null;
return instance;
}
}
}