diff options
24 files changed, 56 insertions, 56 deletions
diff --git a/plugins/BasicHistory/src/Options.cpp b/plugins/BasicHistory/src/Options.cpp index 97b0ccad99..f421dc1104 100644 --- a/plugins/BasicHistory/src/Options.cpp +++ b/plugins/BasicHistory/src/Options.cpp @@ -1767,7 +1767,7 @@ INT_PTR CALLBACK Options::DlgProcOptsTask(HWND hwndDlg, UINT msg, WPARAM wParam, toCp.importType = (enum IImport::ImportType)ComboBox_GetCurSel(GetDlgItem(hwndDlg, IDC_IMPORT_TYPE));
toCp.compress = Button_GetCheck(GetDlgItem(hwndDlg, IDC_COMPRESS)) != 0;
char bufC[100];
- GetWindowTextA(GetDlgItem(hwndDlg, IDC_PASSWORD), bufC, SIZEOF(bufC));
+ GetDlgItemTextA(hwndDlg, IDC_PASSWORD, bufC, SIZEOF(bufC));
toCp.zipPassword = bufC;
HWND exportPath = GetDlgItem(hwndDlg, IDC_EXPORT_PATH);
int exLen = Edit_GetTextLength(exportPath);
diff --git a/plugins/BuddyPounce/src/dialog.cpp b/plugins/BuddyPounce/src/dialog.cpp index 38de85b198..de7e487105 100644 --- a/plugins/BuddyPounce/src/dialog.cpp +++ b/plugins/BuddyPounce/src/dialog.cpp @@ -593,9 +593,9 @@ INT_PTR CALLBACK PounceSentDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lP case IDOK:
{
TCHAR text[2048];
- GetWindowText(GetDlgItem(hwnd, IDOK), text, SIZEOF(text));
+ GetDlgItemText(hwnd, IDOK, text, SIZEOF(text));
if (!_tcscmp(text, TranslateT("Retry"))) {
- GetWindowText(GetDlgItem(hwnd,IDC_MESSAGE), text, SIZEOF(text));
+ GetDlgItemText(hwnd, IDC_MESSAGE, text, SIZEOF(text));
SendPounce(text, hContact);
}
}
diff --git a/plugins/Clist_modern/src/modern_clistopts.cpp b/plugins/Clist_modern/src/modern_clistopts.cpp index 2b72c6bb6a..10d0b1670a 100644 --- a/plugins/Clist_modern/src/modern_clistopts.cpp +++ b/plugins/Clist_modern/src/modern_clistopts.cpp @@ -727,7 +727,7 @@ static INT_PTR CALLBACK DlgProcItemSecondLineOpts(HWND hwndDlg, UINT msg, WPARAM db_set_w(NULL, "CList", "SecondLineType", (WORD)radio);
TCHAR t[TEXT_TEXT_MAX_LENGTH];
- GetWindowText(GetDlgItem(hwndDlg, IDC_VARIABLE_TEXT), t, SIZEOF(t));
+ GetDlgItemText(hwndDlg, IDC_VARIABLE_TEXT, t, SIZEOF(t));
t[TEXT_TEXT_MAX_LENGTH - 1] = '\0';
db_set_ts(NULL, "CList", "SecondLineText", t);
@@ -894,7 +894,7 @@ static INT_PTR CALLBACK DlgProcItemThirdLineOpts(HWND hwndDlg, UINT msg, WPARAM {
TCHAR t[TEXT_TEXT_MAX_LENGTH];
- GetWindowText(GetDlgItem(hwndDlg, IDC_VARIABLE_TEXT), t, SIZEOF(t));
+ GetDlgItemText(hwndDlg, IDC_VARIABLE_TEXT, t, SIZEOF(t));
t[TEXT_TEXT_MAX_LENGTH - 1] = '\0';
db_set_ws(NULL, "CList", "ThirdLineText", t);
diff --git a/plugins/Clist_nicer/skineditor/src/main.cpp b/plugins/Clist_nicer/skineditor/src/main.cpp index 3125a9304a..ac45005c8a 100644 --- a/plugins/Clist_nicer/skineditor/src/main.cpp +++ b/plugins/Clist_nicer/skineditor/src/main.cpp @@ -424,31 +424,31 @@ static void UpdateStatusStructSettingsFromOptDlg(HWND hwndDlg, int index) p->TEXTCOLOR = SendDlgItemMessage(hwndDlg, IDC_TEXTCOLOUR, CPM_GETCOLOUR, 0, 0); if (ChangedSItems.bALPHA) { - GetWindowTextA(GetDlgItem(hwndDlg, IDC_ALPHA), buf, 10); // can be removed now + GetDlgItemTextA(hwndDlg, IDC_ALPHA, buf, 10); // can be removed now if (buf[0] != 0) p->ALPHA = (BYTE) SendDlgItemMessage(hwndDlg, IDC_ALPHASPIN, UDM_GETPOS, 0, 0); } if (ChangedSItems.bMARGIN_LEFT) { - GetWindowTextA(GetDlgItem(hwndDlg, IDC_MRGN_LEFT), buf, 10); + GetDlgItemTextA(hwndDlg, IDC_MRGN_LEFT, buf, 10); if (buf[0] != 0) p->MARGIN_LEFT = (BYTE) SendDlgItemMessage(hwndDlg, IDC_MRGN_LEFT_SPIN, UDM_GETPOS, 0, 0); } if (ChangedSItems.bMARGIN_TOP) { - GetWindowTextA(GetDlgItem(hwndDlg, IDC_MRGN_TOP), buf, 10); + GetDlgItemTextA(hwndDlg, IDC_MRGN_TOP, buf, 10); if (buf[0] != 0) p->MARGIN_TOP = (BYTE) SendDlgItemMessage(hwndDlg, IDC_MRGN_TOP_SPIN, UDM_GETPOS, 0, 0); } if (ChangedSItems.bMARGIN_RIGHT) { - GetWindowTextA(GetDlgItem(hwndDlg, IDC_MRGN_RIGHT), buf, 10); + GetDlgItemTextA(hwndDlg, IDC_MRGN_RIGHT, buf, 10); if (buf[0] != 0) p->MARGIN_RIGHT = (BYTE) SendDlgItemMessage(hwndDlg, IDC_MRGN_RIGHT_SPIN, UDM_GETPOS, 0, 0); } if (ChangedSItems.bMARGIN_BOTTOM) { - GetWindowTextA(GetDlgItem(hwndDlg, IDC_MRGN_BOTTOM), buf, 10); + GetDlgItemTextA(hwndDlg, IDC_MRGN_BOTTOM, buf, 10); if (buf[0] != 0) p->MARGIN_BOTTOM = (BYTE) SendDlgItemMessage(hwndDlg, IDC_MRGN_BOTTOM_SPIN, UDM_GETPOS, 0, 0); } diff --git a/plugins/DbEditorPP/src/addeditsettingsdlg.cpp b/plugins/DbEditorPP/src/addeditsettingsdlg.cpp index 015523d8d8..53c6d1b9f9 100644 --- a/plugins/DbEditorPP/src/addeditsettingsdlg.cpp +++ b/plugins/DbEditorPP/src/addeditsettingsdlg.cpp @@ -283,7 +283,7 @@ INT_PTR CALLBACK EditSettingDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l if (setting)
{
// havta convert it with mir_snprintf()
- GetWindowText(GetDlgItem(hwnd, IDC_SETTINGVALUE), setting, settingLength+1);
+ GetDlgItemText(hwnd, IDC_SETTINGVALUE, setting, settingLength + 1);
if (LOWORD(wParam) == CHK_DECIMAL && IsDlgButtonChecked(hwnd, CHK_DECIMAL))
{
sscanf(setting, "%X", &tmp);
@@ -339,14 +339,14 @@ INT_PTR CALLBACK EditSettingDlgProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM l break;
}
- GetWindowText(GetDlgItem(hwnd, IDC_SETTINGNAME), setting, settingLength+1);
+ GetDlgItemText(hwnd, IDC_SETTINGNAME, setting, settingLength + 1);
if (valueLength)
{
if (dbsetting->dbv.type == DBVT_UTF8)
GetDlgItemTextW(hwnd, valueID, (LPWSTR)value, (valueLength + 2));
else
- GetWindowText(GetDlgItem(hwnd, valueID), value, valueLength+1);
+ GetDlgItemText(hwnd, valueID, value, valueLength + 1);
}
else
if (IsWindowVisible(GetDlgItem(hwnd,IDC_STRING)) || (saveAsType(hwnd)==3))
diff --git a/plugins/Exchange/src/dlg_handlers.cpp b/plugins/Exchange/src/dlg_handlers.cpp index e690c9d156..52b11dabd9 100644 --- a/plugins/Exchange/src/dlg_handlers.cpp +++ b/plugins/Exchange/src/dlg_handlers.cpp @@ -111,16 +111,16 @@ INT_PTR CALLBACK DlgProcOptions(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPara db_set_b(NULL, ModuleName, "Check", IsDlgButtonChecked(hWnd, IDC_CHECK_EMAILS));
TCHAR buffer[4096];
- GetWindowText(GetDlgItem(hWnd, IDC_USER_EDIT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_USER_EDIT, buffer, SIZEOF(buffer));
db_set_ts(NULL, ModuleName, "Username", buffer);
- GetWindowText(GetDlgItem(hWnd, IDC_PASSWORD_EDIT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_PASSWORD_EDIT, buffer, SIZEOF(buffer));
db_set_ts(NULL, ModuleName, "Password", buffer);
- GetWindowText(GetDlgItem(hWnd, IDC_SERVER_EDIT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_SERVER_EDIT, buffer, SIZEOF(buffer));
db_set_ts(NULL, ModuleName, "Server", buffer);
- GetWindowText(GetDlgItem(hWnd, IDC_PORT_EDIT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_PORT_EDIT, buffer, SIZEOF(buffer));
db_set_dw(NULL, ModuleName, "Port", GetDlgItemInt(hWnd,IDC_PORT_EDIT,NULL,FALSE));
db_set_dw(NULL, ModuleName, "Interval", GetDlgItemInt(hWnd,IDC_INTERVAL_EDIT,NULL,FALSE));
diff --git a/plugins/IEHistory/src/dlgHandlers.cpp b/plugins/IEHistory/src/dlgHandlers.cpp index 794f17fe88..b0cb481747 100644 --- a/plugins/IEHistory/src/dlgHandlers.cpp +++ b/plugins/IEHistory/src/dlgHandlers.cpp @@ -550,7 +550,7 @@ INT_PTR CALLBACK OptionsDlgProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPara count = 0; else { TCHAR buffer[1024]; - GetWindowText(GetDlgItem(hWnd, IDC_EVENTS_COUNT), buffer, SIZEOF(buffer)); + GetDlgItemText(hWnd, IDC_EVENTS_COUNT, buffer, SIZEOF(buffer)); count = _tstol(buffer); count = (count < 0) ? 0 : count; } diff --git a/plugins/QuickMessages/src/options.cpp b/plugins/QuickMessages/src/options.cpp index 16644fd2ce..0753b48b17 100644 --- a/plugins/QuickMessages/src/options.cpp +++ b/plugins/QuickMessages/src/options.cpp @@ -123,7 +123,7 @@ void SetMenuEntryProperties(HWND hdlg) {
ListData* ld = ( ListData* )tvi.lParam;
TCHAR szValue[256];
- GetWindowText(GetDlgItem(hdlg,IDC_RCLICKVALUE), szValue, SIZEOF(szValue));
+ GetDlgItemText(hdlg, IDC_RCLICKVALUE, szValue, SIZEOF(szValue));
if(_tcslen(szValue))
{
if(ld->ptszOPQValue&&(ld->ptszOPQValue!=ld->ptszQValue))
@@ -144,7 +144,7 @@ void SetMenuEntryProperties(HWND hdlg) {
ButtonData* bd = ( ButtonData* )tvi.lParam;
TCHAR szValue[256];
- GetWindowText(GetDlgItem(hdlg,IDC_MENUVALUE), szValue, SIZEOF(szValue));
+ GetDlgItemText(hdlg, IDC_MENUVALUE, szValue, SIZEOF(szValue));
if(_tcslen(szValue))
{
if(_tcslen(bd->pszOpValue)&&(bd->pszOpValue!=bd->pszValue))
@@ -836,7 +836,7 @@ INT_PTR CALLBACK OptionsProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lparam) bd = ( ButtonData* )tvi.lParam;
if (bd) {
TCHAR szValue[256];
- GetWindowText(GetDlgItem(hdlg,IDC_MENUVALUE), szValue, SIZEOF(szValue));
+ GetDlgItemText(hdlg, IDC_MENUVALUE, szValue, SIZEOF(szValue));
if(_tcslen(szValue))
{
if(bd->pszOpValue&&(bd->pszOpValue!=bd->pszValue))
@@ -1005,7 +1005,7 @@ INT_PTR CALLBACK OptionsProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lparam) tvis.hParent = NULL;
tvis.hInsertAfter = TVI_LAST;
- GetWindowText(GetDlgItem(hdlg,IDC_BUTTONNAME),namebuff,SIZEOF(namebuff));
+ GetDlgItemText(hdlg, IDC_BUTTONNAME, namebuff, SIZEOF(namebuff));
tvis.item.mask=TVIF_PARAM|TVIF_TEXT;
tvis.item.pszText=(_tcslen(namebuff))?namebuff:TranslateT("New Button");
@@ -1055,7 +1055,7 @@ INT_PTR CALLBACK OptionsProc(HWND hdlg,UINT msg,WPARAM wparam,LPARAM lparam) bd = (ButtonData *)mir_alloc(sizeof(ButtonData));
memset(bd,0,sizeof(ButtonData));
- GetWindowText(GetDlgItem(hdlg,IDC_MENUNAME),namebuff,SIZEOF(namebuff));
+ GetDlgItemText(hdlg, IDC_MENUNAME, namebuff, SIZEOF(namebuff));
bd->dwOPPos=TreeView_GetCount(hMenuTree)-1;
bd->pszOpName=_tcslen(namebuff)?mir_tstrdup(namebuff):mir_tstrdup(TranslateT("New Menu Entry"));
diff --git a/plugins/Sessions/Src/Main.cpp b/plugins/Sessions/Src/Main.cpp index 58309b3e81..6a718e975d 100644 --- a/plugins/Sessions/Src/Main.cpp +++ b/plugins/Sessions/Src/Main.cpp @@ -202,7 +202,7 @@ INT_PTR CALLBACK SaveSessionDlgProc(HWND hdlg, UINT msg, WPARAM wparam, LPARAM l int i = 0, length = GetWindowTextLength(GetDlgItem(hdlg, IDC_LIST));
SavePosition(hdlg, "SaveDlg");
if (length > 0) {
- GetWindowText(GetDlgItem(hdlg, IDC_LIST), szUserSessionName, SIZEOF(szUserSessionName));
+ GetDlgItemText(hdlg, IDC_LIST, szUserSessionName, SIZEOF(szUserSessionName));
szUserSessionName[length + 1] = '\0';
if (IsDlgButtonChecked(hdlg, IDC_SELCONTACTS) && bSC) {
for (MCONTACT hContact = db_find_first(); hContact; hContact = db_find_next(hContact)) {
diff --git a/plugins/SplashScreen/src/options.cpp b/plugins/SplashScreen/src/options.cpp index fddf1bb56a..1e1d955907 100644 --- a/plugins/SplashScreen/src/options.cpp +++ b/plugins/SplashScreen/src/options.cpp @@ -307,25 +307,25 @@ INT_PTR CALLBACK DlgProcOptions(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP {
TCHAR tmp[MAX_PATH];
- GetWindowText(GetDlgItem(hwndDlg, IDC_SPLASHPATH), tmp, SIZEOF(tmp));
+ GetDlgItemText(hwndDlg, IDC_SPLASHPATH, tmp, SIZEOF(tmp));
db_set_ts(NULL, MODNAME, "Path", tmp);
- GetWindowText(GetDlgItem(hwndDlg, IDC_SNDPATH), tmp, SIZEOF(tmp));
+ GetDlgItemText(hwndDlg, IDC_SNDPATH, tmp, SIZEOF(tmp));
db_set_ts(NULL, MODNAME, "Sound", tmp);
- GetWindowText(GetDlgItem(hwndDlg, IDC_VERSIONPREFIX), tmp, SIZEOF(tmp));
+ GetDlgItemText(hwndDlg, IDC_VERSIONPREFIX, tmp, SIZEOF(tmp));
db_set_ts(NULL, MODNAME, "VersionPrefix", tmp);
_tcscpy_s(szPrefix, tmp);
- GetWindowText(GetDlgItem(hwndDlg, IDC_SHOWTIME), tmp, SIZEOF(tmp));
+ GetDlgItemText(hwndDlg, IDC_SHOWTIME, tmp, SIZEOF(tmp));
db_set_dw(NULL, MODNAME, "TimeToShow", _ttoi(tmp));
options.showtime = _ttoi(tmp);
- GetWindowText(GetDlgItem(hwndDlg, IDC_FISTEP), tmp, SIZEOF(tmp));
+ GetDlgItemText(hwndDlg, IDC_FISTEP, tmp, SIZEOF(tmp));
db_set_dw(NULL, MODNAME, "FadeinSpeed", _ttoi(tmp));
options.fisteps = _ttoi(tmp);
- GetWindowText(GetDlgItem(hwndDlg, IDC_FOSTEP), tmp, SIZEOF(tmp));
+ GetDlgItemText(hwndDlg, IDC_FOSTEP, tmp, SIZEOF(tmp));
db_set_dw(NULL, MODNAME, "FadeoutSpeed", _ttoi(tmp));
options.fosteps = _ttoi(tmp);
diff --git a/plugins/TabSRMM/src/selectcontainer.cpp b/plugins/TabSRMM/src/selectcontainer.cpp index 12365c4a0f..9b8121162b 100644 --- a/plugins/TabSRMM/src/selectcontainer.cpp +++ b/plugins/TabSRMM/src/selectcontainer.cpp @@ -102,7 +102,7 @@ INT_PTR CALLBACK SelectContainerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, L TCHAR szNewName[CONTAINER_NAMELEN], szName[CONTAINER_NAMELEN + 1];
int iLen = GetWindowTextLength(GetDlgItem(hwndDlg, IDC_NEWCONTAINERNAME));
if (iLen) {
- GetWindowText(GetDlgItem(hwndDlg, IDC_NEWCONTAINERNAME), szNewName, SIZEOF(szNewName));
+ GetDlgItemText(hwndDlg, IDC_NEWCONTAINERNAME, szNewName, SIZEOF(szNewName));
if (!_tcsncmp(szNewName, CGlobals::m_default_container_name, CONTAINER_NAMELEN) || !_tcsncmp(szNewName, TranslateT("Default container"), CONTAINER_NAMELEN)) {
MessageBox(hwndDlg, TranslateT("You cannot rename the default container"), TranslateT("Error"), MB_OK | MB_ICONERROR);
break;
@@ -144,7 +144,7 @@ INT_PTR CALLBACK SelectContainerDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, L int iLen = GetWindowTextLength(GetDlgItem(hwndDlg, IDC_NEWCONTAINER));
if (iLen) {
- GetWindowText(GetDlgItem(hwndDlg, IDC_NEWCONTAINER), szNewName, SIZEOF(szNewName));
+ GetDlgItemText(hwndDlg, IDC_NEWCONTAINER, szNewName, SIZEOF(szNewName));
int iItem = SendDlgItemMessage(hwndDlg, IDC_CNTLIST, LB_FINDSTRING, (WPARAM)- 1, (LPARAM)szNewName);
if (iItem != LB_ERR || !_tcsncmp(szNewName, CGlobals::m_default_container_name, CONTAINER_NAMELEN)) {
SendDlgItemMessage(hwndDlg, IDC_CNTLIST, LB_GETTEXT, (WPARAM)iItem, (LPARAM)szName);
diff --git a/plugins/TabSRMM/src/templates.cpp b/plugins/TabSRMM/src/templates.cpp index 7cdbeaba65..20aa4eb8f9 100644 --- a/plugins/TabSRMM/src/templates.cpp +++ b/plugins/TabSRMM/src/templates.cpp @@ -254,7 +254,7 @@ INT_PTR CALLBACK DlgProcTemplateEditor(HWND hwndDlg, UINT msg, WPARAM wParam, LP { TCHAR newTemplate[TEMPLATE_LENGTH + 2]; - GetWindowText(GetDlgItem(hwndDlg, IDC_EDITTEMPLATE), newTemplate, SIZEOF(newTemplate)); + GetDlgItemText(hwndDlg, IDC_EDITTEMPLATE, newTemplate, SIZEOF(newTemplate)); memcpy(tSet->szTemplates[teInfo->inEdit], newTemplate, sizeof(TCHAR) * TEMPLATE_LENGTH); teInfo->changed = FALSE; teInfo->updateInfo[teInfo->inEdit] = FALSE; diff --git a/plugins/TrafficCounter/src/options.cpp b/plugins/TrafficCounter/src/options.cpp index 4d58b94f98..3ac48c1f39 100644 --- a/plugins/TrafficCounter/src/options.cpp +++ b/plugins/TrafficCounter/src/options.cpp @@ -310,9 +310,9 @@ static INT_PTR CALLBACK DlgProcTCOptions(HWND hwndDlg, UINT msg, WPARAM wParam, unOptions.ShowOverall = OptTree_GetOptions(hwndDlg, IDC_APPEARANCEOPTIONS, options, optionCount, "ShowOverall");
// Формат счётчиков
- GetWindowText(GetDlgItem(hwndDlg, IDC_EDIT_COUNTER_FORMAT), Traffic_CounterFormat, SIZEOF(Traffic_CounterFormat));
+ GetDlgItemText(hwndDlg, IDC_EDIT_COUNTER_FORMAT, Traffic_CounterFormat, SIZEOF(Traffic_CounterFormat));
// Формат всплывающей подсказки
- GetWindowText(GetDlgItem(hwndDlg, IDC_EDIT_TOOLTIP_FORMAT), Traffic_TooltipFormat, SIZEOF(Traffic_TooltipFormat));
+ GetDlgItemText(hwndDlg, IDC_EDIT_TOOLTIP_FORMAT, Traffic_TooltipFormat, SIZEOF(Traffic_TooltipFormat));
// Ключевой цвет
UseKeyColor = db_get_b(NULL, "ModernSettings", "UseKeyColor", 1);
diff --git a/plugins/WebView/src/webview_datawnd.cpp b/plugins/WebView/src/webview_datawnd.cpp index 256a1bf093..0f98327ede 100644 --- a/plugins/WebView/src/webview_datawnd.cpp +++ b/plugins/WebView/src/webview_datawnd.cpp @@ -57,7 +57,7 @@ INT_PTR CALLBACK DlgProcFind(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPara char *tempbuffer = (char*)malloc(len + 2);
- GetWindowTextA(GetDlgItem(ParentHwnd, IDC_DATA), tempbuffer, len);
+ GetDlgItemTextA(ParentHwnd, IDC_DATA, tempbuffer, len);
strncpy(buff, tempbuffer, SIZEOF(buff));
free(tempbuffer);
diff --git a/plugins/WhenWasIt/src/dlg_handlers.cpp b/plugins/WhenWasIt/src/dlg_handlers.cpp index 015ac86d19..a2a8083483 100644 --- a/plugins/WhenWasIt/src/dlg_handlers.cpp +++ b/plugins/WhenWasIt/src/dlg_handlers.cpp @@ -306,22 +306,22 @@ INT_PTR CALLBACK DlgProcOptions(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPara const int maxSize = 1024;
TCHAR buffer[maxSize];
- GetWindowText(GetDlgItem(hWnd, IDC_DAYS_IN_ADVANCE), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_DAYS_IN_ADVANCE, buffer, SIZEOF(buffer));
TCHAR *stop = NULL;
commonData.daysInAdvance = _tcstol(buffer, &stop, 10);
if (*stop) { commonData.daysInAdvance = DAYS_TO_NOTIFY; }
- GetWindowText(GetDlgItem(hWnd, IDC_DAYS_AFTER), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_DAYS_AFTER, buffer, SIZEOF(buffer));
commonData.daysAfter = _tcstol(buffer, &stop, 10);
if (*stop) { commonData.daysAfter = DAYS_TO_NOTIFY_AFTER; }
- GetWindowText(GetDlgItem(hWnd, IDC_CHECK_INTERVAL), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_CHECK_INTERVAL, buffer, SIZEOF(buffer));
commonData.checkInterval = _ttol(buffer);
if ( !commonData.checkInterval) { commonData.checkInterval = CHECK_INTERVAL; }
- GetWindowText(GetDlgItem(hWnd, IDC_POPUP_TIMEOUT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_POPUP_TIMEOUT, buffer, SIZEOF(buffer));
TCHAR *pos;
pos = _tcschr(buffer, _T('|'));
if (pos) {
@@ -338,12 +338,12 @@ INT_PTR CALLBACK DlgProcOptions(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lPara }
else commonData.popupTimeout = commonData.popupTimeoutToday = _ttol(buffer);
- GetWindowText(GetDlgItem(hWnd, IDC_SOUND_NEAR_DAYS_EDIT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_SOUND_NEAR_DAYS_EDIT, buffer, SIZEOF(buffer));
//cSoundNearDays = _ttol(buffer);
commonData.cSoundNearDays = _tcstol(buffer, &stop, 10);
if (*stop) { commonData.cSoundNearDays = BIRTHDAY_NEAR_DEFAULT_DAYS; }
- GetWindowText(GetDlgItem(hWnd, IDC_DLG_TIMEOUT), buffer, SIZEOF(buffer));
+ GetDlgItemText(hWnd, IDC_DLG_TIMEOUT, buffer, SIZEOF(buffer));
commonData.cDlgTimeout = _tcstol(buffer, &stop, 10);
if (*stop) { commonData.cDlgTimeout = POPUP_TIMEOUT; }
diff --git a/plugins/YAPP/src/yapp_history_dlg.cpp b/plugins/YAPP/src/yapp_history_dlg.cpp index 2c553a68bf..00cda4723c 100644 --- a/plugins/YAPP/src/yapp_history_dlg.cpp +++ b/plugins/YAPP/src/yapp_history_dlg.cpp @@ -438,7 +438,7 @@ void RefreshPopupHistory(HWND hWnd, int renderer) TCHAR filter[MAX_FILTER_SIZE];
DeleteOldEvents(hWnd, renderer); //delete events
- GetWindowText(GetDlgItem(hWnd, IDC_HISTORY_FILTER), filter, SIZEOF(filter)); //get filter text
+ GetDlgItemText(hWnd, IDC_HISTORY_FILTER, filter, SIZEOF(filter)); //get filter text
AddEvents(hWnd, renderer, filter, MatchesFilter);
diff --git a/protocols/IRCG/src/options.cpp b/protocols/IRCG/src/options.cpp index 5fa543c8d1..f07846f49f 100644 --- a/protocols/IRCG/src/options.cpp +++ b/protocols/IRCG/src/options.cpp @@ -1247,8 +1247,8 @@ void CAddIgnoreDlg::OnOk(CCtrlButton*) if (IsDlgButtonChecked(m_hwnd, IDC_C) == BST_CHECKED) flags += 'c';
if (IsDlgButtonChecked(m_hwnd, IDC_M) == BST_CHECKED) flags += 'm';
- GetWindowText(GetDlgItem(m_hwnd, IDC_MASK), szMask, SIZEOF(szMask));
- GetWindowText(GetDlgItem(m_hwnd, IDC_NETWORK), szNetwork, SIZEOF(szNetwork));
+ GetDlgItemText(m_hwnd, IDC_MASK, szMask, SIZEOF(szMask));
+ GetDlgItemText(m_hwnd, IDC_NETWORK, szNetwork, SIZEOF(szNetwork));
CMString Mask = GetWord(szMask, 0);
if (Mask.GetLength() != 0) {
diff --git a/protocols/JabberG/src/jabber_console.cpp b/protocols/JabberG/src/jabber_console.cpp index 8223d8d0cd..08336c73fe 100644 --- a/protocols/JabberG/src/jabber_console.cpp +++ b/protocols/JabberG/src/jabber_console.cpp @@ -506,7 +506,7 @@ INT_PTR CJabberDlgConsole::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) else {
int length = GetWindowTextLength(GetDlgItem(m_hwnd, IDC_CONSOLEIN)) + 1;
TCHAR *textToSend = (TCHAR *)mir_alloc(length * sizeof(TCHAR));
- GetWindowText(GetDlgItem(m_hwnd, IDC_CONSOLEIN), textToSend, length);
+ GetDlgItemText(m_hwnd, IDC_CONSOLEIN, textToSend, length);
int bytesProcessed = 0;
XmlNode xmlTmp(textToSend, &bytesProcessed, NULL);
@@ -562,7 +562,7 @@ INT_PTR CJabberDlgConsole::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) }
else if (HIWORD(wParam) == CBN_EDITCHANGE) {
mir_cslock lck(m_proto->m_filterInfo.csPatternLock);
- GetWindowText(GetDlgItem(m_hwnd, IDC_CB_FILTER), m_proto->m_filterInfo.pattern, SIZEOF(m_proto->m_filterInfo.pattern));
+ GetDlgItemText(m_hwnd, IDC_CB_FILTER, m_proto->m_filterInfo.pattern, SIZEOF(m_proto->m_filterInfo.pattern));
}
break;
diff --git a/protocols/JabberG/src/jabber_groupchat.cpp b/protocols/JabberG/src/jabber_groupchat.cpp index 99a24ee972..4ea03e05a0 100644 --- a/protocols/JabberG/src/jabber_groupchat.cpp +++ b/protocols/JabberG/src/jabber_groupchat.cpp @@ -600,8 +600,8 @@ INT_PTR CJabberDlgGcJoin::DlgProc(UINT msg, WPARAM wParam, LPARAM lParam) SendDlgItemMessage(m_hwnd, IDC_ROOM, CB_RESETCONTENT, 0, 0);
int len = GetWindowTextLength(GetDlgItem(m_hwnd, IDC_SERVER)) + 1;
- TCHAR *server = (TCHAR *)_alloca(len * sizeof(TCHAR));
- GetWindowText(GetDlgItem(m_hwnd, IDC_SERVER), server, len);
+ TCHAR *server = (TCHAR*)_alloca(len * sizeof(TCHAR));
+ GetDlgItemText(m_hwnd, IDC_SERVER, server, len);
if (*server) {
sttRoomListAppend(GetDlgItem(m_hwnd, IDC_ROOM), RoomInfo::ROOM_WAIT, TranslateT("Loading..."), TranslateT("Please wait for room list to download."), _T(""));
diff --git a/protocols/JabberG/src/jabber_privacy.cpp b/protocols/JabberG/src/jabber_privacy.cpp index 3042db1b4e..5724a4c0a7 100644 --- a/protocols/JabberG/src/jabber_privacy.cpp +++ b/protocols/JabberG/src/jabber_privacy.cpp @@ -1632,7 +1632,7 @@ void CJabberDlgPrivacyLists::btnAddJid_OnClick(CCtrlButton *) {
int len = GetWindowTextLength(GetDlgItem(m_hwnd, IDC_NEWJID))+1;
TCHAR *buf = (TCHAR *)_alloca(sizeof(TCHAR) * len);
- GetWindowText(GetDlgItem(m_hwnd, IDC_NEWJID), buf, len);
+ GetDlgItemText(m_hwnd, IDC_NEWJID, buf, len);
SetWindowText(GetDlgItem(m_hwnd, IDC_NEWJID), _T(""));
CListAddContact(GetDlgItem(m_hwnd, IDC_CLIST), buf);
}
diff --git a/protocols/Sametime/src/session_announce_win.cpp b/protocols/Sametime/src/session_announce_win.cpp index 77c82c58ad..7e36cc65e8 100644 --- a/protocols/Sametime/src/session_announce_win.cpp +++ b/protocols/Sametime/src/session_announce_win.cpp @@ -113,7 +113,7 @@ INT_PTR CALLBACK SessionAnnounceDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wPara }
if (send_count > 0) {
- GetWindowText(GetDlgItem(hwndDlg, IDC_ED_ANMSG), safArg->msg, MAX_MESSAGE_SIZE);
+ GetDlgItemText(hwndDlg, IDC_ED_ANMSG, safArg->msg, MAX_MESSAGE_SIZE);
safArg->proto = proto;
SendAnnouncementFunc sendAnnouncementFunc = arg->sendAnnouncementFunc;
sendAnnouncementFunc(safArg);
diff --git a/protocols/SkypeClassic/src/skypeopt.cpp b/protocols/SkypeClassic/src/skypeopt.cpp index 8c598c3efe..74957b8907 100644 --- a/protocols/SkypeClassic/src/skypeopt.cpp +++ b/protocols/SkypeClassic/src/skypeopt.cpp @@ -935,8 +935,8 @@ void DoAutoDetect(HWND dlg) {
if (acc = ezxml_get(f1, "Lib", 0, "Account", 0, "Default", -1))
{
- if (GetWindowTextA(GetDlgItem(dlg,IDC_USERNAME),tmpUser,sizeof(tmpUser)))
- SetWindowTextA(GetDlgItem(dlg,IDC_USERNAME),acc->txt);
+ if (GetDlgItemTextA(dlg, IDC_USERNAME, tmpUser, sizeof(tmpUser)))
+ SetWindowTextA(GetDlgItem(dlg, IDC_USERNAME), acc->txt);
/* Can't find this stuff in current Skype verions??
sprintf (fileName, "%s\\%s\\config.xml", basePath, acc->txt);
if ((acc = ezxml_get(f1, "UI", 0, "Messages", 0, "OpenWindowInCompactMode", -1)) && *acc->txt!='0')
diff --git a/src/modules/langpack/lpopts.cpp b/src/modules/langpack/lpopts.cpp index cb1a8d5a0b..07cb4784b0 100644 --- a/src/modules/langpack/lpopts.cpp +++ b/src/modules/langpack/lpopts.cpp @@ -125,7 +125,7 @@ INT_PTR CALLBACK DlgLangpackOpt(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP {
char buf[512];
mir_strcpy(buf, "mailto:");
- if (GetWindowTextA(GetDlgItem(hwndDlg, LOWORD(wParam)), &buf[7], SIZEOF(buf)-7))
+ if (GetDlgItemTextA(hwndDlg, LOWORD(wParam), &buf[7], SIZEOF(buf) - 7))
CallService(MS_UTILS_OPENURL, 0, (LPARAM)buf);
}
break;
diff --git a/src/modules/netlib/netliblog.cpp b/src/modules/netlib/netliblog.cpp index 43f14d4ac9..844db8b3ad 100644 --- a/src/modules/netlib/netliblog.cpp +++ b/src/modules/netlib/netliblog.cpp @@ -209,11 +209,11 @@ static INT_PTR CALLBACK LogOptionsDlgProc(HWND hwndDlg, UINT message, WPARAM wPa db_set_ts(NULL, "Netlib", "RunAtStart", str);
db_set_b(NULL, "Netlib", "ShowLogOptsAtStart", (BYTE)IsDlgButtonChecked(hwndDlg, IDC_SHOWTHISDLGATSTART));
- GetWindowText(GetDlgItem(hwndDlg, IDC_FILENAME), str, SIZEOF(str));
+ GetDlgItemText(hwndDlg, IDC_FILENAME, str, SIZEOF(str));
logOptions.tszUserFile = rtrimt(str);
db_set_ts(NULL, "Netlib", "File", str);
- GetWindowText(GetDlgItem(hwndDlg, IDC_PATH), str, SIZEOF(str));
+ GetDlgItemText(hwndDlg, IDC_PATH, str, SIZEOF(str));
logOptions.tszFile = rtrimt(str);
db_set_b(NULL, "Netlib", "DumpRecv", logOptions.dumpRecv = IsDlgButtonChecked(hwndDlg, IDC_DUMPRECV));
|