29 #include "../../../idlib/precompiled.h"
52 if ( args.
Argc() > 1 ) {
64 for ( i = 0; i < resourceFiles.
Num(); i++ ) {
66 fileName = path +
"/" + resourceFiles[
i];
70 if ( !src.
LoadFile( fileName,
true ) ) {
86 if ( token ==
"ifdef" || token ==
"ifndef" ) {
88 }
else if ( token ==
"define" ) {
91 if ( token.
Icmpn(
"_APS_", 5 ) == 0 ) {
95 if ( token.
Icmpn(
"IDD_", 4 ) == 0 ) {
97 }
else if ( token.
Icmpn(
"IDR_", 4 ) == 0 ) {
99 }
else if ( token.
Icmpn(
"IDB_", 4 ) == 0 ) {
101 }
else if ( token.
Icmpn(
"IDI_", 4 ) == 0 ) {
103 }
else if ( token.
Icmpn(
"IDS_", 4 ) == 0 ||
104 token.
Icmpn(
"IDP_", 4 ) == 0 ) {
106 }
else if ( token.
Icmpn(
"IDC_", 4 ) == 0 ) {
118 int curResource, curControl, curCommand;
120 curResource = i ? i * 1000 : 100;
121 curCommand = 20000 + i * 1000;
122 curControl = i * 1000 + 200;
131 "// Microsoft Visual C++ generated include file.\n"
135 for ( j = 0; j < dialogs.
Num(); j++ ) {
136 f->
WriteFloatString(
"#define %-40s %d\n", dialogs[j].c_str(), curResource++ );
138 for ( j = 0; j < resources.
Num(); j++ ) {
139 f->
WriteFloatString(
"#define %-40s %d\n", resources[j].c_str(), curResource++ );
141 for ( j = 0; j < bitmaps.
Num(); j++ ) {
142 f->
WriteFloatString(
"#define %-40s %d\n", bitmaps[j].c_str(), curResource++ );
144 for ( j = 0; j < icons.
Num(); j++ ) {
145 f->
WriteFloatString(
"#define %-40s %d\n", icons[j].c_str(), curResource++ );
147 for ( j = 0; j < strings.
Num(); j++ ) {
148 f->
WriteFloatString(
"#define %-40s %d\n", strings[j].c_str(), curResource++ );
153 for ( j = 0; j < controls.
Num(); j++ ) {
154 f->
WriteFloatString(
"#define %-40s %d\n", controls[j].c_str(), curControl++ );
159 for ( j = 0; j < commands.
Num(); j++ ) {
162 if ( commands[j].Cmp(
"ID_ENTITY_START" ) == 0 ) {
166 if ( commands[j].Cmp(
"ID_ENTITY_END" ) == 0 ) {
171 f->
WriteFloatString(
"#define %-40s %d\n", commands[j].c_str(), curCommand++ );
177 "#ifdef APSTUDIO_INVOKED\n"
178 "#ifndef APSTUDIO_READONLY_SYMBOLS\n"
179 "#define _APS_3D_CONTROLS 1\n"
180 "#define _APS_NEXT_RESOURCE_VALUE %d\n"
181 "#define _APS_NEXT_COMMAND_VALUE %d\n"
182 "#define _APS_NEXT_CONTROL_VALUE %d\n"
183 "#define _APS_NEXT_SYMED_VALUE %d\n"
185 "#endif\n", curResource, curCommand, curControl, curResource );
#define SOURCE_CODE_BASE_FOLDER
idFileSystem * fileSystem
idStr & BackSlashesToSlashes(void)
int ExpectAnyToken(idToken *token)
int Icmpn(const char *text, int n) const
int Sys_ListFiles(const char *directory, const char *extension, idStrList &list)
int ExpectTokenType(int type, int subtype, idToken *token)
virtual int WriteFloatString(const char *fmt,...) id_attribute((format(printf
virtual void Printf(const char *fmt,...) id_attribute((format(printf
virtual idFile * OpenExplicitFileWrite(const char *OSPath)=0
int AddUnique(const type &obj)
void Append(const char a)
const char * c_str(void) const
const char * Argv(int arg) const
virtual void CloseFile(idFile *f)=0
virtual void virtual void Warning(const char *fmt,...) id_attribute((format(printf
int ReadToken(idToken *token)
idStr & StripFilename(void)
int LoadFile(const char *filename, bool OSPath=false)
void CreateResourceIDs_f(const idCmdArgs &args)