From: hb.min Date: Mon, 18 Mar 2013 13:29:28 +0000 (+0900) Subject: Modify GetInfoValue method to use the PrivilegeInfo class X-Git-Tag: accepted/tizen_2.1/20130425.023719~11 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=630a4a6fbe6ff09dcb58f99d545281e2da64b403;p=apps%2Fosp%2FInstaller.git Modify GetInfoValue method to use the PrivilegeInfo class Change-Id: Ia7cefc58ba0faa42ba2c6f43ebdf93949e108d2b Signed-off-by: hb.min --- diff --git a/src/IstDetailForm.cpp b/src/IstDetailForm.cpp index dd017e8..810345d 100644 --- a/src/IstDetailForm.cpp +++ b/src/IstDetailForm.cpp @@ -110,13 +110,16 @@ result DetailForm::GetInfoValue(int groupIndex, int itemIndex, String& name, String& description) { String value; - String privilege; + PrivilegeInfo* pPrivilege = null; TryReturn(groupIndex == 0, E_FAILURE, "Group Index Error"); - privilege = dynamic_cast (__pPrivilegeList->GetAt(itemIndex))->GetPointer(); + pPrivilege = dynamic_cast (__pPrivilegeList->GetAt(itemIndex)); - name = PrivilegeInfo::GetName(privilege); - description = PrivilegeInfo::GetDescription(privilege); + if (pPrivilege != null) + { + name = pPrivilege->GetDisplayName(); + description = pPrivilege->GetDescription(); + } return E_SUCCESS; }