summaryrefslogtreecommitdiff
path: root/plugins/Quotes/src/WinCtrlHelper.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/Quotes/src/WinCtrlHelper.cpp')
-rw-r--r--plugins/Quotes/src/WinCtrlHelper.cpp25
1 files changed, 10 insertions, 15 deletions
diff --git a/plugins/Quotes/src/WinCtrlHelper.cpp b/plugins/Quotes/src/WinCtrlHelper.cpp
index 3edd248631..9ca18a6811 100644
--- a/plugins/Quotes/src/WinCtrlHelper.cpp
+++ b/plugins/Quotes/src/WinCtrlHelper.cpp
@@ -1,14 +1,11 @@
#include "stdafx.h"
-namespace
+static INT_PTR CALLBACK VariableListDlgProc(HWND hWnd, UINT msg, WPARAM wp, LPARAM lp)
{
- INT_PTR CALLBACK VariableListDlgProc(HWND hWnd, UINT msg, WPARAM wp, LPARAM lp)
- {
- switch (msg)
+ switch (msg) {
+ case WM_INITDIALOG:
+ TranslateDialogDefault(hWnd);
{
- case WM_INITDIALOG:
- {
- TranslateDialogDefault(hWnd);
const IQuotesProvider* pProvider = reinterpret_cast<const IQuotesProvider*>(lp);
CQuotesProviderVisitorFormatSpecificator visitor;
pProvider->Accept(visitor);
@@ -23,16 +20,14 @@ namespace
::SetDlgItemText(hWnd, IDC_EDIT_VARIABLE, o.str().c_str());
}
break;
- case WM_COMMAND:
- if (BN_CLICKED == HIWORD(wp) && (IDOK == LOWORD(wp) || IDCANCEL == LOWORD(wp)))
- {
- ::EndDialog(hWnd, IDOK);
- }
- break;
- }
- return FALSE;
+ case WM_COMMAND:
+ if (BN_CLICKED == HIWORD(wp) && (IDOK == LOWORD(wp) || IDCANCEL == LOWORD(wp)))
+ ::EndDialog(hWnd, IDOK);
+ break;
}
+
+ return FALSE;
}
void show_variable_list(HWND hwndParent, const IQuotesProvider* pProvider)