Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions sakura_core/cmd/CViewCommander_Search.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -809,7 +809,7 @@ void CViewCommander::Command_REPLACE_ALL()
int nReplaceNum = 0;
HWND hwndStatic = ::GetDlgItem( hwndCancel, IDC_STATIC_KENSUU );
WCHAR szLabel[64];
_itot( nReplaceNum, szLabel, 10 );
_itow( nReplaceNum, szLabel, 10 );
::SendMessage( hwndStatic, WM_SETTEXT, 0, (LPARAM)szLabel );

CLayoutRange sRangeA; //選択範囲
Expand Down Expand Up @@ -1033,7 +1033,7 @@ void CViewCommander::Command_REPLACE_ALL()
Progress_SetPos( hwndProgress, nNewPos );
nOldPos = nNewPos;
}
_itot( nReplaceNum, szLabel, 10 );
_itow( nReplaceNum, szLabel, 10 );
::SendMessage( hwndStatic, WM_SETTEXT, 0, (LPARAM)szLabel );
}

Expand Down Expand Up @@ -1449,7 +1449,7 @@ void CViewCommander::Command_REPLACE_ALL()
}
//>> 2002/03/26 Azumaiya

_itot( nReplaceNum, szLabel, 10 );
_itow( nReplaceNum, szLabel, 10 );
::SendMessage( hwndStatic, WM_SETTEXT, 0, (LPARAM)szLabel );

if( !cDlgCancel.IsCanceled() ){
Expand Down
4 changes: 2 additions & 2 deletions sakura_core/dlg/CDlgTagJumpList.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,7 @@ bool CDlgTagJumpList::GetFullPathAndLine( int index, WCHAR *fullPath, int count,
const WCHAR *p = fileName;
if( p[0] == L'\\' ){
wcscpy( dirFileName, p );
}else if( _istalpha( p[0] ) && p[1] == L':' ){
}else if( iswalpha( p[0] ) && p[1] == L':' ){
wcscpy( dirFileName, p );
}else{
// 相対パス:連結する
Expand Down Expand Up @@ -1617,7 +1617,7 @@ WCHAR* CDlgTagJumpList::GetFullPathFromDepth( WCHAR* pszOutput, int count,
const WCHAR *p = fileName;
if( p[0] == L'\\' ){ //ドライブなし絶対パスか?
wcscpy( pszOutput, p ); //何も加工しない。
}else if( _istalpha( p[0] ) && p[1] == L':' ){ //絶対パスか?
}else if( iswalpha( p[0] ) && p[1] == L':' ){ //絶対パスか?
wcscpy( pszOutput, p ); //何も加工しない。
}else{
for( int i = 0; i < depth; i++ ){
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/env/CFileNameManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ bool CFileNameManager::ExpandMetaToFolder( LPCWSTR pszSrc, LPWSTR pszDes, int nD
szMeta, szPath, _countof( szPath ) );
}
if( false == bFolderPath || L'\0' == szPath[0] ){
pStr = _tgetenv( szMeta );
pStr = _wgetenv( szMeta );
// 環境変数
if( NULL != pStr ){
nPathLen = wcslen( pStr );
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/env/CShareData_IO.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ bool CShareData_IO::ShareData_IO_2( bool bRead )
DWORD mH, mL, lH, lL;
mH = mL = lH = lL = 0; // ※ 古~い ini だと "szVersion" は無い
if( cProfile.IOProfileData(LTEXT("Other"), L"szVersion", StringBufferW(iniVer)) )
_stscanf( iniVer, L"%u.%u.%u.%u", &mH, &mL, &lH, &lL );
swscanf( iniVer, L"%u.%u.%u.%u", &mH, &mL, &lH, &lL );
DWORD dwMS = (DWORD)MAKELONG(mL, mH);
DWORD dwLS = (DWORD)MAKELONG(lL, lH);
DLLSHAREDATA* pShareData = &GetDllShareData();
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/func/CKeyBind.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ WCHAR* CKeyBind::MakeMenuLabel(const WCHAR* sName, const WCHAR* sKey)
}
else {
if( !GetDllShareData().m_Common.m_sMainMenu.m_bMainMenuKeyParentheses
&& (((p = wcschr( sName, sKey[0])) != NULL) || ((p = wcschr( sName, _totlower(sKey[0]))) != NULL)) ){
&& (((p = wcschr( sName, sKey[0])) != nullptr) || ((p = wcschr( sName, towlower(sKey[0]))) != nullptr)) ){
// 欧文風、使用している文字をアクセスキーに
wcscpy_s( sLabel, _countof(sLabel), sName );
sLabel[p-sName] = L'&';
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/macro/CMacroFactory.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ std::wstring CMacroFactory::Ext2Key(const WCHAR *ext)
}

std::wstring key = ext;
std::transform( key.begin(), key.end(), key.begin(), _totlower);
std::transform( key.begin(), key.end(), key.begin(), towlower);

return key;
}
Expand Down
4 changes: 2 additions & 2 deletions sakura_core/prop/CPropComMacro.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -272,7 +272,7 @@ void CPropMacro::SetData( HWND hwndDlg )

// マクロ停止ダイアログ表示待ち時間
WCHAR szCancelTimer[16] = {0};
::DlgItem_SetText( hwndDlg, IDC_MACROCANCELTIMER, _itot(m_Common.m_sMacro.m_nMacroCancelTimer, szCancelTimer, 10) );
::DlgItem_SetText( hwndDlg, IDC_MACROCANCELTIMER, _itow(m_Common.m_sMacro.m_nMacroCancelTimer, szCancelTimer, 10) );

return;
}
Expand Down Expand Up @@ -422,7 +422,7 @@ void CPropMacro::InitDialog( HWND hwndDlg )
sItem.mask = LVIF_TEXT | LVIF_PARAM;
sItem.iItem = pos;
sItem.iSubItem = 0;
_itot( pos, buf, 10 );
_itow( pos, buf, 10 );
sItem.pszText = buf;
sItem.lParam = pos;
ListView_InsertItem( hListView, &sItem );
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/prop/CPropComPlugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ void CPropPlugin::SetData_LIST( HWND hwndDlg )
sItem.mask = LVIF_TEXT | LVIF_PARAM;
sItem.iItem = index;
sItem.iSubItem = 0;
_itot( index, buf, 10 );
_itow( index, buf, 10 );
sItem.pszText = buf;
sItem.lParam = index;
ListView_InsertItem( hListView, &sItem );
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/typeprop/CDlgTypeAscertain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ BOOL CDlgTypeAscertain::OnBnClicked( int wID )
m_psi->sColorFile.clear();
m_psi->nColorType = Combo_GetCurSel( GetItemHwnd( IDC_COMBO_COLORS ) ) - 1;
if (m_psi->nColorType >= MAX_TYPES && Combo_GetLBText( GetItemHwnd( IDC_COMBO_COLORS ), m_psi->nColorType + 1, buff1)) {
if (_stscanf( buff1, L"File -- %ls", buff2 ) > 0) {
if (swscanf( buff1, L"File -- %ls", buff2 ) > 0) {
m_psi->sColorFile = buff2;
m_psi->nColorType = MAX_TYPES;
}
Expand Down
4 changes: 2 additions & 2 deletions sakura_core/uiparts/CMenuDrawer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1424,7 +1424,7 @@ WCHAR CMenuDrawer::GetAccelCharFromLabel( const WCHAR* pszLabel )
if( L'&' == pszLabel[i + 1] ){
i++;
}else{
return (WCHAR)_totupper( pszLabel[i + 1] );
return (WCHAR)towupper( pszLabel[i + 1] );
}
}
}
Expand All @@ -1451,7 +1451,7 @@ LRESULT CMenuDrawer::OnMenuChar( HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPa
chUser += '@';
}
else {
chUser = (WCHAR)_totupper( chUser );
chUser = (WCHAR)towupper( chUser );
}

// 2011.11.18 vector化
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/util/file.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,7 @@ bool IsLocalDrive( const WCHAR* pszDrive )
long lngRet;

if( iswalpha(pszDrive[0]) ){
auto_sprintf(szDriveType, L"%c:\\", _totupper(pszDrive[0]));
auto_sprintf(szDriveType, L"%c:\\", towupper(pszDrive[0]));
lngRet = GetDriveType( szDriveType );
if( lngRet == DRIVE_REMOVABLE || lngRet == DRIVE_CDROM || lngRet == DRIVE_REMOTE )
{
Expand Down
6 changes: 3 additions & 3 deletions sakura_core/util/format.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,15 @@ UINT32 ParseVersion( const WCHAR* sVer )
else p++;
nShift = 0x20;
}
else if( !_istdigit(*p) ){
else if( !iswdigit(*p) ){
nShift = -0x80;
}
else{
nShift = 0;
}
while( *p && !_istdigit(*p) ){ p++; }
while( *p && !iswdigit(*p) ){ p++; }
//数値の抽出
for( nVer = 0, nDigit = 0; _istdigit(*p); p++ ){
for( nVer = 0, nDigit = 0; iswdigit(*p); p++ ){
if( ++nDigit > 2 )break; //数字は2桁までで止める
nVer = nVer * 10 + *p - L'0';
}
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/util/string_ex.h
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ inline int auto_sprintf(WCHAR* buf, const WCHAR* format, ...) { va_list args; va

inline int auto_vsprintf_s(ACHAR* buf, size_t nBufCount, const ACHAR* format, va_list& v) { return ::_vsnprintf_s(buf, nBufCount, _TRUNCATE, format, v); }
inline int auto_vsprintf_s(WCHAR* buf, size_t nBufCount, const WCHAR* format, va_list& v) { return ::_vsnwprintf_s(buf, nBufCount, _TRUNCATE, format, v); }
#define auto_snprintf_s(buf, nBufCount, format, ...) ::_sntprintf_s((buf), nBufCount, _TRUNCATE, (format), __VA_ARGS__)
#define auto_snprintf_s(buf, nBufCount, format, ...) ::_snwprintf_s((buf), nBufCount, _TRUNCATE, (format), __VA_ARGS__)

std::wstring& eos(std::wstring& strOut, size_t cchOut);
std::string& eos(std::string& strOut, size_t cchOut);
Expand Down
2 changes: 1 addition & 1 deletion sakura_core/view/CEditView_Command.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ open_c:;
_wsplitpath( GetDocument()->m_cDocFile.GetFilePath(), szDrive, szDir, szFname, szExt );

for( i = 0; i < open_extno; i++ ){
_tmakepath( szPath, szDrive, szDir, szFname, open_ext[i] );
_wmakepath( szPath, szDrive, szDir, szFname, open_ext[i] );
if( !fexist(szPath) ){
if( i < open_extno - 1 )
continue;
Expand Down