git-svn-id: svn://db.shs.com.ru/pip@386 12ceb7fc-bf1f-11e4-8940-5bc7170c53b5

This commit is contained in:
2017-04-17 13:04:53 +00:00
parent 0f91382084
commit 5349d695da
3 changed files with 95 additions and 29 deletions

View File

@@ -248,7 +248,6 @@ public:
void disconnect();
bool isConnected() const {return state == Connected;}
#ifdef WINDOWS
void toUpperLeft();
void moveRight(int n = 1);
void moveLeft(int n = 1);
@@ -259,18 +258,6 @@ public:
void newLine();
void hideCursor();
void showCursor();
#else
void toUpperLeft() {printf("\e[H");}
void moveRight(int n = 1) {if (n > 0) printf("\e[%dC", n);}
void moveLeft(int n = 1) {if (n > 0) printf("\e[%dD", n);}
void moveTo(int x = 0, int y = 0) {printf("\e[%d;%dH", y, x);}
void clearScreen() {couts(fstr(Normal)); printf("\e[H\e[J");}
void clearScreenLower() {couts(fstr(Normal)); printf("\e[J");}
void clearLine() {printf("\e[K");}
void newLine() {printf("\eE");}
void hideCursor() {printf("\e[?25l");}
void showCursor() {printf("\e[?25h");}
#endif
EVENT_HANDLER0(void, clearVariables) {clearVariables(true);}
EVENT_HANDLER1(void, clearVariables, bool, clearScreen);