Implement onShouldQuit with the same semnatic as libui (return true from the cb will stop the loop)
mischnic opened this issue · 1 comments
mischnic commented
Should return the cb's return value, currently:
Lines 6 to 10 in df1eefd
How it's used by libui (pseudocode):
if (uiShouldQuitCb())
uiQuit();
parro-it commented
We cannot let libui
call uiQuit alone, because we have to call our stopLoop method instead (it call uiQuit after it had cleaned up other things).
So we can implement the same semantic, but always return 0.
Also, we'll have to implement this on JS side, because we also have to unpatch global timers functions.