From 3ad9caeb2a8443b5975fb91c83d2793166a4e4f6 Mon Sep 17 00:00:00 2001 From: Franklin Wei Date: Tue, 24 Oct 2017 19:33:56 -0400 Subject: puzzles: make Untangle's input code return UI_UPDATE instead of "" This was changed upstream and slipped by when I was merging the changes. Change-Id: I3a53cd2db5a5cd2ffef52719a048b8ff4c80d1aa --- apps/plugins/puzzles/src/untangle.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'apps') diff --git a/apps/plugins/puzzles/src/untangle.c b/apps/plugins/puzzles/src/untangle.c index 6c2eb30deb..09c36fe58b 100644 --- a/apps/plugins/puzzles/src/untangle.c +++ b/apps/plugins/puzzles/src/untangle.c @@ -1219,7 +1219,7 @@ static char *interpret_move(const game_state *state, game_ui *ui, if(best >= 0) { ui->cursorpoint = best; - return ""; + return UI_UPDATE; } } else if(ui->dragpoint >= 0) @@ -1229,16 +1229,16 @@ static char *interpret_move(const game_state *state, game_ui *ui, { case CURSOR_UP: ui->newpoint.y -= ds->tilesize / CURSOR_GRANULARITY; - return ""; + return UI_UPDATE; case CURSOR_DOWN: ui->newpoint.y += ds->tilesize / CURSOR_GRANULARITY; - return ""; + return UI_UPDATE; case CURSOR_LEFT: ui->newpoint.x -= ds->tilesize / CURSOR_GRANULARITY; - return ""; + return UI_UPDATE; case CURSOR_RIGHT: ui->newpoint.x += ds->tilesize / CURSOR_GRANULARITY; - return ""; + return UI_UPDATE; default: break; } @@ -1254,7 +1254,7 @@ static char *interpret_move(const game_state *state, game_ui *ui, ui->newpoint.x = state->pts[ui->dragpoint].x * ds->tilesize / state->pts[ui->dragpoint].d; ui->newpoint.y = state->pts[ui->dragpoint].y * ds->tilesize / state->pts[ui->dragpoint].d; ui->newpoint.d = ds->tilesize; - return ""; + return UI_UPDATE; } else if(ui->dragpoint >= 0) { @@ -1273,7 +1273,7 @@ static char *interpret_move(const game_state *state, game_ui *ui, ui->newpoint.x >= (long)state->w*ui->newpoint.d || ui->newpoint.y < 0 || ui->newpoint.y >= (long)state->h*ui->newpoint.d) - return ""; + return UI_UPDATE; /* * We aren't cancelling the drag. Construct a move string @@ -1287,7 +1287,7 @@ static char *interpret_move(const game_state *state, game_ui *ui, else if(ui->cursorpoint < 0) { ui->cursorpoint = 0; - return ""; + return UI_UPDATE; } } -- cgit v1.2.3