diff options
author | Mike Blumenkrantz <zmike@samsung.com> | 2019-10-21 10:30:45 -0400 |
---|---|---|
committer | Marcel Hollerbach <mail@marcel-hollerbach.de> | 2019-10-29 16:08:39 +0100 |
commit | 5ab30b1e01195b73293fdc18bf3eed5b41c5db68 (patch) | |
tree | c9cf5b5ae64623d82eafbb0f1e806f86f7dafe12 | |
parent | 555f456b39ad26a55f4f74ed8e99f709cebe0181 (diff) | |
download | efl-5ab30b1e01195b73293fdc18bf3eed5b41c5db68.tar.gz |
tests/elm: add util callback for incrementing an int data
this is a common functionality
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10509
-rw-r--r-- | src/tests/elementary/suite_helpers.c | 8 | ||||
-rw-r--r-- | src/tests/elementary/suite_helpers.h | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/src/tests/elementary/suite_helpers.c b/src/tests/elementary/suite_helpers.c index a109f838db..8aebdcb3f0 100644 --- a/src/tests/elementary/suite_helpers.c +++ b/src/tests/elementary/suite_helpers.c @@ -524,6 +524,14 @@ event_callback_single_call_int_data(void *data, Evas_Object *obj EINA_UNUSED, vo } void +event_callback_that_increments_an_int_when_called(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) +{ + int *called = data; + + *called += 1; +} + +void event_callback_that_quits_the_main_loop_when_called() { ecore_main_loop_quit(); diff --git a/src/tests/elementary/suite_helpers.h b/src/tests/elementary/suite_helpers.h index d0ada37fb8..928dda9637 100644 --- a/src/tests/elementary/suite_helpers.h +++ b/src/tests/elementary/suite_helpers.h @@ -19,4 +19,5 @@ void wheel_part(Eo *obj, const char *part, Eina_Bool horiz, Eina_Bool down); void wheel_object_at(Eo *obj, int x, int y, Eina_Bool horiz, Eina_Bool down); void event_callback_single_call_int_data(void *data, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED); void event_callback_that_quits_the_main_loop_when_called(); +void event_callback_that_increments_an_int_when_called(void *data, Evas_Object *obj, void *event_info); #endif |