mirror of
https://github.com/bitwarden/android.git
synced 2024-12-24 18:08:26 +03:00
splash
This commit is contained in:
parent
baf77eb3a3
commit
9cb141ef62
3 changed files with 41 additions and 1 deletions
|
@ -66,6 +66,7 @@
|
||||||
<PackageReference Include="Xamarin.Android.Support.v7.MediaRouter" Version="28.0.0.1" />
|
<PackageReference Include="Xamarin.Android.Support.v7.MediaRouter" Version="28.0.0.1" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<Compile Include="SplashActivity.cs" />
|
||||||
<Compile Include="Renderers\BoxedView\BoxedViewRecyclerAdapter.cs" />
|
<Compile Include="Renderers\BoxedView\BoxedViewRecyclerAdapter.cs" />
|
||||||
<Compile Include="Renderers\BoxedView\BoxedViewRenderer.cs" />
|
<Compile Include="Renderers\BoxedView\BoxedViewRenderer.cs" />
|
||||||
<Compile Include="Renderers\BoxedView\BoxedViewSimpleCallback.cs" />
|
<Compile Include="Renderers\BoxedView\BoxedViewSimpleCallback.cs" />
|
||||||
|
|
|
@ -7,9 +7,9 @@ namespace Bit.Droid
|
||||||
{
|
{
|
||||||
[Activity(
|
[Activity(
|
||||||
Label = "Bitwarden",
|
Label = "Bitwarden",
|
||||||
MainLauncher = true,
|
|
||||||
Icon = "@mipmap/ic_launcher",
|
Icon = "@mipmap/ic_launcher",
|
||||||
Theme = "@style/MainTheme",
|
Theme = "@style/MainTheme",
|
||||||
|
Exported = false,
|
||||||
ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)]
|
ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)]
|
||||||
[Register("com.x8bit.bitwarden.MainActivity")]
|
[Register("com.x8bit.bitwarden.MainActivity")]
|
||||||
public class MainActivity : Xamarin.Forms.Platform.Android.FormsAppCompatActivity
|
public class MainActivity : Xamarin.Forms.Platform.Android.FormsAppCompatActivity
|
||||||
|
|
39
src/Android/SplashActivity.cs
Normal file
39
src/Android/SplashActivity.cs
Normal file
|
@ -0,0 +1,39 @@
|
||||||
|
using Android.App;
|
||||||
|
using Android.Content.PM;
|
||||||
|
using Android.Runtime;
|
||||||
|
using Android.OS;
|
||||||
|
using Android.Support.V7.App;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
using Android.Content;
|
||||||
|
|
||||||
|
namespace Bit.Droid
|
||||||
|
{
|
||||||
|
[Activity(
|
||||||
|
Label = "Bitwarden",
|
||||||
|
MainLauncher = true,
|
||||||
|
NoHistory = true,
|
||||||
|
Icon = "@mipmap/ic_launcher",
|
||||||
|
Theme = "@style/MainTheme.Splash",
|
||||||
|
WindowSoftInputMode = Android.Views.SoftInput.StateHidden,
|
||||||
|
ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)]
|
||||||
|
[Register("com.x8bit.bitwarden.SplashActivity")]
|
||||||
|
public class SplashActivity : AppCompatActivity
|
||||||
|
{
|
||||||
|
public override void OnCreate(Bundle savedInstanceState, PersistableBundle persistentState)
|
||||||
|
{
|
||||||
|
base.OnCreate(savedInstanceState, persistentState);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void OnResume()
|
||||||
|
{
|
||||||
|
base.OnResume();
|
||||||
|
var startupWork = new Task(() =>
|
||||||
|
{
|
||||||
|
var mainIntent = new Intent(Application.Context, typeof(MainActivity));
|
||||||
|
mainIntent.PutExtra("myVaultTile", Intent.GetBooleanExtra("myVaultTile", false));
|
||||||
|
StartActivity(mainIntent);
|
||||||
|
});
|
||||||
|
startupWork.Start();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue