From: NeilBrown Date: Tue, 12 Jan 2016 02:57:04 +0000 (+1100) Subject: discard move_cursor() X-Git-Tag: lca2016~25 X-Git-Url: http://git.neil.brown.name/?a=commitdiff_plain;h=966e7d37c9d98e789bc8afd9b4bc76279f058382;p=edlib.git discard move_cursor() no longer needed - we have a new way of positioning the cursor. Signed-off-by: NeilBrown --- diff --git a/display-ncurses.c b/display-ncurses.c index b1acb31b..edf102d4 100644 --- a/display-ncurses.c +++ b/display-ncurses.c @@ -42,24 +42,6 @@ static void set_screen(SCREEN *scr) current_screen = scr; } -static void move_cursor(struct pane *p) -{ - int ox; - int oy; - - p = pane_with_cursor(p, &ox, &oy); - - if (p) { - int cx = p->cx; - int cy = p->cy; - if (cx >= p->w) - cx = p->w - 1; - if (cy >= p->h) - cy = p->h - 1; - move(oy+cy, ox+cx); - } -} - DEF_CMD(input_handle); DEF_CMD(handle_winch); @@ -196,7 +178,6 @@ DEF_CMD(ncurses_handle) if (ci->numeric > 0) { /* post-order call */ - move_cursor(p); if (dd->cursor.x >= 0) move(dd->cursor.y, dd->cursor.x); refresh();