diff options
Diffstat (limited to 'plugins/YAMN/src/proto/pop3/pop3opt.cpp')
-rw-r--r-- | plugins/YAMN/src/proto/pop3/pop3opt.cpp | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/plugins/YAMN/src/proto/pop3/pop3opt.cpp b/plugins/YAMN/src/proto/pop3/pop3opt.cpp index 76d45d294a..4aaf1db2c1 100644 --- a/plugins/YAMN/src/proto/pop3/pop3opt.cpp +++ b/plugins/YAMN/src/proto/pop3/pop3opt.cpp @@ -119,7 +119,7 @@ INT_PTR CALLBACK DlgProcPluginOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lParam case IDC_STWWW:
{
char str[1024];
- GetDlgItemTextA(hDlg,IDC_STWWW,str,SIZEOF(str));
+ GetDlgItemTextA(hDlg,IDC_STWWW,str,_countof(str));
CallService(MS_UTILS_OPENURL,OUF_NEWWINDOW,(LPARAM)str);
break;
}
@@ -721,7 +721,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara case WM_YAMN_CHANGETIME:
if ((HPOP3ACCOUNT)wParam == ActualAccount) {
TCHAR Text[256];
- mir_sntprintf(Text,SIZEOF(Text),TranslateT("Time left to next check [s]: %d"),(DWORD)lParam);
+ mir_sntprintf(Text,_countof(Text),TranslateT("Time left to next check [s]: %d"),(DWORD)lParam);
SetDlgItemText(hDlg,IDC_STTIMELEFT,Text);
}
return TRUE;
@@ -734,14 +734,14 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara ActualAccount=NULL;
DlgSetItemText(hDlg,(WPARAM)IDC_STTIMELEFT,0);
- if (GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,SIZEOF(DlgInput)))
+ if (GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,_countof(DlgInput)))
DlgEnableAccount(hDlg,TRUE,FALSE);
else
DlgEnableAccount(hDlg,FALSE,FALSE);
break;
case CBN_KILLFOCUS:
- GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,SIZEOF(DlgInput));
+ GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,_countof(DlgInput));
if (NULL==(ActualAccount=(HPOP3ACCOUNT)CallService(MS_YAMN_FINDACCOUNTBYNAME,(WPARAM)POP3Plugin,(LPARAM)DlgInput))) {
DlgSetItemText(hDlg,(WPARAM)IDC_STTIMELEFT,0);
EnableWindow(GetDlgItem(hDlg,IDC_BTNDEL),FALSE);
@@ -864,7 +864,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara case IDC_BTNAPP:
{
TCHAR filter[MAX_PATH];
- mir_sntprintf(filter, SIZEOF(filter), _T("%s (*.exe;*.bat;*.cmd;*.com)%c*.exe;*.bat;*.cmd;*.com%c%s (*.*)%c*.*%c"),
+ mir_sntprintf(filter, _countof(filter), _T("%s (*.exe;*.bat;*.cmd;*.com)%c*.exe;*.bat;*.cmd;*.com%c%s (*.*)%c*.*%c"),
TranslateT("Executables"), 0, 0, TranslateT("All Files"), 0, 0);
OPENFILENAME OFNStruct = { 0 };
@@ -892,7 +892,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara break;
case IDC_BTNDEL:
- GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,SIZEOF(DlgInput));
+ GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,_countof(DlgInput));
EnableWindow(GetDlgItem(hDlg,IDC_BTNDEL),FALSE);
if ((CB_ERR==(Result=SendDlgItemMessage(hDlg,IDC_COMBOACCOUNT,CB_GETCURSEL,0,0)))
|| (NULL==(ActualAccount=(HPOP3ACCOUNT)CallService(MS_YAMN_FINDACCOUNTBYNAME,(WPARAM)POP3Plugin,(LPARAM)DlgInput))))
@@ -939,7 +939,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara size_t Length,index;
UINT Port,Interval;
- if ( GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT, Text, SIZEOF(Text))) {
+ if ( GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT, Text, _countof(Text))) {
Check = (IsDlgButtonChecked(hDlg,IDC_CHECK)==BST_CHECKED);
CheckSSL = (IsDlgButtonChecked(hDlg,IDC_CHECKSSL)==BST_CHECKED);
CheckNoTLS = (IsDlgButtonChecked(hDlg,IDC_CHECKNOTLS)==BST_CHECKED);
@@ -975,15 +975,15 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara break;
}
- GetDlgItemTextA(hDlg, IDC_EDITAPP, Text, SIZEOF(Text));
+ GetDlgItemTextA(hDlg, IDC_EDITAPP, Text, _countof(Text));
if (CheckApp && !(Length = mir_strlen(Text))) {
MessageBox(hDlg,TranslateT("Please select application to run"),TranslateT("Input error"),MB_OK);
break;
}
- GetDlgItemTextA(hDlg, IDC_COMBOACCOUNT, Text, SIZEOF(Text));
+ GetDlgItemTextA(hDlg, IDC_COMBOACCOUNT, Text, _countof(Text));
if ( !( Length = mir_strlen(Text))) {
- GetDlgItemTextA(hDlg,IDC_EDITNAME, Text, SIZEOF(Text));
+ GetDlgItemTextA(hDlg,IDC_EDITNAME, Text, _countof(Text));
if ( !(Length = mir_strlen( Text )))
break;
}
@@ -1036,7 +1036,7 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara DebugLog(SynchroFile,"Options:APPLY:ActualAccountSO-write enter\n");
#endif
- GetDlgItemTextA(hDlg, IDC_EDITNAME, Text, SIZEOF(Text));
+ GetDlgItemTextA(hDlg, IDC_EDITNAME, Text, _countof(Text));
if ( !(Length = mir_strlen( Text )))
break;
if (NULL != ActualAccount->Name)
@@ -1044,31 +1044,31 @@ INT_PTR CALLBACK DlgProcPOP3AccOpt(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPara ActualAccount->Name = new char[ mir_strlen(Text)+1];
mir_strcpy(ActualAccount->Name,Text);
- GetDlgItemTextA(hDlg,IDC_EDITSERVER,Text,SIZEOF(Text));
+ GetDlgItemTextA(hDlg,IDC_EDITSERVER,Text,_countof(Text));
if (NULL != ActualAccount->Server->Name)
delete[] ActualAccount->Server->Name;
ActualAccount->Server->Name=new char[ mir_strlen(Text)+1];
mir_strcpy(ActualAccount->Server->Name,Text);
- GetDlgItemTextA(hDlg,IDC_EDITLOGIN,Text,SIZEOF(Text));
+ GetDlgItemTextA(hDlg,IDC_EDITLOGIN,Text,_countof(Text));
if (NULL != ActualAccount->Server->Login)
delete[] ActualAccount->Server->Login;
ActualAccount->Server->Login=new char[ mir_strlen(Text)+1];
mir_strcpy(ActualAccount->Server->Login,Text);
- GetDlgItemTextA(hDlg,IDC_EDITPASS,Text,SIZEOF(Text));
+ GetDlgItemTextA(hDlg,IDC_EDITPASS,Text,_countof(Text));
if (NULL != ActualAccount->Server->Passwd)
delete[] ActualAccount->Server->Passwd;
ActualAccount->Server->Passwd=new char[ mir_strlen(Text)+1];
mir_strcpy(ActualAccount->Server->Passwd,Text);
- GetDlgItemTextW(hDlg,IDC_EDITAPP,TextW,SIZEOF(TextW));
+ GetDlgItemTextW(hDlg,IDC_EDITAPP,TextW,_countof(TextW));
if (NULL != ActualAccount->NewMailN.App)
delete[] ActualAccount->NewMailN.App;
ActualAccount->NewMailN.App=new WCHAR[mir_wstrlen(TextW)+1];
mir_wstrcpy(ActualAccount->NewMailN.App,TextW);
- GetDlgItemTextW(hDlg,IDC_EDITAPPPARAM,TextW,SIZEOF(TextW));
+ GetDlgItemTextW(hDlg,IDC_EDITAPPPARAM,TextW,_countof(TextW));
if (NULL != ActualAccount->NewMailN.AppParam)
delete[] ActualAccount->NewMailN.AppParam;
ActualAccount->NewMailN.AppParam=new WCHAR[mir_wstrlen(TextW)+1];
@@ -1258,7 +1258,7 @@ INT_PTR CALLBACK DlgProcPOP3AccPopup(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPa {
case CBN_KILLFOCUS:
- GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,SIZEOF(DlgInput));
+ GetDlgItemTextA(hDlg,IDC_COMBOACCOUNT,DlgInput,_countof(DlgInput));
if (NULL==(ActualAccount=(HPOP3ACCOUNT)CallService(MS_YAMN_FINDACCOUNTBYNAME,(WPARAM)POP3Plugin,(LPARAM)DlgInput)))
{
DlgSetItemText(hDlg,(WPARAM)IDC_STTIMELEFT,0);
@@ -1434,7 +1434,7 @@ INT_PTR CALLBACK DlgProcPOP3AccPopup(HWND hDlg,UINT msg,WPARAM wParam,LPARAM lPa BOOL CheckPopN;
UINT Time,TimeN,TimeF;
- if (GetDlgItemText(hDlg,IDC_COMBOACCOUNT,Text,SIZEOF(Text)))
+ if (GetDlgItemText(hDlg,IDC_COMBOACCOUNT,Text,_countof(Text)))
{
CheckPopup = (IsDlgButtonChecked(hDlg,IDC_CHECKPOP)==BST_CHECKED);
CheckPopupW = (IsDlgButtonChecked(hDlg,IDC_CHECKCOL)==BST_CHECKED);
|