diff options
author | George Hazan <ghazan@miranda.im> | 2018-04-15 15:26:58 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-04-15 15:26:58 +0300 |
commit | 312527636ef61001c77fc452fa5a0d31a8c6ee69 (patch) | |
tree | df6213badb43eec495c3f02b87e89247ca093eda /src | |
parent | 70c6c50d70b2e27929907c0f18e981a03e68f270 (diff) |
suddenly chkCtrlSupport lost a link with g_dat.bCtrlSupport in StdMsg's options
Diffstat (limited to 'src')
-rw-r--r-- | src/core/stdmsg/src/msgdialog.cpp | 47 | ||||
-rw-r--r-- | src/core/stdmsg/src/msgoptions.cpp | 1 |
2 files changed, 26 insertions, 22 deletions
diff --git a/src/core/stdmsg/src/msgdialog.cpp b/src/core/stdmsg/src/msgdialog.cpp index c7547331b9..e179f4a978 100644 --- a/src/core/stdmsg/src/msgdialog.cpp +++ b/src/core/stdmsg/src/msgdialog.cpp @@ -703,33 +703,36 @@ LRESULT CSrmmWindow::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) return 0;
}
- if (wParam == VK_UP && isCtrl && g_dat.bCtrlSupport && !g_dat.bAutoClose) {
- if (m_cmdList.getCount()) {
- if (m_cmdListInd < 0) {
- m_cmdListInd = m_cmdList.getCount() - 1;
- SetEditorText(m_message.GetHwnd(), m_cmdList[m_cmdListInd]);
- }
- else if (m_cmdListInd > 0) {
- SetEditorText(m_message.GetHwnd(), m_cmdList[--m_cmdListInd]);
+ if (isCtrl && g_dat.bCtrlSupport && !g_dat.bAutoClose) {
+ if (wParam == VK_UP) {
+ if (m_cmdList.getCount()) {
+ if (m_cmdListInd < 0) {
+ m_cmdListInd = m_cmdList.getCount() - 1;
+ SetEditorText(m_message.GetHwnd(), m_cmdList[m_cmdListInd]);
+ }
+ else if (m_cmdListInd > 0) {
+ SetEditorText(m_message.GetHwnd(), m_cmdList[--m_cmdListInd]);
+ }
}
+ m_btnOk.Enable(GetWindowTextLength(m_message.GetHwnd()) != 0);
+ UpdateReadChars();
+ return 0;
}
- m_btnOk.Enable(GetWindowTextLength(m_message.GetHwnd()) != 0);
- UpdateReadChars();
- return 0;
- }
- if (wParam == VK_DOWN && isCtrl && g_dat.bCtrlSupport && !g_dat.bAutoClose) {
- if (m_cmdList.getCount() && m_cmdListInd >= 0) {
- if (m_cmdListInd < m_cmdList.getCount() - 1)
- SetEditorText(m_message.GetHwnd(), m_cmdList[++m_cmdListInd]);
- else {
- m_cmdListInd = -1;
- SetEditorText(m_message.GetHwnd(), m_cmdList[m_cmdList.getCount() - 1]);
+ if (wParam == VK_DOWN) {
+ if (m_cmdList.getCount() && m_cmdListInd >= 0) {
+ if (m_cmdListInd < m_cmdList.getCount() - 1)
+ SetEditorText(m_message.GetHwnd(), m_cmdList[++m_cmdListInd]);
+ else {
+ m_cmdListInd = -1;
+ SetEditorText(m_message.GetHwnd(), m_cmdList[m_cmdList.getCount() - 1]);
+ }
}
- }
- m_btnOk.Enable(GetWindowTextLength(m_message.GetHwnd()) != 0);
- UpdateReadChars();
+ m_btnOk.Enable(GetWindowTextLength(m_message.GetHwnd()) != 0);
+ UpdateReadChars();
+ return 0;
+ }
}
if (ProcessHotkeys(wParam, isShift, isCtrl, isAlt))
diff --git a/src/core/stdmsg/src/msgoptions.cpp b/src/core/stdmsg/src/msgoptions.cpp index da0ddf36f6..0c8bbf0e74 100644 --- a/src/core/stdmsg/src/msgoptions.cpp +++ b/src/core/stdmsg/src/msgoptions.cpp @@ -238,6 +238,7 @@ public: CreateLink(chkCharCount, g_dat.bShowReadChar);
CreateLink(chkStatusWin, g_dat.bUseStatusWinIcon);
CreateLink(chkShowButtons, g_dat.bShowButtons);
+ CreateLink(chkCtrlSupport, g_dat.bCtrlSupport);
CreateLink(chkSendOnEnter, g_dat.bSendOnEnter);
CreateLink(chkSendOnDblEnter, g_dat.bSendOnDblEnter);
CreateLink(chkSavePerContact, g_dat.bSavePerContact);
|