--- hatari/src/includes/main.h 2019/04/01 07:15:27 1.1.1.16 +++ hatari/src/includes/main.h 2019/04/09 08:54:26 1.1.1.25 @@ -1,18 +1,14 @@ /* Hatari - main.h - This file is distributed under the GNU Public License, version 2 or at - your option any later version. Read the file gpl.txt for details. + This file is distributed under the GNU General Public License, version 2 + or at your option any later version. Read the file gpl.txt for details. */ #ifndef HATARI_MAIN_H #define HATARI_MAIN_H - -/* Name and version for window title: */ -//#define PROG_NAME "Hatari devel (" __DATE__ ")" -#define PROG_NAME "Hatari v1.2.0" - +#include "config.h" #include #include @@ -23,9 +19,12 @@ #include #include -#ifndef FALSE -#define FALSE false -#define TRUE true +#if __GNUC__ >= 3 +# define likely(x) __builtin_expect (!!(x), 1) +# define unlikely(x) __builtin_expect (!!(x), 0) +#else +# define likely(x) (x) +# define unlikely(x) (x) #endif #ifdef WIN32 @@ -36,22 +35,28 @@ #define CALL_VAR(func) { ((void(*)(void))func)(); } +#ifndef ARRAYSIZE +#define ARRAYSIZE(x) (int)(sizeof(x)/sizeof(x[0])) +#endif /* 68000 operand sizes */ #define SIZE_BYTE 1 #define SIZE_WORD 2 #define SIZE_LONG 4 +/* The 8 MHz CPU frequency */ +#define CPU_FREQ 8012800 extern bool bQuitProgram; -extern bool bEnableDebug; -extern void Main_MemorySnapShot_Capture(bool bSave); extern bool Main_PauseEmulation(bool visualize); extern bool Main_UnPauseEmulation(void); -extern void Main_RequestQuit(void); +extern void Main_RequestQuit(int exitval); +extern void Main_SetRunVBLs(Uint32 vbls); +extern bool Main_SetVBLSlowdown(int factor); extern void Main_WaitOnVbl(void); extern void Main_WarpMouse(int x, int y); extern void Main_EventHandler(void); +extern void Main_SetTitle(const char *title); #endif /* ifndef HATARI_MAIN_H */