window: read_key: move cursor back to position it was at before helper function call

This commit is contained in:
Andrzej Rybczak
2014-01-04 21:45:08 +01:00
parent c8c182b409
commit 554d684396

View File

@@ -48,10 +48,13 @@ const char *base;
int read_key(FILE *) int read_key(FILE *)
{ {
size_t x;
int result; int result;
do do
{ {
x = w->getX();
w->runGetStringHelper(rl_line_buffer); w->runGetStringHelper(rl_line_buffer);
w->goToXY(x, start_y);
w->refresh(); w->refresh();
result = w->readKey(); result = w->readKey();
} }