From 8c5a5c0ea6f2b23254cf1a201a22668510162c8d Mon Sep 17 00:00:00 2001 From: Ricky Kresslein Date: Wed, 20 Apr 2022 10:19:03 +0300 Subject: Set default button in Delete All dialog --- src/application.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/application.rs b/src/application.rs index 2e57935..4edb64d 100755 --- a/src/application.rs +++ b/src/application.rs @@ -178,12 +178,14 @@ impl FurtheranceApplication { (&gettext("Cancel"), gtk::ResponseType::Reject), (&gettext("Delete"), gtk::ResponseType::Accept) ]); + dialog.set_default_response(gtk::ResponseType::Accept); let message_area = dialog.message_area().downcast::().unwrap(); let explanation = gtk::Label::new(Some(&gettext("This will delete ALL of your task history."))); let instructions = gtk::Label::new(Some( &gettext("Type DELETE in the box below then click Delete to proceed."))); let delete_entry = gtk::Entry::new(); + delete_entry.set_activates_default(true); message_area.append(&explanation); message_area.append(&instructions); message_area.append(&delete_entry); -- cgit 1.4.1