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