mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-26 03:30:46 +00:00
Compile DEF progress meter only on Windows or if having the startup window.
The latter checked with #defined HAVE_GTK2, which is probably not correct for every platform. In builds without a startup window, the periods get mingled with stdout output otherwise. git-svn-id: https://svn.eduke32.com/eduke32@3827 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
640eda2194
commit
ed5613bf57
1 changed files with 9 additions and 1 deletions
|
@ -192,11 +192,18 @@ static void tile_from_truecolpic(int32_t tile, const palette_t *picptr, int32_t
|
||||||
Bfree(ftd);
|
Bfree(ftd);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#undef USE_DEF_PROGRESS
|
||||||
|
#if defined _WIN32 || defined HAVE_GTK2
|
||||||
|
# define USE_DEF_PROGRESS
|
||||||
|
#endif
|
||||||
|
|
||||||
static int32_t defsparser(scriptfile *script)
|
static int32_t defsparser(scriptfile *script)
|
||||||
{
|
{
|
||||||
int32_t tokn;
|
int32_t tokn;
|
||||||
char *cmdtokptr;
|
char *cmdtokptr;
|
||||||
|
#ifdef USE_DEF_PROGRESS
|
||||||
static uint32_t iter = 0;
|
static uint32_t iter = 0;
|
||||||
|
#endif
|
||||||
|
|
||||||
static const tokenlist basetokens[] =
|
static const tokenlist basetokens[] =
|
||||||
{
|
{
|
||||||
|
@ -260,6 +267,7 @@ static int32_t defsparser(scriptfile *script)
|
||||||
|
|
||||||
while (1)
|
while (1)
|
||||||
{
|
{
|
||||||
|
#ifdef USE_DEF_PROGRESS
|
||||||
if (++iter >= 50)
|
if (++iter >= 50)
|
||||||
{
|
{
|
||||||
flushlogwindow = 1;
|
flushlogwindow = 1;
|
||||||
|
@ -267,7 +275,7 @@ static int32_t defsparser(scriptfile *script)
|
||||||
flushlogwindow = 0;
|
flushlogwindow = 0;
|
||||||
iter = 0;
|
iter = 0;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
if (quitevent) return 0;
|
if (quitevent) return 0;
|
||||||
tokn = getatoken(script,basetokens,sizeof(basetokens)/sizeof(tokenlist));
|
tokn = getatoken(script,basetokens,sizeof(basetokens)/sizeof(tokenlist));
|
||||||
cmdtokptr = script->ltextptr;
|
cmdtokptr = script->ltextptr;
|
||||||
|
|
Loading…
Reference in a new issue