소스 검색

prevented incompatible size limits

pull/5536/head
unknown 3 주 전
부모
커밋
3d1afc3cff
1개의 변경된 파일12개의 추가작업 그리고 0개의 파일을 삭제
  1. +12
    -0
      src/platforms/rcore_desktop_win32.c

+ 12
- 0
src/platforms/rcore_desktop_win32.c 파일 보기

@ -972,6 +972,12 @@ void SetWindowMonitor(int monitor)
// Set window minimum dimensions (FLAG_WINDOW_RESIZABLE)
void SetWindowMinSize(int width, int height)
{
if ((width > CORE.Window.screenMax.width) || (height > CORE.Window.screenMax.height))
{
TRACELOG(LOG_WARNING, "WIN32: WINDOW: Cannot set minimum screen size higher than the maximum");
return;
}
CORE.Window.screenMin.width = width;
CORE.Window.screenMin.height = height;
@ -981,6 +987,12 @@ void SetWindowMinSize(int width, int height)
// Set window maximum dimensions (FLAG_WINDOW_RESIZABLE)
void SetWindowMaxSize(int width, int height)
{
if ((width < CORE.Window.screenMin.width) || (height < CORE.Window.screenMin.height))
{
TRACELOG(LOG_WARNING, "WIN32: WINDOW: Cannot set maximum screen size lower than the minimum");
return;
}
CORE.Window.screenMax.width = width;
CORE.Window.screenMax.height = height;

불러오는 중...
취소
저장