author | unc0rr |
Sun, 08 Feb 2015 00:10:05 +0300 | |
branch | qmlfrontend |
changeset 10819 | 57e21f7621b0 |
parent 10616 | 20a2d5e6930a |
child 10888 | a04e04aaf599 |
permissions | -rw-r--r-- |
10416 | 1 |
#ifndef FLIB_H |
2 |
#define FLIB_H |
|
3 |
||
4 |
#include <stdint.h> |
|
5 |
||
6 |
#ifdef __cplusplus |
|
7 |
extern "C" { |
|
8 |
#endif |
|
9 |
||
10428
7c25297720f1
More refactoring: move PoC preview getting code into flib
unc0rr
parents:
10426
diff
changeset
|
10 |
enum MessageType { |
7c25297720f1
More refactoring: move PoC preview getting code into flib
unc0rr
parents:
10426
diff
changeset
|
11 |
MSG_PREVIEW |
10444
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10440
diff
changeset
|
12 |
, MSG_ADDPLAYINGTEAM |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10440
diff
changeset
|
13 |
, MSG_REMOVEPLAYINGTEAM |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10440
diff
changeset
|
14 |
, MSG_ADDTEAM |
47a6231f1fc1
Teams widget now allows to add and remove teams (basic implementation, no checks performed, no colors, no hedgehogs)
unc0rr
parents:
10440
diff
changeset
|
15 |
, MSG_REMOVETEAM |
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
16 |
, MSG_TEAMCOLOR |
10428
7c25297720f1
More refactoring: move PoC preview getting code into flib
unc0rr
parents:
10426
diff
changeset
|
17 |
}; |
7c25297720f1
More refactoring: move PoC preview getting code into flib
unc0rr
parents:
10426
diff
changeset
|
18 |
|
10416 | 19 |
typedef union string255_ |
20 |
{ |
|
21 |
struct { |
|
22 |
unsigned char s[256]; |
|
23 |
}; |
|
24 |
struct { |
|
25 |
unsigned char len; |
|
26 |
unsigned char str[255]; |
|
27 |
}; |
|
28 |
} string255; |
|
29 |
||
10418
091d2c0216c3
Move away from passing shortstrings into C code, now IPC works
unc0rr
parents:
10416
diff
changeset
|
30 |
typedef void RunEngine_t(int argc, const char ** argv); |
10428
7c25297720f1
More refactoring: move PoC preview getting code into flib
unc0rr
parents:
10426
diff
changeset
|
31 |
typedef void registerGUIMessagesCallback_t(void * context, void (*)(void * context, MessageType mt, const char * msg, uint32_t len)); |
10430 | 32 |
typedef void getPreview_t(); |
10432 | 33 |
typedef void runQuickGame_t(); |
10448 | 34 |
typedef void runLocalGame_t(); |
10450 | 35 |
typedef void resetGameConfig_t(); |
10430 | 36 |
typedef void setSeed_t(const char * seed); |
37 |
typedef char *getSeed_t(); |
|
10612 | 38 |
typedef void setTheme_t(const char * themeName); |
39 |
typedef void setScript_t(const char * scriptName); |
|
10819
57e21f7621b0
Send selected scheme config on engine initialization (WIP)
unc0rr
parents:
10616
diff
changeset
|
40 |
typedef void setScheme_t(const char * schemeName); |
10424
4be6cd55f1cf
- Get rid of engine's PathPrefix and UserPathPrefix
unc0rr
parents:
10420
diff
changeset
|
41 |
typedef void flibInit_t(const char * localPrefix, const char * userPrefix); |
4be6cd55f1cf
- Get rid of engine's PathPrefix and UserPathPrefix
unc0rr
parents:
10420
diff
changeset
|
42 |
typedef void flibFree_t(); |
10416 | 43 |
|
10434
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
44 |
typedef char **getThemesList_t(); |
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
45 |
typedef void freeThemesList_t(char **list); |
10436 | 46 |
typedef uint32_t getThemeIcon_t(char * theme, char * buffer, uint32_t size); |
10434
1614b13ad35e
Themes model, also add some files I forgot to add previously
unc0rr
parents:
10432
diff
changeset
|
47 |
|
10517 | 48 |
typedef char **getScriptsList_t(); |
10616 | 49 |
typedef char **getSchemesList_t(); |
10517 | 50 |
|
10440 | 51 |
typedef char **getTeamsList_t(); |
10452
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
52 |
typedef void tryAddTeam_t(const char * teamName); |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
53 |
typedef void tryRemoveTeam_t(const char * teamName); |
03519fd9f98d
Show team color in teams list widget, also allow to change it on mouse click
unc0rr
parents:
10450
diff
changeset
|
54 |
typedef void changeTeamColor_t(const char * teamName, int32_t dir); |
10440 | 55 |
|
10416 | 56 |
#ifdef __cplusplus |
57 |
} |
|
58 |
#endif |
|
59 |
||
60 |
#endif // FLIB_H |