From 3b66d10f0f0f47894a2cc0aba81035fa534a2b06 Mon Sep 17 00:00:00 2001 From: scarab Date: Tue, 29 Jul 2008 15:05:21 +0000 Subject: - dalsi upravy pro win32 a nastavovani klaves git-svn-id: http://opensvn.csie.org/tuxanci_ng@179 0ee4d065-81f0-4d1e-b06c-ff20ad07cc3e --- src/base/modules.h | 4 ---- src/base/myTimer.c | 10 ++++++---- 2 files changed, 6 insertions(+), 8 deletions(-) (limited to 'src/base') diff --git a/src/base/modules.h b/src/base/modules.h index 1437c52..9329dbd 100644 --- a/src/base/modules.h +++ b/src/base/modules.h @@ -31,11 +31,7 @@ typedef struct export_fce_s int (*fce_getNetTypeGame)(); int (*fce_loadDepModule)(char *name); -#ifndef __WIN32__ void (*fce_addToExportFce)(char *name, void *function); -#else - void (*fce_addToExportFce)(char *name, HINSTANCE *function); -#endif void* (*fce_getExportFce)(char *name); void (*fce_getTuxProportion)(tux_t *tux, int *x,int *y, int *w, int *h); diff --git a/src/base/myTimer.c b/src/base/myTimer.c index 114f9d7..2fbee7b 100644 --- a/src/base/myTimer.c +++ b/src/base/myTimer.c @@ -13,11 +13,14 @@ #ifndef PUBLIC_SERVER #include "interface.h" #endif - #ifdef __WIN32__ #include #include +#endif +/* // uncoment when having issues with gettimeofday in Windows +#ifdef __WIN32__ #define DELTA_EPOCH_IN_MICROSECS 11644473600000000ULL + struct timezone { int tz_minuteswest; @@ -34,8 +37,7 @@ int gettimeofday(struct timeval *tv, struct timezone *tz) tmpres |= ft.dwHighDateTime; tmpres <<= 32; tmpres |= ft.dwLowDateTime; - /*converting file time to unix epoch*/ - tmpres /= 10; /*convert into microseconds*/ + tmpres /= 10; tmpres -= DELTA_EPOCH_IN_MICROSECS; tv->tv_sec = (long)(tmpres / 1000000UL); tv->tv_usec = (long)(tmpres % 1000000UL); @@ -51,7 +53,7 @@ int gettimeofday(struct timeval *tv, struct timezone *tz) return 0; } #endif - +*/ static struct timeval start = { .tv_sec = 0, .tv_usec = 0 }; list_t* newTimer() -- cgit v1.2.3