main() refactoring

This commit is contained in:
Vadim Lopatin 2015-04-07 12:15:06 +03:00
parent e592462f6b
commit d97cec9522
3 changed files with 20 additions and 12 deletions

View File

@ -1355,6 +1355,9 @@ version (Windows) {
// to remove import
extern(Windows) int DLANGUIWinMain(void* hInstance, void* hPrevInstance,
char* lpCmdLine, int nCmdShow);
} else {
// to remove import
extern int DLANGUImain(string[] args);
}
/// put "mixin APP_ENTRY_POINT;" to main module of your dlangui based app
@ -1386,6 +1389,11 @@ mixin template APP_ENTRY_POINT() {
return 1;
}
}
} else {
int main(string[] args)
{
return DLANGUImain(args);
}
}
}

View File

@ -1260,7 +1260,7 @@ version (Windows) {
}
} else {
int main(string[] args)
int DLANGUImain(string[] args)
{
initLogs();