mirror of
https://github.com/KeyKeeperApp/KeyKeeper.git
synced 2026-05-09 01:46:31 +03:00
add password entry field and button to unlock screen
This commit is contained in:
@@ -52,7 +52,18 @@
|
|||||||
</Grid>
|
</Grid>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
<DataTemplate DataType="{x:Type vm:LockedRepositoryViewModel}">
|
<DataTemplate DataType="{x:Type vm:LockedRepositoryViewModel}">
|
||||||
|
<StackPanel Margin="20"
|
||||||
|
HorizontalAlignment="Center"
|
||||||
|
VerticalAlignment="Center">
|
||||||
|
<TextBox x:Name="UnlockPasswordEdit"
|
||||||
|
PasswordChar="*"
|
||||||
|
Width="450" />
|
||||||
|
|
||||||
|
<Button x:Name="UnlockButton"
|
||||||
|
HorizontalAlignment="Center"
|
||||||
|
Foreground="Black"
|
||||||
|
Content="Unlock!" />
|
||||||
|
</StackPanel>
|
||||||
</DataTemplate>
|
</DataTemplate>
|
||||||
</Window.DataTemplates>
|
</Window.DataTemplates>
|
||||||
|
|
||||||
|
|||||||
@@ -21,9 +21,9 @@ public class RepositoryWindowViewModel : ViewModelBase
|
|||||||
|
|
||||||
private void UpdateLockStatus()
|
private void UpdateLockStatus()
|
||||||
{
|
{
|
||||||
if (currentPage is LockedRepositoryViewModel && !passStore.Locked)
|
if ((currentPage == null || currentPage is LockedRepositoryViewModel) && !passStore.Locked)
|
||||||
SwitchToUnlocked();
|
SwitchToUnlocked();
|
||||||
else if (currentPage is UnlockedRepositoryViewModel && passStore.Locked)
|
else if ((currentPage == null || currentPage is UnlockedRepositoryViewModel) && passStore.Locked)
|
||||||
SwitchToLocked();
|
SwitchToLocked();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user