mirror of
https://github.com/holub/mame
synced 2025-06-05 20:33:45 +03:00
(nw) possible fix for MT 07275 [hap]
This commit is contained in:
parent
379b9e6c92
commit
6d3eddd819
@ -200,7 +200,12 @@ osd_ticks_t osd_ticks_per_second(void)
|
|||||||
|
|
||||||
void osd_sleep(osd_ticks_t duration)
|
void osd_sleep(osd_ticks_t duration)
|
||||||
{
|
{
|
||||||
|
#ifdef WIN32
|
||||||
|
// sleep_for appears to oversleep on Windows with gcc 8
|
||||||
|
Sleep(duration / (osd_ticks_per_second() / 1000));
|
||||||
|
#else
|
||||||
std::this_thread::sleep_for(std::chrono::high_resolution_clock::duration(duration));
|
std::this_thread::sleep_for(std::chrono::high_resolution_clock::duration(duration));
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user