Modified load items flag
authorSangYong Lee <sangyongim.lee@samsung.com>
Wed, 10 Apr 2013 05:45:09 +0000 (14:45 +0900)
committerSangYong Lee <sangyongim.lee@samsung.com>
Wed, 10 Apr 2013 05:45:09 +0000 (14:45 +0900)
Change-Id: I3bad7509162b7ac11e0fa10081f4ab9d670a0231
Signed-off-by: SangYong Lee <sangyongim.lee@samsung.com>
src/ui/controls/FUiCtrl_TableViewPresenter.cpp

index 30e729a..43267e3 100644 (file)
@@ -1070,12 +1070,8 @@ _TableViewPresenter::PreloadItem(int topDrawnGroupIndex, int topDrawnItemIndex,
                shiftingDistance = 0;
        }
 
-       __lockLoadItemWithScroll = true;
-
        ScrollToItem(topDrawnGroupIndex, topDrawnItemIndex, TABLE_VIEW_SCROLL_ITEM_ALIGNMENT_TOP, shiftingDistance);
 
-       __lockLoadItemWithScroll = false;
-
        AdjustClientAreaBounds(true);
 
        if (__pTableView->GetScrollStyle() == TABLE_VIEW_SCROLL_BAR_STYLE_FAST_SCROLL)
@@ -1425,6 +1421,8 @@ _TableViewPresenter::LoadItem(int groupIndex, int itemIndex)
 
        if ((pItem != null) && !pItem->HasParent())
        {
+               __lockLoadItemWithScroll = true;
+
                __pTableView->AttachChild(*pItem);
 
                pItem->SetDrawingProperty(__pItemDrawingProperty);
@@ -1434,6 +1432,8 @@ _TableViewPresenter::LoadItem(int groupIndex, int itemIndex)
                SetItemLayout(pItem, itemPosition);
                pItem->SetReorderMode(__pTableView->IsReorderModeEnabled());
                pItem->AdjustChildControlMargin();
+
+               __lockLoadItemWithScroll = false;
        }
 
        return pItem;