mirror of
https://github.com/raysan5/raylib.git
synced 2026-04-09 16:59:09 -04:00
MSVC warnings (#5595)
This commit is contained in:
@ -60,7 +60,7 @@ int main(void)
|
||||
//----------------------------------------------------------------------------------
|
||||
if (btnComputeHashes)
|
||||
{
|
||||
int textInputLen = strlen(textInput);
|
||||
int textInputLen = (int)strlen(textInput);
|
||||
|
||||
// Encode data to Base64 string (includes NULL terminator), memory must be MemFree()
|
||||
base64Text = EncodeDataBase64((unsigned char *)textInput, textInputLen, &base64TextSize);
|
||||
|
||||
@ -78,7 +78,7 @@ int main(void)
|
||||
|
||||
GuiSetStyle(LISTVIEW, TEXT_ALIGNMENT, TEXT_ALIGN_LEFT);
|
||||
GuiSetStyle(LISTVIEW, TEXT_PADDING, 40);
|
||||
GuiListViewEx((Rectangle){ 0, 50, GetScreenWidth(), GetScreenHeight() - 50 },
|
||||
GuiListViewEx((Rectangle){ 0, 50, (float)GetScreenWidth(), (float)GetScreenHeight() - 50 },
|
||||
files.paths, files.count, &listScrollIndex, &listItemActive, &listItemFocused);
|
||||
|
||||
EndDrawing();
|
||||
|
||||
@ -86,10 +86,10 @@ int main(void)
|
||||
|
||||
// Draw mouse position
|
||||
DrawCircleV(GetMousePosition(), 20, MAROON);
|
||||
DrawRectangle(mousePos.x - 25, mousePos.y, 50, 2, BLACK);
|
||||
DrawRectangle(mousePos.x, mousePos.y - 25, 2, 50, BLACK);
|
||||
DrawRectangleRec((Rectangle) { mousePos.x - 25, mousePos.y, 50, 2 }, BLACK);
|
||||
DrawRectangleRec((Rectangle) { mousePos.x, mousePos.y - 25, 2, 50 }, BLACK);
|
||||
DrawText(TextFormat("[%i,%i]", GetMouseX(), GetMouseY()), mousePos.x - 44,
|
||||
(mousePos.y > GetScreenHeight() - 60)? mousePos.y - 46 : mousePos.y + 30, 20, BLACK);
|
||||
(mousePos.y > GetScreenHeight() - 60)? (int)mousePos.y - 46 : (int)mousePos.y + 30, 20, BLACK);
|
||||
|
||||
EndDrawing();
|
||||
//----------------------------------------------------------------------------------
|
||||
|
||||
@ -177,10 +177,10 @@ int main(void)
|
||||
DrawRectangleRec(increaseTypeButton, SKYBLUE);
|
||||
DrawRectangleRec(decreaseResolutionButton, SKYBLUE);
|
||||
DrawRectangleRec(increaseResolutionButton, SKYBLUE);
|
||||
DrawText("<", decreaseTypeButton.x + 3, decreaseTypeButton.y + 1, 10, BLACK);
|
||||
DrawText(">", increaseTypeButton.x + 3, increaseTypeButton.y + 1, 10, BLACK);
|
||||
DrawText("<", decreaseResolutionButton.x + 3, decreaseResolutionButton.y + 1, 10, BLACK);
|
||||
DrawText(">", increaseResolutionButton.x + 3, increaseResolutionButton.y + 1, 10, BLACK);
|
||||
DrawText("<", (int)decreaseTypeButton.x + 3, (int)decreaseTypeButton.y + 1, 10, BLACK);
|
||||
DrawText(">", (int)increaseTypeButton.x + 3, (int)increaseTypeButton.y + 1, 10, BLACK);
|
||||
DrawText("<", (int)decreaseResolutionButton.x + 3, (int)decreaseResolutionButton.y + 1, 10, BLACK);
|
||||
DrawText(">", (int)increaseResolutionButton.x + 3, (int)increaseResolutionButton.y + 1, 10, BLACK);
|
||||
|
||||
EndDrawing();
|
||||
//----------------------------------------------------------------------------------
|
||||
@ -308,7 +308,7 @@ static void ResizeRenderSize(ViewportType viewportType, int *screenWidth, int *s
|
||||
}
|
||||
|
||||
UnloadRenderTexture(*target);
|
||||
*target = LoadRenderTexture(sourceRect->width, -sourceRect->height);
|
||||
*target = LoadRenderTexture((int)sourceRect->width, -(int)sourceRect->height);
|
||||
}
|
||||
|
||||
// Example how to calculate position on RenderTexture
|
||||
|
||||
Reference in New Issue
Block a user