mirror of
https://github.com/reactos/reactos.git
synced 2025-02-22 16:36:33 +00:00
[NOTEPAD] Use StringCchPrintf instead (#5654)
Use preferred string functions. CORE-18837
This commit is contained in:
parent
eb6561bbc7
commit
3f921d1119
2 changed files with 3 additions and 3 deletions
|
@ -164,7 +164,7 @@ int DIALOG_StringMsgBox(HWND hParent, int formatId, LPCTSTR szString, DWORD dwFl
|
|||
|
||||
/* Load and format szMessage */
|
||||
LoadString(Globals.hInstance, formatId, szResource, _countof(szResource));
|
||||
_sntprintf(szMessage, _countof(szMessage), szResource, szString);
|
||||
StringCchPrintf(szMessage, _countof(szMessage), szResource, szString);
|
||||
|
||||
/* Load szCaption */
|
||||
if ((dwFlags & MB_ICONMASK) == MB_ICONEXCLAMATION)
|
||||
|
@ -880,7 +880,7 @@ VOID DIALOG_StatusBarUpdateCaretPos(VOID)
|
|||
line = SendMessage(Globals.hEdit, EM_LINEFROMCHAR, (WPARAM)dwStart, 0);
|
||||
col = dwStart - SendMessage(Globals.hEdit, EM_LINEINDEX, (WPARAM)line, 0);
|
||||
|
||||
_stprintf(buff, Globals.szStatusBarLineCol, line + 1, col + 1);
|
||||
StringCchPrintf(buff, _countof(buff), Globals.szStatusBarLineCol, line + 1, col + 1);
|
||||
SendMessage(Globals.hStatusBar, SB_SETTEXT, SBPART_CURPOS, (LPARAM)buff);
|
||||
}
|
||||
|
||||
|
|
|
@ -202,7 +202,7 @@ BOOL NOTEPAD_FindNext(FINDREPLACE *pFindReplace, BOOL bReplace, BOOL bShowAlert)
|
|||
if (bShowAlert)
|
||||
{
|
||||
LoadString(Globals.hInstance, STRING_CANNOTFIND, szResource, _countof(szResource));
|
||||
_sntprintf(szText, _countof(szText), szResource, pFindReplace->lpstrFindWhat);
|
||||
StringCchPrintf(szText, _countof(szText), szResource, pFindReplace->lpstrFindWhat);
|
||||
LoadString(Globals.hInstance, STRING_NOTEPAD, szResource, _countof(szResource));
|
||||
MessageBox(Globals.hFindReplaceDlg, szText, szResource, MB_OK);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue