From: Jaehyun Cho Date: Wed, 9 Aug 2017 14:32:35 +0000 (+0900) Subject: elc_naviframe: Fix to handle item deletion right after item push X-Git-Tag: submit/sandbox/upgrade/efl120/20180319.053334~3225 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=be0af0ed00148c55e1eb519444ea48201677badb;p=platform%2Fupstream%2Fefl.git elc_naviframe: Fix to handle item deletion right after item push If an item is deleted right after the item is newly pushed, the push transition should not happen for both the new item and the current item. --- diff --git a/src/lib/elementary/elc_naviframe.c b/src/lib/elementary/elc_naviframe.c index 42f5a40..f057bb5 100644 --- a/src/lib/elementary/elc_naviframe.c +++ b/src/lib/elementary/elc_naviframe.c @@ -616,8 +616,16 @@ end: // make sure there is no more reference to this item. EINA_LIST_FOREACH(sd->ops, l, nfo) { - if (nfo->related == nit) nfo->related = NULL; - if (nfo->self == nit) nfo->self = NULL; + /* If an transition is cancelled by deleting an item, then the pair + * transition also should be cancelled. + * This case can happen when an item is deleted by elm_object_item_del() + * right after the item is newly pushed. + */ + if ((nfo->self == nit) || (nfo->related == nit)) + { + nfo->self = NULL; + nfo->related = NULL; + } } _item_free(nit);