1
0
mirror of https://github.com/bitwarden/mobile.git synced 2024-06-25 10:26:02 +02:00

pin lock page modifications

This commit is contained in:
Kyle Spearrin 2016-06-06 21:13:00 -04:00
parent 89e4189779
commit 15e154feb0
4 changed files with 20 additions and 3 deletions

View File

@ -76,6 +76,12 @@ namespace Bit.App
{
CheckLockAsync(false);
}
var lockPage = Current.MainPage.Navigation.ModalStack.LastOrDefault() as LockPinPage;
if(lockPage != null)
{
lockPage.PinControl.Entry.Focus();
}
}
private async Task CheckLockAsync(bool forceLock)

View File

@ -24,8 +24,8 @@ namespace Bit.App.Controls
Entry = new ExtendedEntry
{
Keyboard = Keyboard.Numeric,
IsVisible = false,
MaxLength = 4
MaxLength = 4,
Margin = new Thickness(0, int.MaxValue, 0, 0)
};
Entry.SetBinding<PinPageModel>(Xamarin.Forms.Entry.TextProperty, s => s.PIN);
Entry.TextChanged += PinEntry_TextChanged;

View File

@ -55,6 +55,11 @@ namespace Bit.App.Pages
Content = stackLayout;
}
protected override bool OnBackButtonPressed()
{
return false;
}
protected override void OnAppearing()
{
base.OnAppearing();

View File

@ -46,7 +46,7 @@ namespace Bit.App.Pages
{
Padding = new Thickness(30, 40),
Spacing = 10,
Children = { PinControl.Label, PinControl.Entry, logoutButton }
Children = { PinControl.Label, logoutButton, PinControl.Entry }
};
Title = "Verify PIN";
@ -54,6 +54,12 @@ namespace Bit.App.Pages
BindingContext = Model;
}
protected override bool OnBackButtonPressed()
{
return false;
}
protected override void OnAppearing()
{
base.OnAppearing();