diff options
author | George Hazan <ghazan@miranda.im> | 2017-04-12 12:46:58 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2017-04-12 13:12:37 +0300 |
commit | b17edd86654fa52cac4d05d02b085e0941552de7 (patch) | |
tree | 3360234fc60202b71265ecc746076ff425d8956c /src/core | |
parent | 06f4854682bec85dda4b3238b4c4da69c6eca897 (diff) |
StdMsg: fix for pressing Esc in a log window
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/stdmsg/src/msgdialog.cpp | 15 | ||||
-rw-r--r-- | src/core/stdmsg/src/msgs.h | 1 |
2 files changed, 15 insertions, 1 deletions
diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index f64f4e826b..4a2d6db9ce 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -635,6 +635,19 @@ int CSrmmWindow::Resizer(UTILRESIZECONTROL *urc) /////////////////////////////////////////////////////////////////////////////////////////
+LRESULT CSrmmWindow::WndProc_Log(UINT msg, WPARAM wParam, LPARAM lParam)
+{
+ if (msg == WM_KEYDOWN) {
+ bool isShift = (GetKeyState(VK_SHIFT) & 0x8000) != 0;
+ bool isCtrl = (GetKeyState(VK_CONTROL) & 0x8000) != 0;
+ bool isAlt = (GetKeyState(VK_MENU) & 0x8000) != 0;
+ if (ProcessHotkeys(wParam, isShift, isCtrl, isAlt))
+ return FALSE;
+ }
+
+ return CSuper::WndProc_Log(msg, wParam, lParam);
+}
+
LRESULT CSrmmWindow::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam)
{
bool isShift, isCtrl, isAlt;
@@ -686,7 +699,7 @@ LRESULT CSrmmWindow::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) m_message.SendMsg(WM_PASTE, 0, 0);
return 0;
}
-
+
if (wParam == VK_UP && isCtrl && g_dat.bCtrlSupport && !g_dat.bAutoClose) {
if (m_cmdList.getCount()) {
if (m_cmdListInd < 0) {
diff --git a/src/core/stdmsg/src/msgs.h b/src/core/stdmsg/src/msgs.h index 48a028245a..f1f84714fa 100644 --- a/src/core/stdmsg/src/msgs.h +++ b/src/core/stdmsg/src/msgs.h @@ -53,6 +53,7 @@ class CSrmmWindow : public CSrmmBaseDialog static LRESULT CALLBACK TabSubclassProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam);
+ virtual LRESULT WndProc_Log(UINT msg, WPARAM wParam, LPARAM lParam) override;
virtual LRESULT WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) override;
CCtrlBase m_avatar;
|