From b4d0e08a22145e9bd207a5ab8188e2f11a92e1a2 Mon Sep 17 00:00:00 2001 From: Pietro Gagliardi Date: Thu, 16 Jun 2016 13:41:13 -0400 Subject: [PATCH] Started the work to fix uiMainStep(). --- test/main.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) 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");