diff options
author | George Hazan <george.hazan@gmail.com> | 2015-06-21 12:01:49 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2015-06-21 12:01:49 +0000 |
commit | e865872b4ef16b6e40cfe868843f1070fa3a239b (patch) | |
tree | 0710f76e005c25ce151c46015c0853af6101d2cc /plugins/Variables/src/help.cpp | |
parent | 87cf54594168e5579bbb852bcb4aaae3fefa3b89 (diff) |
- resizer moved to mir_core, because it uses hard-coded windows structures;
- MS_UTILS_RESIZEDIALOG replaced with a short call of Utils_ResizeDialog;
- code cleaning
git-svn-id: http://svn.miranda-ng.org/main/trunk@14295 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Variables/src/help.cpp')
-rw-r--r-- | plugins/Variables/src/help.cpp | 62 |
1 files changed, 8 insertions, 54 deletions
diff --git a/plugins/Variables/src/help.cpp b/plugins/Variables/src/help.cpp index ffdaa361e0..b17d9ddbd9 100644 --- a/plugins/Variables/src/help.cpp +++ b/plugins/Variables/src/help.cpp @@ -73,14 +73,7 @@ static INT_PTR CALLBACK extratextDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPA case WM_SIZE: if (!IsIconic( hwndDlg )) { - UTILRESIZEDIALOG urd = { 0 }; - urd.cbSize = sizeof(urd); - urd.hInstance = hInst; - urd.hwndDlg = hwndDlg; - urd.lpTemplate = MAKEINTRESOURCEA(IDD_EXTRATEXT_DIALOG); - urd.pfnResizer = defaultHelpDialogResize; - CallService(MS_UTILS_RESIZEDIALOG, 0, (LPARAM)&urd); - + Utils_ResizeDialog(hwndDlg, hInst, MAKEINTRESOURCEA(IDD_EXTRATEXT_DIALOG), defaultHelpDialogResize); SendMessage(hwndDlg, WM_MOVE, 0, 0); } break; @@ -170,15 +163,7 @@ static INT_PTR CALLBACK clistDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARAM case WM_SIZE: if (!IsIconic(hwndDlg)) { - UTILRESIZEDIALOG urd = { sizeof(urd) }; - urd.hInstance = hInst; - urd.hwndDlg = hwndDlg; - urd.lParam = 0; - /* ! uses ANSI version ! */ - urd.lpTemplate = MAKEINTRESOURCEA(IDD_CLIST_DIALOG); - urd.pfnResizer = clistDialogResize; - CallService(MS_UTILS_RESIZEDIALOG, 0, (LPARAM)&urd); - + Utils_ResizeDialog(hwndDlg, hInst, MAKEINTRESOURCEA(IDD_CLIST_DIALOG), clistDialogResize); SendMessage(hwndDlg, WM_MOVE, 0, 0); } break; @@ -512,14 +497,7 @@ static INT_PTR CALLBACK tokenHelpDlgProc(HWND hwndDlg, UINT msg, WPARAM wParam, case WM_SIZE: if (!IsIconic(hwndDlg)) { - UTILRESIZEDIALOG urd = { 0 }; - urd.cbSize = sizeof(urd); - urd.hInstance = hInst; - urd.hwndDlg = hwndDlg; - urd.lpTemplate = MAKEINTRESOURCEA(IDD_TOKENS_DIALOG); - urd.pfnResizer = defaultHelpDialogResize; - CallService(MS_UTILS_RESIZEDIALOG, 0, (LPARAM)&urd); - + Utils_ResizeDialog(hwndDlg, hInst, MAKEINTRESOURCEA(IDD_TOKENS_DIALOG), defaultHelpDialogResize); SendMessage(hwndDlg, WM_MOVE, 0, 0); } break; @@ -684,16 +662,9 @@ static INT_PTR CALLBACK inputDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARAM break; case WM_SIZE: - if (!IsIconic(hwndDlg)) { - UTILRESIZEDIALOG urd = { 0 }; - urd.cbSize = sizeof(urd); - urd.hInstance = hInst; - urd.hwndDlg = hwndDlg; - urd.lParam = (LPARAM)dat; - urd.lpTemplate = MAKEINTRESOURCEA(IDD_INPUT_DIALOG); - urd.pfnResizer = inputDialogResize; - CallService(MS_UTILS_RESIZEDIALOG, 0, (LPARAM)&urd); - } + if (!IsIconic(hwndDlg)) + Utils_ResizeDialog(hwndDlg, hInst, MAKEINTRESOURCEA(IDD_INPUT_DIALOG), inputDialogResize, (LPARAM)dat); + SendMessage(hwndDlg, WM_MOVE, 0, 0); break; @@ -774,15 +745,7 @@ static INT_PTR CALLBACK helpInfoDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPAR case WM_SIZE: if (!IsIconic( hwndDlg )) { - UTILRESIZEDIALOG urd = { 0 }; - urd.cbSize = sizeof(urd); - urd.hInstance = hInst; - urd.hwndDlg = hwndDlg; - urd.lParam = 0; - urd.lpTemplate = MAKEINTRESOURCEA(IDD_HELPINFO_DIALOG); - urd.pfnResizer = defaultHelpDialogResize; - CallService(MS_UTILS_RESIZEDIALOG, 0, (LPARAM)&urd); - + Utils_ResizeDialog(hwndDlg, hInst, MAKEINTRESOURCEA(IDD_HELPINFO_DIALOG), defaultHelpDialogResize); SendMessage(hwndDlg, WM_MOVE, 0, 0); } break; @@ -1082,16 +1045,7 @@ static INT_PTR CALLBACK helpDlgProc(HWND hwndDlg,UINT msg,WPARAM wParam,LPARAM l case WM_SIZE: if (!IsIconic(hwndDlg)) { - UTILRESIZEDIALOG urd = { 0 }; - urd.cbSize = sizeof(urd); - urd.hInstance = hInst; - urd.hwndDlg = hwndDlg; - urd.lParam = 0; - // ! uses ANSI version ! - urd.lpTemplate = MAKEINTRESOURCEA(IDD_HELP_DIALOG); - urd.pfnResizer = helpDialogResize; - CallService(MS_UTILS_RESIZEDIALOG, 0, (LPARAM)&urd); - + Utils_ResizeDialog(hwndDlg, hInst, MAKEINTRESOURCEA(IDD_HELP_DIALOG), helpDialogResize); SendMessage(hwndDlg, WM_MOVE, 0, 0); RECT rcTabs, rcParent; |