summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2016-07-29 11:57:10 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2016-07-29 11:57:10 +0900
commit5f224a6671f7d9100213bc6a99745b75fa351abc (patch)
tree9def4b442c7839565671e72887156c8370acd703
parent518c59166c2856ec1fbacbc63e26d5a52b906f99 (diff)
efl - elm genlist - clean up sanghyeon's patch to be less code
use if not while, no first, and timing checkis already done at end so remove from if/while. cleaner now.
-rw-r--r--src/lib/elementary/elm_genlist.c11
1 files changed, 3 insertions, 8 deletions
diff --git a/src/lib/elementary/elm_genlist.c b/src/lib/elementary/elm_genlist.c
index 4c596c49f8..7e36fb3259 100644
--- a/src/lib/elementary/elm_genlist.c
+++ b/src/lib/elementary/elm_genlist.c
@@ -7573,25 +7573,20 @@ static int
7573_filter_queue_process(Elm_Genlist_Data *sd) 7573_filter_queue_process(Elm_Genlist_Data *sd)
7574{ 7574{
7575 int n; 7575 int n;
7576 Elm_Gen_Item *it, *first; 7576 Elm_Gen_Item *it;
7577 double t0; 7577 double t0;
7578 7578
7579 t0 = ecore_time_get(); 7579 t0 = ecore_time_get();
7580 for (n = 0; ((sd->filter_queue) && (sd->processed_count < ITEM_QUEUE_MAX)); n++) 7580 for (n = 0; ((sd->filter_queue) && (sd->processed_count < ITEM_QUEUE_MAX)); n++)
7581 { 7581 {
7582 it = first = eina_list_data_get(sd->filter_queue); 7582 it = eina_list_data_get(sd->filter_queue);
7583 //FIXME: This is added as a fail safe code for items not yet processed. 7583 //FIXME: This is added as a fail safe code for items not yet processed.
7584 while (it && it->item->queued) 7584 if (it && it->item->queued)
7585 { 7585 {
7586 if ((ecore_time_get() - t0) > (ecore_animator_frametime_get()))
7587 return n;
7588 sd->filter_queue = eina_list_remove_list 7586 sd->filter_queue = eina_list_remove_list
7589 (sd->filter_queue, sd->filter_queue); 7587 (sd->filter_queue, sd->filter_queue);
7590 sd->filter_queue = eina_list_append(sd->filter_queue, it); 7588 sd->filter_queue = eina_list_append(sd->filter_queue, it);
7591 it = eina_list_data_get(sd->filter_queue); 7589 it = eina_list_data_get(sd->filter_queue);
7592
7593 //Do not iterate more than one loop
7594 if (it == first) return n;
7595 } 7590 }
7596 sd->filter_queue = eina_list_remove_list(sd->filter_queue, sd->filter_queue); 7591 sd->filter_queue = eina_list_remove_list(sd->filter_queue, sd->filter_queue);
7597 _filter_item_internal(it); 7592 _filter_item_internal(it);