From 3280ada8e96cdc194007d41cc67d2d6b8bea46d5 Mon Sep 17 00:00:00 2001 From: Carsten Haitzler Date: Fri, 25 May 2012 09:18:48 +0000 Subject: [PATCH] fix mainloop begin/quit then begin again issue. SVN revision: 71419 --- legacy/ecore/ChangeLog | 8 ++++++++ legacy/ecore/src/lib/ecore/ecore_main.c | 3 +++ 2 files changed, 11 insertions(+) diff --git a/legacy/ecore/ChangeLog b/legacy/ecore/ChangeLog index 5c99801..482c0e7 100644 --- a/legacy/ecore/ChangeLog +++ b/legacy/ecore/ChangeLog @@ -675,3 +675,11 @@ will hold a loop busy and not allow feedback workers to run, so now have fairer scheduling. * Allow 16 * cpu num for worker threads (default still cpu num) + +2012-05-25 Carsten Haitzler (The Rasterman) + + * Fix ecore mainloop issue if you begin the mainloop, keep a + timer around, quit mainloop, then start it again expecting the timer + to keep ticking off. also happens to be an issuw with + iterating the mainloop. + diff --git a/legacy/ecore/src/lib/ecore/ecore_main.c b/legacy/ecore/src/lib/ecore/ecore_main.c index 3107c3f..949a14c 100644 --- a/legacy/ecore/src/lib/ecore/ecore_main.c +++ b/legacy/ecore/src/lib/ecore/ecore_main.c @@ -860,6 +860,7 @@ ecore_main_loop_iterate(void) EINA_MAIN_LOOP_CHECK_RETURN; #ifndef USE_G_MAIN_LOOP _ecore_lock(); + _ecore_time_loop_time = ecore_time_get(); _ecore_main_loop_iterate_internal(1); _ecore_unlock(); #else @@ -890,6 +891,7 @@ ecore_main_loop_iterate_may_block(int may_block) EINA_MAIN_LOOP_CHECK_RETURN_VAL(0); #ifndef USE_G_MAIN_LOOP _ecore_lock(); + _ecore_time_loop_time = ecore_time_get(); in_main_loop++; _ecore_main_loop_iterate_internal(!may_block); in_main_loop--; @@ -925,6 +927,7 @@ ecore_main_loop_begin(void) #ifndef USE_G_MAIN_LOOP _ecore_lock(); in_main_loop++; + _ecore_time_loop_time = ecore_time_get(); while (do_quit == 0) _ecore_main_loop_iterate_internal(0); do_quit = 0; in_main_loop--; -- 2.7.4