mirror of
https://github.com/wismna/ModernKeePass.git
synced 2025-10-03 23:50:18 -04:00
Unregister the messenger everywhere on unload/navigate from
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
// The Blank Page item template is documented at http://go.microsoft.com/fwlink/?LinkId=234238
|
||||
|
||||
using Windows.UI.Xaml.Navigation;
|
||||
using ModernKeePass.ViewModels;
|
||||
|
||||
namespace ModernKeePass.Views
|
||||
{
|
||||
/// <summary>
|
||||
@@ -7,9 +10,16 @@ namespace ModernKeePass.Views
|
||||
/// </summary>
|
||||
public sealed partial class NewDatabasePage
|
||||
{
|
||||
public NewVm Model => (NewVm)DataContext;
|
||||
|
||||
public NewDatabasePage()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
protected override void OnNavigatedFrom(NavigationEventArgs e)
|
||||
{
|
||||
Model.Cleanup();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user