Small change to text input box example

You don't have to spam backspace anymore.
This commit is contained in:
someone_existing 2020-08-14 20:13:53 +02:00 committed by GitHub
parent 53b17765f4
commit 2cbe468fb0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -59,7 +59,7 @@ int main(void)
key = GetKeyPressed(); // Check next character in the queue
}
if (IsKeyPressed(KEY_BACKSPACE))
if (IsKeyDown(KEY_BACKSPACE))
{
letterCount--;
name[letterCount] = '\0';
@ -120,4 +120,4 @@ bool IsAnyKeyPressed()
if ((key >= 32) && (key <= 126)) keyPressed = true;
return keyPressed;
}
}