seoz pushed a commit to branch master.

http://git.enlightenment.org/core/elementary.git/commit/?id=ea8155b0faa6ab435867e9561501a61972d08925

commit ea8155b0faa6ab435867e9561501a61972d08925
Author: Daniel Juyung Seo <seojuyu...@gmail.com>
Date:   Wed Nov 6 13:36:34 2013 +0900

    elm_list.c: fixed a bug when any item is selected without control on multi 
select with control mode.
    
    When any item is selected without control on multi select with control 
mode, already selected items should be unselected automatically.
---
 src/lib/elm_list.c | 22 +++++++---------------
 1 file changed, 7 insertions(+), 15 deletions(-)

diff --git a/src/lib/elm_list.c b/src/lib/elm_list.c
index fef56cf..66d6651 100644
--- a/src/lib/elm_list.c
+++ b/src/lib/elm_list.c
@@ -1294,27 +1294,19 @@ _mouse_up_cb(void *data,
    evas_object_ref(obj);
    _elm_list_walk(sd);
 
-   if (sd->multi)
+   if (sd->multi &&
+       ((sd->multi_select_mode != ELM_OBJECT_MULTI_SELECT_MODE_WITH_CONTROL) ||
+        (evas_key_modifier_is_set(ev->modifiers, "Control"))))
      {
-        if (((sd->multi_select_mode != 
ELM_OBJECT_MULTI_SELECT_MODE_WITH_CONTROL) ||
-             (evas_key_modifier_is_set(ev->modifiers, "Control"))))
+        if (!it->selected)
           {
-             if (!it->selected)
-               {
-                  _item_highlight(it);
-                  _item_select(it);
-               }
-             else
-               {
-                  _item_unhighlight(it);
-                  _item_unselect(it);
-               }
+             _item_highlight(it);
+             _item_select(it);
           }
         else
           {
              _item_unhighlight(it);
-             if (it->selected)
-               _item_unselect(it);
+             _item_unselect(it);
           }
      }
    else

-- 


Reply via email to