Editor no longer moves the cursor if not needed.

This commit is contained in:
Jonas 'Sortie' Termansen 2011-11-24 19:27:24 +01:00
parent 63b622a086
commit c0fa3a6aae
1 changed files with 8 additions and 1 deletions

View File

@ -62,9 +62,16 @@ unsigned textmode()
bool ctrl = false;
int oldcursorx = -1;
int oldcursory = -1;
while ( true )
{
cursorto(cursorx, cursory);
if ( oldcursorx != cursorx || oldcursory != cursory )
{
cursorto(cursorx, cursory);
oldcursorx = cursorx;
oldcursory = cursory;
}
unsigned method = System::Keyboard::POLL;
uint32_t codepoint = System::Keyboard::ReceiveKeystroke(method);