2019-03-29 00:10:10 +03:00
|
|
|
|
using Bit.App.Pages;
|
|
|
|
|
using System;
|
2019-03-30 00:54:03 +03:00
|
|
|
|
using System.Reflection;
|
2019-03-28 03:12:44 +03:00
|
|
|
|
using Xamarin.Forms;
|
2019-03-30 00:54:03 +03:00
|
|
|
|
using Xamarin.Forms.StyleSheets;
|
2019-03-28 03:12:44 +03:00
|
|
|
|
using Xamarin.Forms.Xaml;
|
|
|
|
|
|
|
|
|
|
[assembly: XamlCompilation(XamlCompilationOptions.Compile)]
|
|
|
|
|
namespace Bit.App
|
|
|
|
|
{
|
|
|
|
|
public partial class App : Application
|
|
|
|
|
{
|
|
|
|
|
public App()
|
|
|
|
|
{
|
|
|
|
|
InitializeComponent();
|
2019-03-30 00:54:03 +03:00
|
|
|
|
|
|
|
|
|
// TODO: Load theme?
|
|
|
|
|
if(false)
|
|
|
|
|
{
|
|
|
|
|
#pragma warning disable CS0162 // Unreachable code detected
|
|
|
|
|
Resources.Add(
|
|
|
|
|
#pragma warning restore CS0162 // Unreachable code detected
|
|
|
|
|
StyleSheet.FromAssemblyResource(IntrospectionExtensions.GetTypeInfo(typeof(App)).Assembly,
|
|
|
|
|
"Bit.App.Css.dark.css"));
|
|
|
|
|
}
|
|
|
|
|
Resources.Add(
|
|
|
|
|
StyleSheet.FromAssemblyResource(IntrospectionExtensions.GetTypeInfo(typeof(App)).Assembly,
|
|
|
|
|
"Bit.App.Css.styles.css"));
|
|
|
|
|
Resources.Add(
|
|
|
|
|
StyleSheet.FromAssemblyResource(IntrospectionExtensions.GetTypeInfo(typeof(App)).Assembly,
|
|
|
|
|
$"Bit.App.Css.{Device.RuntimePlatform.ToLowerInvariant()}.css"));
|
|
|
|
|
|
2019-03-29 06:52:33 +03:00
|
|
|
|
MainPage = new TabsPage();
|
2019-03-28 03:12:44 +03:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override void OnStart()
|
|
|
|
|
{
|
|
|
|
|
// Handle when your app starts
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override void OnSleep()
|
|
|
|
|
{
|
|
|
|
|
// Handle when your app sleeps
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected override void OnResume()
|
|
|
|
|
{
|
|
|
|
|
// Handle when your app resumes
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|