elementary: use initialization information to initialize test application once.

This commit is contained in:
Cedric BAIL 2016-07-06 15:52:05 -07:00
parent cdf04241db
commit 99018bcb5f
1 changed files with 16 additions and 11 deletions

View File

@ -1027,6 +1027,8 @@ efl_main(void *data EINA_UNUSED,
Eina_Bool test_win_only = EINA_FALSE;
char *autorun = NULL;
if (arge->initialization)
{
_log_domain = eina_log_domain_register("elementary_test", NULL);
eo_event_callback_add(ev->object, EO_EVENT_DEL, _main_loop_death, NULL);
@ -1039,6 +1041,12 @@ efl_main(void *data EINA_UNUSED,
elm_app_compile_data_dir_set(PACKAGE_DATA_DIR);
elm_app_info_set(efl_main, "elementary", "images/logo.png");
elm_color_class_translate_cb_set(colorclass_tl_cb);
elm_color_class_list_cb_set(colorclass_list_cb);
/* put here any init specific to this app like parsing args etc. */
}
/* if called with a single argument try to autorun a test with
* the same name as the given param
* ex: elementary_test "Box Vert 2" */
@ -1069,9 +1077,6 @@ efl_main(void *data EINA_UNUSED,
}
}
elm_color_class_translate_cb_set(colorclass_tl_cb);
elm_color_class_list_cb_set(colorclass_list_cb);
/* put here any init specific to this app like parsing args etc. */
my_win_main(autorun, test_win_only); /* create main window */
/* FIXME: Hum, no exit code anywhere anymore ? */