Skip to content

Commit 28e4371

Browse files
committed
Fix usleep → std::this_thread::sleep_for for Windows/macOS portability
1 parent 4452a7b commit 28e4371

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Processing.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -549,7 +549,7 @@ void PApplet::size(int w,int h){
549549
#ifdef _WIN32
550550
Sleep(1);
551551
#elif !defined(__EMSCRIPTEN__)
552-
usleep(1000);
552+
::std::this_thread::sleep_for(::std::chrono::milliseconds(1));
553553
#endif
554554
}
555555
// Force coordinate system to requested size regardless of WM.

0 commit comments

Comments
 (0)