Apply string localization for authentication popup
authorHyun Lee <hyunn.lee@samsung.com>
Wed, 8 May 2013 08:59:51 +0000 (17:59 +0900)
committerHyun Lee <hyunn.lee@samsung.com>
Wed, 8 May 2013 08:59:51 +0000 (17:59 +0900)
Change-Id: I39eb7b1c8ebd0c76160da74fc211f8914c83b7ea
Signed-off-by: Hyun Lee <hyunn.lee@samsung.com>
src/controls/FWebCtrl_AuthConfirmPopup.cpp

index ae32ed0..9182343 100755 (executable)
@@ -84,11 +84,11 @@ _AuthConfirmPopup::Construct(const String& host, const String& realm, Authentica
 
        Rectangle rect(0, 0, 0, 0);
        rect.width = pPopupData->popupDim.width;
-       rect.height = (5*pPopupData->spacePad) + (pPopupData->editDim.height*2) + pPopupData->btnDim.height + 2*pPopupData->labelDim.height;
+       rect.height = (5*pPopupData->spacePad) + (pPopupData->editDim.height*2) + pPopupData->btnDim.height + (2*pPopupData->labelDim.height);
        r = _WebPopup::Construct(true, Dimension(rect.width, rect.height));
        SysTryReturn(NID_WEB_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
 
-       SetTitleText("Authentication Required");
+       SetTitleText(pSysResource->GetString(_RESOURCE_DOMAIN_ID_OSP, "IDS_BR_BODY_DESTINATIONS_AUTHENTICATION_REQUIRED"));
 
        //host realm label
        rect.height = 2*pPopupData->labelDim.height;
@@ -96,9 +96,8 @@ _AuthConfirmPopup::Construct(const String& host, const String& realm, Authentica
        std::unique_ptr<Label> pLabel(new (std::nothrow) Label());
        SysTryReturnResult(NID_WEB_CTRL, pLabel.get(), E_OUT_OF_MEMORY, "Memory Allocation failed.");
 
-       String hostRealm(L"A username and password are being requested by ");
-       hostRealm.Append(host);
-       hostRealm.Append(L". The site says: \"");
+       String hostRealm(host);
+       hostRealm.Append(L": \n ");
        hostRealm.Append(realm);
        hostRealm.Append(L"\"");
        r = pLabel->Construct(rect, hostRealm);
@@ -123,7 +122,7 @@ _AuthConfirmPopup::Construct(const String& host, const String& realm, Authentica
        r = pIdEditField->Construct(rect, EDIT_FIELD_STYLE_NORMAL);
        SysTryReturn(NID_WEB_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
 
-       pIdEditField->SetGuideText(L"User name");
+       pIdEditField->SetGuideText(pSysResource->GetString(_RESOURCE_DOMAIN_ID_OSP, "IDS_BR_BODY_AUTHUSERNAME"));
        pIdEditField->SetGuideTextColor(Color::GetColor(COLOR_ID_GREY));
        pIdEditField->SetTextSize(35);;
 
@@ -138,7 +137,7 @@ _AuthConfirmPopup::Construct(const String& host, const String& realm, Authentica
        r = pPwdEditField->Construct(rect, EDIT_FIELD_STYLE_PASSWORD);
        SysTryReturn(NID_WEB_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
 
-       pPwdEditField->SetGuideText(L"Password");
+       pPwdEditField->SetGuideText(pSysResource->GetString(_RESOURCE_DOMAIN_ID_OSP, "IDS_BR_BODY_AUTHPASSWORD"));
        pPwdEditField->SetGuideTextColor(Color::GetColor(COLOR_ID_GREY));
        pPwdEditField->SetTextSize(35);;
 
@@ -161,8 +160,8 @@ _AuthConfirmPopup::Construct(const String& host, const String& realm, Authentica
        ArrayList titleList;
        r = titleList.Construct();
        SysTryReturn(NID_WEB_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));
-       titleList.Add(*(new String(pSysResource->GetString("sys_string", "IDS_COM_SK_OK"))));
-       titleList.Add(*(new String(pSysResource->GetString("sys_string", "IDS_COM_POP_CANCEL"))));
+       titleList.Add(*(new String(pSysResource->GetString(_RESOURCE_DOMAIN_ID_OSP, "IDS_COM_BUTTON_LOGIN"))));
+       titleList.Add(*(new String(pSysResource->GetString(_RESOURCE_DOMAIN_ID_OSP, "IDS_COM_SK_CANCEL"))));
 
        r = CreateAndAddButtons(idList, titleList, pButtonPanel);
        SysTryReturn(NID_WEB_CTRL, r == E_SUCCESS, r, r, "[%s] Propagating.", GetErrorMessage(r));