From f60a8402bb44fd471c7a71cf2d671dbae8f76585 Mon Sep 17 00:00:00 2001 From: Michael BOUCHAUD Date: Tue, 23 Oct 2012 15:13:09 +0000 Subject: [PATCH] elementary: fix promote on first item and demote on last item of a genlist SVN revision: 78375 --- src/lib/elm_genlist.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lib/elm_genlist.c b/src/lib/elm_genlist.c index cc46c6e..76b2580 100644 --- a/src/lib/elm_genlist.c +++ b/src/lib/elm_genlist.c @@ -3723,6 +3723,7 @@ _item_move_after(Elm_Gen_Item *it, { if (!it) return; if (!after) return; + if (it == after) return; GL_IT(it)->wsd->items = eina_inlist_remove(GL_IT(it)->wsd->items, EINA_INLIST_GET(it)); @@ -3747,6 +3748,7 @@ _item_move_before(Elm_Gen_Item *it, { if (!it) return; if (!before) return; + if (it == before) return; GL_IT(it)->wsd->items = eina_inlist_remove(GL_IT(it)->wsd->items, EINA_INLIST_GET(it)); -- 2.7.4