Started the work to fix uiMainStep().

This commit is contained in:
Pietro Gagliardi 2016-06-16 13:41:13 -04:00
parent dd2ee50710
commit b4d0e08a22
1 changed files with 9 additions and 2 deletions

View File

@ -54,6 +54,7 @@ int main(int argc, char *argv[])
uiTab *innerTab; uiTab *innerTab;
int nomenus = 0; int nomenus = 0;
int startspaced = 0; int startspaced = 0;
int steps = 0;
newhbox = uiNewHorizontalBox; newhbox = uiNewHorizontalBox;
newvbox = uiNewVerticalBox; newvbox = uiNewVerticalBox;
@ -67,7 +68,9 @@ int main(int argc, char *argv[])
else if (strcmp(argv[i], "swaphv") == 0) { else if (strcmp(argv[i], "swaphv") == 0) {
newhbox = uiNewVerticalBox; newhbox = uiNewVerticalBox;
newvbox = uiNewHorizontalBox; newvbox = uiNewHorizontalBox;
} else { } else if (strcmp(argv[i], "steps") == 0)
steps = 1;
else {
fprintf(stderr, "%s: unrecognized option %s\n", argv[0], argv[i]); fprintf(stderr, "%s: unrecognized option %s\n", argv[0], argv[i]);
return 1; return 1;
} }
@ -156,7 +159,11 @@ int main(int argc, char *argv[])
setSpaced(1); setSpaced(1);
uiControlShow(uiControl(w)); uiControlShow(uiControl(w));
uiMain(); if (!steps)
uiMain();
else
while (uiMainStep(1))
;
printf("after uiMain()\n"); printf("after uiMain()\n");
uiUninit(); uiUninit();
printf("after uiUninit()\n"); printf("after uiUninit()\n");