summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortruelight <truelight@openttd.org>2007-02-15 16:15:00 +0000
committertruelight <truelight@openttd.org>2007-02-15 16:15:00 +0000
commitc50396cb15a9de2bfa68e0be4d64b76a261e7e3b (patch)
tree027d0ec80db672d69ba0432640cc367dad4dd947 /src
parent6abbf15a8ef1f380ad820d40d69fb7c8f52e0f58 (diff)
downloadopenttd-c50396cb15a9de2bfa68e0be4d64b76a261e7e3b.tar.xz
(svn r8745) [PSP] -Add: added a CSleep() for PSP
Diffstat (limited to 'src')
-rw-r--r--src/unix.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/unix.cpp b/src/unix.cpp
index cee8082d9..68b96ee39 100644
--- a/src/unix.cpp
+++ b/src/unix.cpp
@@ -260,13 +260,11 @@ bool InsertTextBufferClipboard(Textbuf *tb)
void CSleep(int milliseconds)
{
- #if !defined(__BEOS__) && !defined(__AMIGA__)
- usleep(milliseconds * 1000);
- #endif
- #ifdef __BEOS__
+ #if defined(PSP)
+ sceKernelDelayThread(milliseconds * 1000);
+ #elif defined(__BEOS__)
snooze(milliseconds * 1000);
- #endif
- #if defined(__AMIGA__)
+ #elif defined(__AMIGA__)
{
ULONG signals;
ULONG TimerSigBit = 1 << TimerPort->mp_SigBit;
@@ -282,7 +280,9 @@ void CSleep(int milliseconds)
}
WaitIO((struct IORequest *)TimerRequest);
}
- #endif // __AMIGA__
+ #else
+ usleep(milliseconds * 1000);
+ #endif
}
#ifdef WITH_ICONV