static char *EatPrefix(char *text, const char *prefix)
{
if (int len = strlen(prefix))
- if (memicmp(text, prefix, len) == 0)
+ if (_memicmp(text, prefix, len) == 0)
return text + len;
return 0;
}
m_codepage = 0;
if (FILE *f = _tfopen(szDllFileName, _T("r")))
{
- std::vector<int> lines;
+ std::vector<unsigned> lines;
std::string format;
std::string directive;
std::string msgid;
if (msgstr.empty())
msgstr = msgid;
unslash(msgstr);
- for (int *pline = lines.begin() ; pline < lines.end() ; ++pline)
+ for (unsigned *pline = &*lines.begin() ; pline < &*lines.end() ; ++pline)
{
- int line = *pline;
+ unsigned line = *pline;
if (m_strarray.size() <= line)
m_strarray.resize(line + 1);
m_strarray[line] = msgstr;
{
ws.resize(len);
const char *msgstr = m_strarray[line].c_str();
- len = MultiByteToWideChar(m_codepage, 0, msgstr, -1, ws.begin(), len + 1);
+ len = MultiByteToWideChar(m_codepage, 0, msgstr, -1, &*ws.begin(), len + 1);
ASSERT(*msgstr == 0 || len != 0);
ws.resize(len - 1);
return true;
{
if (LPCWSTR text = pItemData->GetWideString())
{
- int line = 0;
- swscanf(text, L"Merge.rc:%d", &line);
+ unsigned line = 0;
+ swscanf(text, L"Merge.rc:%u", &line);
std::wstring s;
if (TranslateString(line, s))
pItemData->SetWideString(s.c_str());
TCHAR text[80];
if (::GetMenuString(h, i, text, RTL_NUMBER_OF(text), MF_BYPOSITION))
{
- int line = 0;
- _stscanf(text, _T("Merge.rc:%d"), &line);
+ unsigned line = 0;
+ _stscanf(text, _T("Merge.rc:%u"), &line);
String s;
if (TranslateString(line, s))
::ModifyMenu(h, i, mii.fState | MF_BYPOSITION, mii.wID, s.c_str());
{
TCHAR text[80];
::GetWindowText(h, text, RTL_NUMBER_OF(text));
- int line = 0;
- _stscanf(text, _T("Merge.rc:%d"), &line);
+ unsigned line = 0;
+ _stscanf(text, _T("Merge.rc:%u"), &line);
String s;
if (TranslateString(line, s))
::SetWindowText(h, s.c_str());
TCHAR text[1024];
AfxLoadString(id, text, RTL_NUMBER_OF(text));
#if LANG_PO(FALSE, TRUE) // compiling for use with .PO files
- int line = 0;
- _stscanf(text, _T("Merge.rc:%d"), &line);
+ unsigned line = 0;
+ _stscanf(text, _T("Merge.rc:%u"), &line);
if (!TranslateString(line, s))
#endif
s = text;
while (*text++);
// Caption string is ahead
#if LANG_PO(FALSE, TRUE) // compiling for use with .PO files
- int line = 0;
- swscanf(text, L"Merge.rc:%d", &line);
+ unsigned line = 0;
+ swscanf(text, L"Merge.rc:%u", &line);
if (!TranslateString(line, s))
#endif
s = text;
if (m_pOptionsMgr->ImportOptions(s) == OPT_OK)
{
ReadOptions(TRUE);
- AfxMessageBox(IDS_OPT_IMPORT_DONE, MB_ICONINFORMATION);
+ LangMessageBox(IDS_OPT_IMPORT_DONE, MB_ICONINFORMATION);
}
else
- AfxMessageBox(IDS_OPT_IMPORT_ERR, MB_ICONWARNING);
+ LangMessageBox(IDS_OPT_IMPORT_ERR, MB_ICONWARNING);
}
}
settingsFile += _T(".ini");
if (m_pOptionsMgr->ExportOptions(settingsFile) == OPT_OK)
- AfxMessageBox(IDS_OPT_EXPORT_DONE, MB_ICONINFORMATION);
+ LangMessageBox(IDS_OPT_EXPORT_DONE, MB_ICONINFORMATION);
else
- AfxMessageBox(IDS_OPT_EXPORT_ERR, MB_ICONWARNING);
+ LangMessageBox(IDS_OPT_EXPORT_ERR, MB_ICONWARNING);
}
}