[FORMATTING][RAPPS] available.cpp: Fix braces

svn path=/branches/GSoC_2017/rapps/; revision=75220
This commit is contained in:
Alexander Shaposhnikov 2017-06-27 23:33:15 +00:00
parent 17e36ed120
commit de725c5391

View file

@ -9,7 +9,8 @@
#include "rapps.h"
inline void _AddText(UINT a, LPCWSTR b, DWORD c, DWORD d) {
inline void _AddText(UINT a, LPCWSTR b, DWORD c, DWORD d)
{
if (b[0] != '\0')
{
WCHAR szText[MAX_STR_LEN];
@ -19,7 +20,8 @@ inline void _AddText(UINT a, LPCWSTR b, DWORD c, DWORD d) {
}
}
inline void _AddTextNewl(UINT a, DWORD b) {
inline void _AddTextNewl(UINT a, DWORD b)
{
WCHAR szText[MAX_STR_LEN];
LoadStringW(hInst, a, szText, _countof(szText));
InsertRichEditText(L"\n", 0);
@ -28,13 +30,16 @@ inline void _AddTextNewl(UINT a, DWORD b) {
}
template<typename T, size_t N, size_t N2>
inline BOOL _GetString(LPCWSTR a, T(&b)[N], T (&cFileName)[N2]) {
inline BOOL _GetString(LPCWSTR a, T(&b)[N], T(&cFileName)[N2])
{
return ParserGetString(a, b, N, cFileName);
}
template<typename T, size_t N, size_t N2>
inline void _GetStringNullFailure(LPCWSTR a, T(&b)[N], T (&cFileName)[N2]) {
if (!_GetString(a, b, cFileName)) {
inline void _GetStringNullFailure(LPCWSTR a, T(&b)[N], T(&cFileName)[N2])
{
if (!_GetString(a, b, cFileName))
{
b[0] = '\0';
}
}
@ -52,7 +57,8 @@ inline BOOL _AppInstallCheckWithKey(PAPPLICATION_INFO Info, REGSAM key)
//Check both registry keys in 64bit system
//TODO: check system type beforehand to avoid double checks?
inline BOOL _AppInstallCheck(PAPPLICATION_INFO Info) {
inline BOOL _AppInstallCheck(PAPPLICATION_INFO Info)
{
return _AppInstallCheckWithKey(Info, KEY_WOW64_32KEY)
|| _AppInstallCheckWithKey(Info, KEY_WOW64_64KEY);
}
@ -94,7 +100,8 @@ ShowAvailableAppInfo(INT Index)
{
_AddText(IDS_AINFO_VERSION, szVersion, CFE_BOLD, 0);
}
} else
}
else
{
_AddTextNewl(IDS_STATUS_NOTINSTALLED, CFE_ITALIC);
}
@ -157,7 +164,8 @@ DeleteCurrentAppsDB(VOID)
continue;
result = result && DeleteFileW(szTmp);
} while (FindNextFileW(hFind, &FindFileData) != 0);
}
while (FindNextFileW(hFind, &FindFileData) != 0);
FindClose(hFind);
@ -329,7 +337,8 @@ skip_if_cached:
if (!lpEnumProc(Info))
break;
} while (FindNextFileW(hFind, &FindFileData) != 0);
}
while (FindNextFileW(hFind, &FindFileData) != 0);
FindClose(hFind);