Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/games/gomoku gomoku: after accepting a spot via the mouse, c...
details: https://anonhg.NetBSD.org/src/rev/a0b0d1e63683
branches: trunk
changeset: 366521:a0b0d1e63683
user: rillig <rillig%NetBSD.org@localhost>
date: Sun May 29 16:19:52 2022 +0000
description:
gomoku: after accepting a spot via the mouse, clear current coordinate
diffstat:
games/gomoku/bdisp.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diffs (35 lines):
diff -r d8bcb85a33dc -r a0b0d1e63683 games/gomoku/bdisp.c
--- a/games/gomoku/bdisp.c Sun May 29 16:14:41 2022 +0000
+++ b/games/gomoku/bdisp.c Sun May 29 16:19:52 2022 +0000
@@ -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 @@
break;
case KEY_MOUSE:
if (get_coord_mouse(&x, &y))
- return PT(x, y);
+ goto selected;
beep();
break;
case 'Q':
@@ -455,6 +455,7 @@
return SAVE;
case ' ':
case '\r':
+ selected:
(void)mvhline(BSZ + 3, 6, ' ', 6);
return PT(x, y);
}
Home |
Main Index |
Thread Index |
Old Index