Sha256: 0b0ac14d622b59782a3f497c2c7f4c4d227936ce39fb9f0f32718dd64314b38b

Contents?: true

Size: 379 Bytes

Versions: 22

Compression:

Stored size: 379 Bytes

Contents

#include <Gosu/Platform.hpp>
#if defined(GOSU_IS_WIN)

#include <Gosu/Timing.hpp>
#include <cstdlib>
#include <windows.h>

void Gosu::sleep(unsigned milliseconds)
{
    Sleep(milliseconds);
}

unsigned long Gosu::milliseconds()
{
    static unsigned long start = [] {
        timeBeginPeriod(1);
        return timeGetTime();
    }();
    return timeGetTime() - start;
}

#endif

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
gosu-1.4.1 src/TimingWin.cpp
gosu-1.4.0 src/TimingWin.cpp
gosu-1.3.0 src/TimingWin.cpp
gosu-1.2.0 src/TimingWin.cpp
gosu-1.1.1.1 src/TimingWin.cpp
gosu-1.1.0 src/TimingWin.cpp
gosu-1.1.0.pre2 src/TimingWin.cpp
gosu-1.1.0.pre1 src/TimingWin.cpp
gosu-1.0.0 src/TimingWin.cpp
gosu-1.0.0.pre2 src/TimingWin.cpp
gosu-1.0.0.pre1 src/TimingWin.cpp
gosu-0.15.2 src/TimingWin.cpp
gosu-0.15.1 src/TimingWin.cpp
gosu-0.15.0 src/TimingWin.cpp
gosu-0.14.6.pre1 src/TimingWin.cpp
gosu-0.14.5 src/TimingWin.cpp
gosu-0.14.4 src/TimingWin.cpp
gosu-0.14.4.pre2 src/TimingWin.cpp
gosu-0.14.3.pre1 src/TimingWin.cpp
gosu-0.14.3 src/TimingWin.cpp