https://git.reactos.org/?p=reactos.git;a=commitdiff;h=da8810ab889727d7863c6…
commit da8810ab889727d7863c60e9e0bb4d72e0ca58ef
Author: 赫杨 <1160386205(a)qq.com>
AuthorDate: Mon Aug 17 02:46:37 2020 +0800
Commit: Mark Jansen <mark.jansen(a)reactos.org>
CommitDate: Sun Sep 6 17:10:17 2020 +0200
[RAPPS] add m_szPkgName for AvailableApps
---
base/applications/rapps/available.cpp | 7 +++++++
base/applications/rapps/include/available.h | 3 ++-
2 files changed, 9 insertions(+), 1 deletion(-)
diff --git a/base/applications/rapps/available.cpp
b/base/applications/rapps/available.cpp
index 155840be11b..88a1bf9a8b9 100644
--- a/base/applications/rapps/available.cpp
+++ b/base/applications/rapps/available.cpp
@@ -38,6 +38,13 @@ VOID
CAvailableApplicationInfo::RetrieveGeneralInfo(AvailableStrings& AvlbString
{
m_Parser = new CConfigParser(m_sFileName);
+ // TODO: I temporarily use the file name (without suffix) as package name.
+ // It should be better to put this in a field of ini file.
+ // consider write a converter to do this and write a github action for rapps-db to
ensure package_name is unique.
+ m_szPkgName = m_sFileName;
+ PathRemoveExtensionW(m_szPkgName.GetBuffer(MAX_PATH));
+ m_szPkgName.ReleaseBuffer();
+
m_Parser->GetInt(L"Category", m_Category);
if (!GetString(L"Name", m_szName)
diff --git a/base/applications/rapps/include/available.h
b/base/applications/rapps/include/available.h
index 2ee8136cc91..8000c3b11fc 100644
--- a/base/applications/rapps/include/available.h
+++ b/base/applications/rapps/include/available.h
@@ -43,7 +43,7 @@ public:
INT m_Category;
//BOOL m_IsSelected;
LicenseType m_LicenseType;
- ATL::CStringW m_szName;
+ ATL::CStringW m_szName; // software's display name.
ATL::CStringW m_szRegName;
ATL::CStringW m_szVersion;
ATL::CStringW m_szLicense;
@@ -54,6 +54,7 @@ public:
ATL::CSimpleArray<LCID> m_LanguageLCIDs;
ATL::CSimpleArray<ATL::CStringW> m_szScrnshotLocation;
ATL::CStringW m_szIconLocation;
+ ATL::CStringW m_szPkgName; // software's package name.
ULONG m_SizeBytes;