all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Peder O. Klingenberg" <peder@klingenberg.no>
To: 42731@debbugs.gnu.org
Subject: bug#42731: 28.0.50; Snake doesn't quit when pressing "q"
Date: Thu, 06 Aug 2020 19:46:42 +0200	[thread overview]
Message-ID: <86tuxf4qgt.fsf@klingenberg.no> (raw)

[-- Attachment #1: Type: text/plain, Size: 204 bytes --]


When playing Tetris, pressing "q" when not in an active game quits the Tetris
window.  Very handy.  Snake should IMO behave the same, but doesn't currently.

Here's a patch to fix that.

-- 
...Peder...

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-lisp-play-snake.el-snake-null-map-Add-quitting-by-pr.patch --]
[-- Type: text/x-patch, Size: 729 bytes --]

From 72713a7d52f2ee823a4e81c16a9c64104fcca012 Mon Sep 17 00:00:00 2001
From: "Peder O. Klingenberg" <peder@klingenberg.no>
Date: Thu, 6 Aug 2020 14:32:52 +0200
Subject: [PATCH] * lisp/play/snake.el (snake-null-map): Add quitting by
 pressing q.

---
 lisp/play/snake.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lisp/play/snake.el b/lisp/play/snake.el
index d7c0683a05..70d80c464f 100644
--- a/lisp/play/snake.el
+++ b/lisp/play/snake.el
@@ -192,6 +192,7 @@ snake-mode-map
 (defvar snake-null-map
   (let ((map (make-sparse-keymap 'snake-null-map)))
     (define-key map "n"		'snake-start-game)
+    (define-key map "q"         'quit-window)
     map)
   "Keymap for finished Snake games.")
 
-- 
2.28.0.rc2.windows.1


             reply	other threads:[~2020-08-06 17:46 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-06 17:46 Peder O. Klingenberg [this message]
2020-08-07 10:31 ` bug#42731: 28.0.50; Snake doesn't quit when pressing "q" Stefan Kangas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86tuxf4qgt.fsf@klingenberg.no \
    --to=peder@klingenberg.no \
    --cc=42731@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.