diff options
author | George Hazan <ghazan@miranda.im> | 2016-12-07 18:28:15 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2016-12-07 18:28:15 +0300 |
commit | 15f871ebb43e49f96e8f7e2ec95359bc0a05545f (patch) | |
tree | 81290687285eb633f5eed29714a9bb9e171676b4 /plugins/Scriver/src/msgdialog.cpp | |
parent | ffd40987e231ae7f06193bafebd7fe045c2d60ae (diff) |
no need to calculate button width each time
Diffstat (limited to 'plugins/Scriver/src/msgdialog.cpp')
-rw-r--r-- | plugins/Scriver/src/msgdialog.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/plugins/Scriver/src/msgdialog.cpp b/plugins/Scriver/src/msgdialog.cpp index f6efee312a..cc2a85b382 100644 --- a/plugins/Scriver/src/msgdialog.cpp +++ b/plugins/Scriver/src/msgdialog.cpp @@ -765,8 +765,7 @@ INT_PTR CALLBACK DlgProcMessage(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lP if (!cbd->m_bIMButton)
continue;
- int width = (cbd->m_dwArrowCID) ? 34 : 22;
- HWND hwndButton = CreateWindowEx(0, L"MButtonClass", L"", WS_CHILD | WS_VISIBLE | WS_TABSTOP, 0, 0, width, 22, hwndDlg, (HMENU)cbd->m_dwButtonCID, g_hInst, NULL);
+ HWND hwndButton = CreateWindowEx(0, L"MButtonClass", L"", WS_CHILD | WS_VISIBLE | WS_TABSTOP, 0, 0, cbd->m_iButtonWidth, 22, hwndDlg, (HMENU)cbd->m_dwButtonCID, g_hInst, NULL);
SendMessage(hwndButton, BUTTONSETASFLATBTN, TRUE, 0);
if (cbd->m_pwszTooltip)
SendMessage(hwndButton, BUTTONADDTOOLTIP, LPARAM(cbd->m_pwszTooltip), BATF_UNICODE);
|