Mercurial > sdl-ios-xcode
comparison include/SDL_main.h @ 3407:d3baf5ac4e37
Partial fix for bug #859
Header file update from Ken for improved doxygen output
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Mon, 19 Oct 2009 13:31:58 +0000 |
parents | 99210400e8b9 |
children | f7b03b6838cb |
comparison
equal
deleted
inserted
replaced
3406:8ae607392409 | 3407:d3baf5ac4e37 |
---|---|
23 #ifndef _SDL_main_h | 23 #ifndef _SDL_main_h |
24 #define _SDL_main_h | 24 #define _SDL_main_h |
25 | 25 |
26 #include "SDL_stdinc.h" | 26 #include "SDL_stdinc.h" |
27 | 27 |
28 /* Redefine main() on some platforms so that it is called by SDL */ | 28 /** |
29 * \file SDL_main.h | |
30 * | |
31 * Redefine main() on some platforms so that it is called by SDL. | |
32 */ | |
29 | 33 |
30 #if defined(__WIN32__) || \ | 34 #if defined(__WIN32__) || \ |
31 (defined(__MWERKS__) && !defined(__BEOS__)) || \ | 35 (defined(__MWERKS__) && !defined(__BEOS__)) || \ |
32 defined(__SYMBIAN32__) || defined(__IPHONEOS__) | 36 defined(__SYMBIAN32__) || defined(__IPHONEOS__) |
33 | 37 |
35 #define C_LINKAGE "C" | 39 #define C_LINKAGE "C" |
36 #else | 40 #else |
37 #define C_LINKAGE | 41 #define C_LINKAGE |
38 #endif /* __cplusplus */ | 42 #endif /* __cplusplus */ |
39 | 43 |
40 /* The application's main() function must be called with C linkage, | 44 /** |
41 and should be declared like this: | 45 * \file SDL_main.h |
42 #ifdef __cplusplus | 46 * |
43 extern "C" | 47 * The application's main() function must be called with C linkage, |
44 #endif | 48 * and should be declared like this: |
45 int main(int argc, char *argv[]) | 49 * \code |
46 { | 50 * #ifdef __cplusplus |
47 } | 51 * extern "C" |
52 * #endif | |
53 * int main(int argc, char *argv[]) | |
54 * { | |
55 * } | |
56 * \endcode | |
48 */ | 57 */ |
58 | |
49 #define main SDL_main | 59 #define main SDL_main |
50 | 60 |
51 /* The prototype for the application's main() function */ | 61 /** |
62 * The prototype for the application's main() function | |
63 */ | |
52 extern C_LINKAGE int SDL_main(int argc, char *argv[]); | 64 extern C_LINKAGE int SDL_main(int argc, char *argv[]); |
53 | 65 |
54 | 66 |
55 /* From the SDL library code -- needed for registering the app on Win32 */ | 67 /* From the SDL library code -- needed for registering the app on Win32 */ |
56 #ifdef __WIN32__ | 68 #ifdef __WIN32__ |
60 /* *INDENT-OFF* */ | 72 /* *INDENT-OFF* */ |
61 extern "C" { | 73 extern "C" { |
62 /* *INDENT-ON* */ | 74 /* *INDENT-ON* */ |
63 #endif | 75 #endif |
64 | 76 |
65 /* This can be called to set the application class at startup */ | 77 /** |
78 * This can be called to set the application class at startup | |
79 */ | |
66 extern DECLSPEC int SDLCALL SDL_RegisterApp(char *name, Uint32 style, | 80 extern DECLSPEC int SDLCALL SDL_RegisterApp(char *name, Uint32 style, |
67 void *hInst); | 81 void *hInst); |
68 extern DECLSPEC void SDLCALL SDL_UnregisterApp(void); | 82 extern DECLSPEC void SDLCALL SDL_UnregisterApp(void); |
69 | 83 |
70 #ifdef __cplusplus | 84 #ifdef __cplusplus |