Skip to content

Commit

Permalink
Mini-buffer entry is no longer an issue. EOM
Browse files Browse the repository at this point in the history
  • Loading branch information
timvisher committed Nov 23, 2011
1 parent 32315a1 commit 20f7190
Showing 1 changed file with 10 additions and 12 deletions.
22 changes: 10 additions & 12 deletions emacs/vimgolf.el
Expand Up @@ -108,7 +108,6 @@ with `C-c C-v` prefixes to help in playing VimGolf.

(defun vimgolf-capturable-keystroke-p ()
(not (or executing-kbd-macro
(< 0 (recursion-depth))
(member this-command
'(digit-argument
negative-argument
Expand Down Expand Up @@ -147,17 +146,16 @@ unknown key sequence was entered).")
(defun vimgolf-refresh-keystroke-log ()
"Refresh the contents of the keystrokes log buffer."
(let ((deactivate-mark nil))
(when (not (< 0 (recursion-depth)))
(with-current-buffer (get-buffer-create vimgolf-keystrokes-buffer-name)
(erase-buffer)
(insert (format "Keystrokes (%d):\n\n" (vimgolf-count-keystrokes))
(mapconcat 'key-description (mapcar 'car vimgolf-keystrokes) " ")
"\n\nFull command log:\n\n")
(dolist (entry vimgolf-keystrokes)
(insert (key-description (car entry)))
(insert " ")
(princ (cdr entry) (current-buffer))
(insert "\n"))))))
(with-current-buffer (get-buffer-create vimgolf-keystrokes-buffer-name)
(erase-buffer)
(insert (format "Keystrokes (%d):\n\n" (vimgolf-count-keystrokes))
(mapconcat 'key-description (mapcar 'car vimgolf-keystrokes) " ")
"\n\nFull command log:\n\n")
(dolist (entry vimgolf-keystrokes)
(insert (key-description (car entry)))
(insert " ")
(princ (cdr entry) (current-buffer))
(insert "\n")))))

(defun vimgolf-enable-capture (enable)
"Enable keystroke logging if `ENABLE' is non-nil otherwise disable it."
Expand Down

0 comments on commit 20f7190

Please sign in to comment.