Recycle bin is now created when deleting first element instead of selecting new group in Settings

This commit is contained in:
bg45
2017-11-01 17:35:57 -04:00
committed by BONNEVILLE Geoffroy
parent 7e642e3b73
commit 82ef424365
5 changed files with 17 additions and 6 deletions

View File

@@ -1,6 +1,7 @@
using System;
using Windows.Storage;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using ModernKeePass.ViewModels;
using ModernKeePassLib;
using ModernKeePassLib.Interfaces;
@@ -129,5 +130,12 @@ namespace ModernKeePass.Common
{
_pwDatabase.DeletedObjects.Add(new PwDeletedObject(id, DateTime.UtcNow));
}
public void CreateRecycleBin()
{
RecycleBin = RootGroup.AddNewGroup("Recycle bin");
RecycleBin.IsSelected = true;
RecycleBin.IconSymbol = Symbol.Delete;
}
}
}