diff options
author | Jean-Philippe Andre <jp.andre@samsung.com> | 2014-10-22 15:49:25 +0900 |
---|---|---|
committer | Jean-Philippe Andre <jp.andre@samsung.com> | 2014-10-22 15:49:25 +0900 |
commit | 0a40a870395f6d181767dabadce753224376f89a (patch) | |
tree | f3ed5ed46fde688ba24e516746bdf5fb476ac3f2 | |
parent | 0774f2ceeb51ebe1f7f723f48e13adb94009aea7 (diff) |
Fix support of --count from command line
expedite would never exit after N loops
-rw-r--r-- | src/bin/main.c | 2 | ||||
-rw-r--r-- | src/bin/main.h | 1 | ||||
-rw-r--r-- | src/bin/ui.c | 3 |
3 files changed, 5 insertions, 1 deletions
diff --git a/src/bin/main.c b/src/bin/main.c index 77e192e..0f4b777 100644 --- a/src/bin/main.c +++ b/src/bin/main.c | |||
@@ -9,6 +9,7 @@ const char *profile = "n800"; | |||
9 | const char *choosen_engine = NULL; | 9 | const char *choosen_engine = NULL; |
10 | int win_w = 720, win_h = 420; | 10 | int win_w = 720, win_h = 420; |
11 | int loops = LOOPS; | 11 | int loops = LOOPS; |
12 | int one_test = 0; | ||
12 | Eina_Bool fullscreen = EINA_FALSE; | 13 | Eina_Bool fullscreen = EINA_FALSE; |
13 | Eina_Bool cmp_report = EINA_FALSE; | 14 | Eina_Bool cmp_report = EINA_FALSE; |
14 | 15 | ||
@@ -1326,6 +1327,7 @@ main(int argc, char **argv) | |||
1326 | } | 1327 | } |
1327 | else if (test > 0) | 1328 | else if (test > 0) |
1328 | { | 1329 | { |
1330 | one_test = 1; | ||
1329 | ui_num(test); | 1331 | ui_num(test); |
1330 | } | 1332 | } |
1331 | 1333 | ||
diff --git a/src/bin/main.h b/src/bin/main.h index 5a861eb..4f373b5 100644 --- a/src/bin/main.h +++ b/src/bin/main.h | |||
@@ -47,6 +47,7 @@ extern "C" | |||
47 | extern Evas *evas; | 47 | extern Evas *evas; |
48 | extern int win_w, win_h; | 48 | extern int win_w, win_h; |
49 | extern int loops; | 49 | extern int loops; |
50 | extern int one_test; | ||
50 | extern const char *choosen_engine; | 51 | extern const char *choosen_engine; |
51 | extern Eina_Bool fullscreen; | 52 | extern Eina_Bool fullscreen; |
52 | extern Eina_Bool cmp_report; | 53 | extern Eina_Bool cmp_report; |
diff --git a/src/bin/ui.c b/src/bin/ui.c index 243ab11..147075d 100644 --- a/src/bin/ui.c +++ b/src/bin/ui.c | |||
@@ -504,6 +504,7 @@ ui_num(int n) | |||
504 | if (!mi->test) | 504 | if (!mi->test) |
505 | return; | 505 | return; |
506 | menu_sel = n; | 506 | menu_sel = n; |
507 | if (one_test) test_item = menu_sel; | ||
507 | _ui_select(); | 508 | _ui_select(); |
508 | } | 509 | } |
509 | } | 510 | } |
@@ -714,7 +715,7 @@ ui_fps(double fps) | |||
714 | 715 | ||
715 | test_item++; | 716 | test_item++; |
716 | mi = eina_list_nth(menu, test_item); | 717 | mi = eina_list_nth(menu, test_item); |
717 | if (!mi->test) | 718 | if (one_test || !mi->test) |
718 | { | 719 | { |
719 | char datestr[1024]; | 720 | char datestr[1024]; |
720 | struct tm *tim; | 721 | struct tm *tim; |