summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorjussi2024-01-10 22:19:00 +0200
committerjussi2024-01-10 22:19:00 +0200
commit7460a16cae15dfa7924d1d4df1aac166a6a6fd2c (patch)
treea028b655e878b4c2ff4b8fb3fb4a27395f5e082f /include
parent863f596b76043ec374fafa38f14cdc4a97d0b267 (diff)
downloadreilua-enhanced-7460a16cae15dfa7924d1d4df1aac166a6a6fd2c.tar.gz
reilua-enhanced-7460a16cae15dfa7924d1d4df1aac166a6a6fd2c.tar.bz2
reilua-enhanced-7460a16cae15dfa7924d1d4df1aac166a6a6fd2c.zip
Raygui lib extensions property list.
Diffstat (limited to 'include')
-rw-r--r--include/raygui.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/raygui.h b/include/raygui.h
index f85bc58..8486dc2 100644
--- a/include/raygui.h
+++ b/include/raygui.h
@@ -2662,7 +2662,7 @@ int GuiTextBox(Rectangle bounds, char *text, int bufferSize, bool editMode)
//if (multiline) cursor.y = GetTextLines()
// Finish text editing on ENTER or mouse click outside bounds
- if ((!multiline && IsKeyPressed(KEY_ENTER)) ||
+ if ((!multiline && IsKeyPressed(KEY_ENTER)) || (!multiline && IsKeyPressed(KEY_KP_ENTER)) ||
(!CheckCollisionPointRec(mousePosition, bounds) && IsMouseButtonPressed(MOUSE_LEFT_BUTTON)))
{
textBoxCursorIndex = 0; // GLOBAL: Reset the shared cursor index
@@ -2825,7 +2825,7 @@ int GuiValueBox(Rectangle bounds, const char *text, int *value, int minValue, in
GuiState state = guiState;
char textValue[RAYGUI_VALUEBOX_MAX_CHARS + 1] = "\0";
- sprintf(textValue, "%i", *value);
+ sprintf(textValue, "%i", *value);
Rectangle textBounds = { 0 };
if (text != NULL)
@@ -2858,6 +2858,7 @@ int GuiValueBox(Rectangle bounds, const char *text, int *value, int minValue, in
{
int key = GetCharPressed();
if ((key >= 48) && (key <= 57))
+ // if ( ( key >= 48 && key <= 57 ) || key == 45 )
{
textValue[keyCount] = (char)key;
keyCount++;