Module Name:    src
Committed By:   rillig
Date:           Sun May 29 16:19:52 UTC 2022

Modified Files:
        src/games/gomoku: bdisp.c

Log Message:
gomoku: after accepting a spot via the mouse, clear current coordinate


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/games/gomoku/bdisp.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/games/gomoku/bdisp.c
diff -u src/games/gomoku/bdisp.c:1.52 src/games/gomoku/bdisp.c:1.53
--- src/games/gomoku/bdisp.c:1.52	Sun May 29 14:37:44 2022
+++ src/games/gomoku/bdisp.c	Sun May 29 16:19:52 2022
@@ -1,4 +1,4 @@
-/*	$NetBSD: bdisp.c,v 1.52 2022/05/29 14:37:44 rillig Exp $	*/
+/*	$NetBSD: bdisp.c,v 1.53 2022/05/29 16:19:52 rillig Exp $	*/
 
 /*
  * Copyright (c) 1994
@@ -34,7 +34,7 @@
 
 #include <sys/cdefs.h>
 /*	@(#)bdisp.c	8.2 (Berkeley) 5/3/95	*/
-__RCSID("$NetBSD: bdisp.c,v 1.52 2022/05/29 14:37:44 rillig Exp $");
+__RCSID("$NetBSD: bdisp.c,v 1.53 2022/05/29 16:19:52 rillig Exp $");
 
 #include <curses.h>
 #include <string.h>
@@ -444,7 +444,7 @@ get_coord(void)
 			break;
 		case KEY_MOUSE:
 			if (get_coord_mouse(&x, &y))
-				return PT(x, y);
+				goto selected;
 			beep();
 			break;
 		case 'Q':
@@ -455,6 +455,7 @@ get_coord(void)
 			return SAVE;
 		case ' ':
 		case '\r':
+		selected:
 			(void)mvhline(BSZ + 3, 6, ' ', 6);
 			return PT(x, y);
 		}

Reply via email to