mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
convert info strings to UTF-16
svn path=/trunk/; revision=15740
This commit is contained in:
parent
9719715092
commit
d0551f0760
1 changed files with 10 additions and 2 deletions
|
@ -1847,15 +1847,23 @@ static void CheckForFileInfo(struct PropertiesDialog* dlg, HWND hwnd, LPCTSTR st
|
||||||
|
|
||||||
for(p=InfoStrings; *p; ++p) {
|
for(p=InfoStrings; *p; ++p) {
|
||||||
TCHAR subblock[200];
|
TCHAR subblock[200];
|
||||||
|
#ifdef UNICODE
|
||||||
|
TCHAR infoStr[100];
|
||||||
|
#endif
|
||||||
LPCTSTR pTxt;
|
LPCTSTR pTxt;
|
||||||
UINT nValLen;
|
UINT nValLen;
|
||||||
|
|
||||||
LPCSTR pInfoString = *p;
|
LPCSTR pInfoString = *p;
|
||||||
wsprintf(subblock, sStringFileInfo, pTranslate->wLanguage, pTranslate->wCodePage, pInfoString);
|
#ifdef UNICODE
|
||||||
|
MultiByteToWideChar(CP_ACP, 0, pInfoString, -1, infoStr, 100);
|
||||||
|
#else
|
||||||
|
#define infoStr pInfoString
|
||||||
|
#endif
|
||||||
|
wsprintf(subblock, sStringFileInfo, pTranslate->wLanguage, pTranslate->wCodePage, infoStr);
|
||||||
|
|
||||||
/* Retrieve file description for language and code page */
|
/* Retrieve file description for language and code page */
|
||||||
if (VerQueryValue(dlg->pVersionData, subblock, (PVOID)&pTxt, &nValLen)) {
|
if (VerQueryValue(dlg->pVersionData, subblock, (PVOID)&pTxt, &nValLen)) {
|
||||||
int idx = ListBox_AddString(hlbox, pInfoString);
|
int idx = ListBox_AddString(hlbox, infoStr);
|
||||||
ListBox_SetItemData(hlbox, idx, pTxt);
|
ListBox_SetItemData(hlbox, idx, pTxt);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue