mirror of
https://github.com/wismna/ModernKeePass.git
synced 2025-10-03 15:40:18 -04:00
Create database works with new Vm
Refactoring
This commit is contained in:
@@ -1,28 +0,0 @@
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
namespace ModernKeePass.Domain.AOP
|
||||
{
|
||||
public class NotifyPropertyChangedBase : INotifyPropertyChanged
|
||||
{
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
protected void OnPropertyChanged(string propertyName = "")
|
||||
{
|
||||
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
|
||||
protected bool SetProperty<T>(ref T property, T value, [CallerMemberName] string propertyName = "")
|
||||
{
|
||||
if (EqualityComparer<T>.Default.Equals(property, value))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
property = value;
|
||||
OnPropertyChanged(propertyName);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
@@ -75,7 +75,6 @@
|
||||
<None Include="project.json" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="AOP\NotifyPropertyChangedBase.cs" />
|
||||
<Compile Include="Common\Constants.cs" />
|
||||
<Compile Include="Dtos\Credentials.cs" />
|
||||
<Compile Include="Dtos\FileInfo.cs" />
|
||||
|
@@ -3,6 +3,7 @@
|
||||
public enum DatabaseVersion
|
||||
{
|
||||
V2,
|
||||
V3,
|
||||
V4
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user