Fix Focus Bug 46/37146/2
authorKim Tae Soo <taesoo46.kim@samsung.com>
Fri, 20 Mar 2015 00:44:28 +0000 (09:44 +0900)
committerKim Tae Soo <taesoo46.kim@samsung.com>
Fri, 20 Mar 2015 01:09:14 +0000 (10:09 +0900)
1. focused_item value should be updated when gengrid is updated.
2. Use CViewMgr::PopView when context view is needed to be hided

Change-Id: I04a08f4370d08c316ff50ae839634e849629d593
Signed-off-by: Kim Tae Soo <taesoo46.kim@samsung.com>
src/views/category-layout.cpp
src/views/playlist-layout.cpp

index 6041718..0767255 100644 (file)
@@ -939,6 +939,7 @@ void CCategoryLayout::m_CreateCatgrid(bool sort_flag)
                m_AddCategoryItem(grid_item, t_CategoryType(), info);
 
        elm_gengrid_item_class_free(grid_item);
+       t.focused_item = elm_gengrid_first_item_get(t.grid);
 
        elm_object_part_content_set(Layout(),
                MUSIC_PART_CATEGORY_GRID, t.grid);
index 5ba4c7e..cd64474 100644 (file)
@@ -91,8 +91,9 @@ void CPlaylistLayout::m_PlaylistCtxtAction(EActionType type)
 
        catinfo = (CCategoryInfo *)t.ctxtinfo->context;
 
-       if (!CViewMgr::GetInstance()->PushView(MUSIC_BASE_VIEW, NULL)) {
-               _ERR(" viewmgr show failed ");
+       // Show base view
+       if (!CViewMgr::GetInstance()->PopView()) {
+               _ERR("CViewMgr::PopView to show BaseView is failed.");
                return;
        }