mirror of
https://github.com/wismna/ModernKeePass.git
synced 2025-10-03 15:40:18 -04:00
WIP strings in ressource file (XAML is done, code-behind is not)
Invalid URI now shows a message Create entry is now a link above entries Entries gridview allows reordering (WIP enable it conditionnally) Code cleanup in adding/removing PwEntries from VM
This commit is contained in:
@@ -226,7 +226,6 @@ namespace ModernKeePass.ViewModels
|
||||
{
|
||||
PreviousGroup = ParentGroup;
|
||||
PreviousGroup.Entries.Remove(this);
|
||||
PreviousGroup.RemovePwEntry(_pwEntry);
|
||||
if (destination == null)
|
||||
{
|
||||
_database.AddDeletedItem(IdUuid);
|
||||
@@ -234,19 +233,22 @@ namespace ModernKeePass.ViewModels
|
||||
}
|
||||
ParentGroup = destination;
|
||||
ParentGroup.Entries.Add(this);
|
||||
ParentGroup.AddPwEntry(_pwEntry);
|
||||
}
|
||||
|
||||
public void CommitDelete()
|
||||
{
|
||||
_pwEntry.ParentGroup.Entries.Remove(_pwEntry);
|
||||
if (_database.RecycleBinEnabled && !PreviousGroup.IsSelected) _database.RecycleBin.AddPwEntry(_pwEntry);
|
||||
else _database.AddDeletedItem(IdUuid);
|
||||
if (!_database.RecycleBinEnabled || PreviousGroup.IsSelected) _database.AddDeletedItem(IdUuid);
|
||||
}
|
||||
|
||||
public void Save()
|
||||
{
|
||||
_database.Save();
|
||||
}
|
||||
|
||||
public PwEntry GetPwEntry()
|
||||
{
|
||||
return _pwEntry;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user