set focus to name when there is no text with selected done btn 30/45530/1
authorSoohye Shin <soohye.shin@samsung.com>
Fri, 7 Aug 2015 06:59:07 +0000 (15:59 +0900)
committerSoohye Shin <soohye.shin@samsung.com>
Fri, 7 Aug 2015 06:59:07 +0000 (15:59 +0900)
Change-Id: I3b4f9a21d6b767553b398e74e23b7c3dd1855416
Signed-off-by: Soohye Shin <soohye.shin@samsung.com>
src/view/view_user_edit.c

index 2496098..6c4ca4e 100644 (file)
@@ -530,8 +530,13 @@ static void _select_btn_done(struct _priv *priv)
                priv->di->icon = strdup(photo ? photo :
                                IMAGE_USER_DEFAULT);
                datamgr_select_item(priv->dm, priv->di);
-       } else
+       } else {
+               if (!name || !strcmp(name, "")) {
+                       elm_object_focus_set(priv->name, EINA_TRUE);
+                       return;
+               }
                datamgr_add_item(priv->dm, name, photo, "");
+       }
 
        priv->di = NULL;
        viewmgr_pop_view();