소스 검색

Adds SetWindowOpacity() implementation for PLATFORM_WEB (#4403)

pull/4408/head
Asdqwe 5 달 전
committed by GitHub
부모
커밋
9d0b1f0171
No known key found for this signature in database GPG 키 ID: B5690EEEBB952194
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. +3
    -1
      src/platforms/rcore_web.c

+ 3
- 1
src/platforms/rcore_web.c 파일 보기

@ -673,7 +673,9 @@ void SetWindowSize(int width, int height)
// Set window opacity, value opacity is between 0.0 and 1.0
void SetWindowOpacity(float opacity)
{
TRACELOG(LOG_WARNING, "SetWindowOpacity() not available on target platform");
if (opacity >= 1.0f) opacity = 1.0f;
else if (opacity <= 0.0f) opacity = 0.0f;
EM_ASM({ document.getElementById('canvas').style.opacity = $0; }, opacity);
}
// Set window focused

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