{"thread":{"id":"26350","subject":"[PATCH] gitk: Preserve Entry class key bindings for SHA id","startedAt":"2011-01-27T16:06:25Z","lastAt":"2011-01-27T16:06:25Z","messageCount":1,"participants":["Kacper Kornet"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"159951","messageId":"20110127160625.GC519@camk.edu.pl","threadId":"26350","inReplyTo":null,"subject":"[PATCH] gitk: Preserve Entry class key bindings for SHA id","fromName":"Kacper Kornet","fromEmail":"kornet@camk.edu.pl","sentAt":"2011-01-27T16:06:25Z","receivedAt":"2011-01-27T16:06:25Z","isPatch":true,"sender":{"key":"kornet@camk.edu.pl","avatar":null},"body":"If bind is specified for key without any modifier, then any combination\nof modifiers may be present in the event. So bind $e $ev \"$escript;\nbreak\" breaks some useful bindings from Entry class (for example\nCtrl+k).\n\nSigned-off-by: Kacper Kornet <kornet@camk.edu.pl>\n---\n gitk |   10 +++++-----\n 1 files changed, 5 insertions(+), 5 deletions(-)\n\ndiff --git a/gitk b/gitk\nindex 9cbc09d..71eebb2 100755\n--- a/gitk\n+++ b/gitk\n@@ -2389,6 +2389,10 @@ proc makewindow {} {\n         }\n     }\n \n+    foreach e $entries {\n+        bindtags $e [linsert [bindtags $e] 2 entrybind]\n+    }\n+\n     bind .pwbottom <Configure> {resizecdetpanes %W %w}\n     pack .ctop -fill both -expand 1\n     bindall <1> {selcanvline %W %x %y}\n@@ -2588,12 +2592,8 @@ proc scrollcanv {cscroll f0 f1} {\n proc bindkey {ev script} {\n     global entries\n     bind . $ev $script\n-    set escript [bind Entry $ev]\n-    if {$escript == {}} {\n-\tset escript [bind Entry <Key>]\n-    }\n     foreach e $entries {\n-\tbind $e $ev \"$escript; break\"\n+\tbind entrybind $ev \"break\"\n     }\n }\n \n-- \n1.7.3.5\n\n-- \n  Kacper Kornet\n"}]}