Fixed issue 56312
authorHimanshu <himanshu.t@samsung.com>
Mon, 28 Oct 2013 09:04:53 +0000 (14:34 +0530)
committerHimanshu <himanshu.t@samsung.com>
Mon, 28 Oct 2013 09:04:53 +0000 (14:34 +0530)
Change-Id: Icd811d79398a4d5ac0ba54c0d2a073720b672bcc
Signed-off-by: Himanshu <himanshu.t@samsung.com>
src/GlAllListEditorPanel.cpp

index 83c53e8..d019e21 100644 (file)
@@ -38,9 +38,9 @@ using namespace Tizen::Media;
 using namespace Tizen::Ui::Controls;
 using namespace Tizen::Ui::Scenes;
 
-static const int H_COUNT_LABEL = 48;
-static const int H_COUNT_LABEL_BUTTON = 42;
-static const int W_COUNT_LABEL_BUTTON = 42;
+static const float H_COUNT_LABEL = 48.0f;
+static const float H_COUNT_LABEL_BUTTON = 42.0f;
+static const float W_COUNT_LABEL_BUTTON = 42.0f;
 static const int COUNT_LABEL_FONT_SIZE = 33;
 static const int H_CONTENT_MARGIN = 9;
 static const int W_CONTENT_MARGIN = 6;
@@ -96,8 +96,9 @@ AllListEditorPanel::OnInitializing(void)
        __pPresentationModel->ClearThumbnailRequests();
        __pPresentationModel->AddPresentationModelListener(this);
 
-       Rectangle clientAreaBounds = pForm->GetClientAreaBounds();
-       SetBounds(0, 0, clientAreaBounds.width, clientAreaBounds.height);
+       FloatRectangle clientAreaBounds = pForm->GetClientAreaBoundsF();
+       SetBounds(0.0f, 0.0f, clientAreaBounds.width, clientAreaBounds.height);
+
 
        __pContentIconListView = new (std::nothrow) IconListView();
        __pContentIconListView->Construct(Rectangle(0, 0, clientAreaBounds.width, clientAreaBounds.height - H_COUNT_LABEL),
@@ -125,7 +126,7 @@ AllListEditorPanel::OnInitializing(void)
        String strTmp;
        strTmp = ResourceManager::GetString(L"IDS_ST_POP_NO_ITEMS_SELECTED").GetPointer();
        __pLabelSelectCnt->Construct(
-                       Rectangle(0, clientAreaBounds.height - H_COUNT_LABEL, clientAreaBounds.width, H_COUNT_LABEL), strTmp);
+                       FloatRectangle(0, clientAreaBounds.height - H_COUNT_LABEL, clientAreaBounds.width, H_COUNT_LABEL), strTmp);
        __pLabelSelectCnt->SetTextVerticalAlignment(ALIGNMENT_MIDDLE);
        __pLabelSelectCnt->SetTextHorizontalAlignment(ALIGNMENT_LEFT);
        __pLabelSelectCnt->SetBackgroundColor(COLOR_COUNT_LABEL);
@@ -135,7 +136,7 @@ AllListEditorPanel::OnInitializing(void)
        __pLabelSelectCnt->Invalidate(true);
 
        __pButtonSelectRegion = new (std::nothrow) Button();
-       __pButtonSelectRegion->Construct(Rectangle(clientAreaBounds.width - W_COUNT_LABEL_BUTTON - 10,
+       __pButtonSelectRegion->Construct(FloatRectangle(clientAreaBounds.width - W_COUNT_LABEL_BUTTON - 10,
                        clientAreaBounds.height - H_COUNT_LABEL_BUTTON - 4, W_COUNT_LABEL_BUTTON, H_COUNT_LABEL_BUTTON),
                        EMPTY_SPACE);
        __pButtonSelectRegion->SetActionId(IDA_BUTTON_MOVE_TO_SELECTION);
@@ -632,12 +633,12 @@ AllListEditorPanel::ChangeOrientation(void)
        const Form* pForm = dynamic_cast<Form*>(pSceneManager->GetCurrentScene()->GetForm());
        TryReturn(pForm != null,, "[%s] fail to get the form.", GetErrorMessage(GetLastResult()));
 
-       Rectangle clientAreaBounds = pForm->GetClientAreaBounds();
-       SetBounds(0, 0, clientAreaBounds.width, clientAreaBounds.height);
-       __pContentIconListView->SetBounds(0, 0, clientAreaBounds.width, clientAreaBounds.height - H_COUNT_LABEL);
-       __pLabelSelectCnt->SetBounds(0, clientAreaBounds.height - H_COUNT_LABEL, clientAreaBounds.width, H_COUNT_LABEL);
-       __pButtonSelectRegion->SetBounds(clientAreaBounds.width - W_COUNT_LABEL_BUTTON - 10,
-                       clientAreaBounds.height - H_COUNT_LABEL_BUTTON - 4, W_COUNT_LABEL_BUTTON, H_COUNT_LABEL_BUTTON);
+       FloatRectangle clientAreaBounds = pForm->GetClientAreaBoundsF();
+       SetBounds(0.0f, 0.0f, clientAreaBounds.width, clientAreaBounds.height);
+       __pContentIconListView->SetBounds(0.0f, 0.0f, clientAreaBounds.width, clientAreaBounds.height - H_COUNT_LABEL);
+       __pLabelSelectCnt->SetBounds(0.0f, clientAreaBounds.height - H_COUNT_LABEL, clientAreaBounds.width, H_COUNT_LABEL);
+       __pButtonSelectRegion->SetBounds(clientAreaBounds.width - W_COUNT_LABEL_BUTTON - 10.0f,
+                       clientAreaBounds.height - H_COUNT_LABEL_BUTTON - 4.0f, W_COUNT_LABEL_BUTTON, H_COUNT_LABEL_BUTTON);
 }
 
 result