[Commits] [SCM] clawsker branch, master, updated. 1.1.1-5-gfbeef10

mones at claws-mail.org mones at claws-mail.org
Sat Jul 14 12:56:28 CEST 2018


The branch, master has been updated
       via  fbeef107fe07fa5220b4bec0c1ef8ebb6d657260 (commit)
      from  d2b9c2328c530bfe3501b45f969007d95dc48973 (commit)

Summary of changes:
 clawsker |    8 ++++++++
 1 file changed, 8 insertions(+)


- Log -----------------------------------------------------------------
commit fbeef107fe07fa5220b4bec0c1ef8ebb6d657260
Author: Ricardo Mones <ricardo at mones.org>
Date:   Sat Jul 14 12:56:00 2018 +0200

    Allow to exit with escape key

diff --git a/clawsker b/clawsker
index b286a67..8c8b687 100755
--- a/clawsker
+++ b/clawsker
@@ -2822,6 +2822,13 @@ sub get_app_icons {
     return @APPICONS;
 }
 
+sub escape_key_handler {
+    my ($widget, $event) = @_;
+    if ($event->keyval == Gtk2::Gdk->keyval_from_name('Escape')) {
+        exit_handler($widget);
+    }
+}
+
 # initialise
 exit unless parse_command_line ();
 Gtk2->init;
@@ -2835,6 +2842,7 @@ my $about = new_about_dialog ();
 $box->pack_start (new_notebook (), TRUE, TRUE, 0);
 $box->pack_end (new_button_box ($main_window, $about), FALSE, FALSE, 0);
 $main_window->signal_connect (delete_event => sub { exit_handler($main_window) });
+$main_window->signal_connect (key_press_event => \&escape_key_handler);
 $main_window->set_title ($xl::s{win_title});
 $main_window->set_icon_list (get_app_icons ());
 $main_window->add ($box);

-----------------------------------------------------------------------


hooks/post-receive
-- 
Hidden preferences editor for Claws Mail


More information about the Commits mailing list