From 6a32de54e79c7f572f552922aed3273206298f92 Mon Sep 17 00:00:00 2001 From: Rozhuk Ivan Date: Sat, 13 Dec 2014 23:12:37 +0000 Subject: SendDlgItemMessage(..., ..., BM_GETCHECK,0,0) -> IsDlgButtonChecked(..., ...) git-svn-id: http://svn.miranda-ng.org/main/trunk@11385 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/YARelay/src/options.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'plugins/YARelay/src/options.cpp') diff --git a/plugins/YARelay/src/options.cpp b/plugins/YARelay/src/options.cpp index e7444393a6..ddb28dc58b 100644 --- a/plugins/YARelay/src/options.cpp +++ b/plugins/YARelay/src/options.cpp @@ -144,27 +144,27 @@ static INT_PTR CALLBACK OptionsFrameProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, case PSN_KILLACTIVE: // read all data from options frame - if (SendDlgItemMessage(hwndDlg, IDC_RADIO_ALL, BM_GETCHECK, 0, 0) == BST_CHECKED) + if (IsDlgButtonChecked(hwndDlg, IDC_RADIO_ALL) == BST_CHECKED) hForwardFrom = 0; else hForwardFrom = (MCONTACT)SendDlgItemMessage(hwndDlg, IDC_COMBO_FROM, CB_GETITEMDATA, SendDlgItemMessage(hwndDlg, IDC_COMBO_FROM, CB_GETCURSEL, 0, 0), 0); hForwardTo = (MCONTACT)SendDlgItemMessage(hwndDlg, IDC_COMBO_TO, CB_GETITEMDATA, SendDlgItemMessage(hwndDlg, IDC_COMBO_TO, CB_GETCURSEL, 0, 0), 0); iForwardOnStatus = 0; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK1, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_OFFLINE; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK2, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_ONLINE; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK3, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_AWAY; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK4, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_NA; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK5, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_OCCUPIED; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK6, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_DND; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK7, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_FREECHAT; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK8, BM_GETCHECK, 0, 0) == BST_CHECKED) iForwardOnStatus |= STATUS_INVISIBLE; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK1) == BST_CHECKED) iForwardOnStatus |= STATUS_OFFLINE; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK2) == BST_CHECKED) iForwardOnStatus |= STATUS_ONLINE; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK3) == BST_CHECKED) iForwardOnStatus |= STATUS_AWAY; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK4) == BST_CHECKED) iForwardOnStatus |= STATUS_NA; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK5) == BST_CHECKED) iForwardOnStatus |= STATUS_OCCUPIED; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK6) == BST_CHECKED) iForwardOnStatus |= STATUS_DND; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK7) == BST_CHECKED) iForwardOnStatus |= STATUS_FREECHAT; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK8) == BST_CHECKED) iForwardOnStatus |= STATUS_INVISIBLE; GetDlgItemText(hwndDlg, IDC_EDIT_TEMPLATE, tszForwardTemplate, SIZEOF(tszForwardTemplate)); - if (SendDlgItemMessage(hwndDlg, IDC_CHECK_SPLIT, BM_GETCHECK, 0, 0) == BST_CHECKED) iSplit = 1; else iSplit = 0; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK_SPLIT) == BST_CHECKED) iSplit = 1; else iSplit = 0; iSplitMaxSize = GetDlgItemInt(hwndDlg, IDC_EDIT_MAXSIZE, NULL, FALSE); iSendParts = GetDlgItemInt(hwndDlg, IDC_EDIT_SENDPARTS, NULL, FALSE); - if (SendDlgItemMessage(hwndDlg, IDC_CHECK_MARKREAD, BM_GETCHECK, 0, 0) == BST_CHECKED) iMarkRead = 1; else iMarkRead = 0; - if (SendDlgItemMessage(hwndDlg, IDC_CHECK_SAVEHISTORY, BM_GETCHECK, 0, 0) == BST_CHECKED) iSendAndHistory = 1; else iSendAndHistory = 0; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK_MARKREAD) == BST_CHECKED) iMarkRead = 1; else iMarkRead = 0; + if (IsDlgButtonChecked(hwndDlg, IDC_CHECK_SAVEHISTORY) == BST_CHECKED) iSendAndHistory = 1; else iSendAndHistory = 0; if (iSplitMaxSize <= 0) iSplitMaxSize = 1; -- cgit v1.2.3