ref: f13fbf2285b1731dcc592f5a657dcbda2bbf3a02
parent: a0c7156fc8547fd0d6591413dea01462d003b847
author: Ben Harris <bjh21@bjh21.me.uk>
date: Thu Aug 10 20:59:30 EDT 2023
Singles: use new move_cursor() features
--- a/singles.c
+++ b/singles.c
@@ -1504,11 +1504,10 @@
int i, x = FROMCOORD(mx), y = FROMCOORD(my);
enum { NONE, TOGGLE_BLACK, TOGGLE_CIRCLE, UI } action = NONE;
- if (IS_CURSOR_MOVE(button)) {
- move_cursor(button, &ui->cx, &ui->cy, state->w, state->h, true, NULL);
- ui->cshow = true;
- action = UI;
- } else if (IS_CURSOR_SELECT(button)) {
+ if (IS_CURSOR_MOVE(button))
+ return move_cursor(button, &ui->cx, &ui->cy, state->w, state->h, true,
+ &ui->cshow);
+ else if (IS_CURSOR_SELECT(button)) {
x = ui->cx; y = ui->cy;
if (!ui->cshow) {
action = UI;