Support permanently deleting files and directories using Shift+Del

Add a confirmation dialog to limit risks of data lost.
This commit is contained in:
Tim Dengel 2024-08-12 05:23:04 +02:00 committed by Gwen Lg
parent 8ced8b0551
commit 1a66d7b184
4 changed files with 97 additions and 1 deletions

View file

@ -68,6 +68,7 @@ pub fn key_binds(mode: &tab::Mode) -> HashMap<KeyBind, Action> {
bind!([Ctrl], Key::Character("c".into()), Copy);
bind!([Ctrl], Key::Character("x".into()), Cut);
bind!([], Key::Named(Named::Delete), Delete);
bind!([Shift], Key::Named(Named::Delete), PermanentlyDelete);
bind!([Shift], Key::Named(Named::Enter), OpenInNewWindow);
bind!([Ctrl], Key::Character("v".into()), Paste);
bind!([], Key::Named(Named::F2), Rename);