changeset 10026:09392b4de856

(gomoku-click): New function. (gomoku-mode-map): Put it on Mouse-2.
author Richard M. Stallman <rms@gnu.org>
date Sat, 19 Nov 1994 14:52:57 +0000
parents 3b058e13d177
children bb1027a75918
files lisp/play/gomoku.el
diffstat 1 files changed, 7 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/play/gomoku.el	Sat Nov 19 14:06:09 1994 +0000
+++ b/lisp/play/gomoku.el	Sat Nov 19 14:52:57 1994 +0000
@@ -113,6 +113,7 @@
   (define-key gomoku-mode-map [left] 'gomoku-move-left)
   (define-key gomoku-mode-map [right] 'gomoku-move-right)
   (define-key gomoku-mode-map [kp-enter] 'gomoku-human-plays)
+  (define-key gomoku-mode-map [mouse-2] 'gomoku-click)
   (define-key gomoku-mode-map [insert] 'gomoku-human-plays))
 
 (defun gomoku-mode ()
@@ -737,6 +738,12 @@
 		   (t
 		    (gomoku-prompt-for-move)))))))))
 
+(defun gomoku-click (click)
+  "Play at the square where you click."
+  (interactive "e")
+  (mouse-set-point click)
+  (gomoku-human-plays))
+
 (defun gomoku-human-plays ()
   "Signal to the Gomoku program that you have played.
 You must have put the cursor on the square where you want to play.