diff options
author | George Hazan <ghazan@miranda.im> | 2020-02-05 21:39:06 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2020-02-05 21:39:06 +0300 |
commit | f72638c4700b2f790d3d71d19360763a330a907a (patch) | |
tree | 677ae76f4c56cee61378237771706f07c8ff7499 /plugins/TabSRMM | |
parent | c9286dd2fd24c5baf5cfc905ac73aa797bb4c28e (diff) |
fixes #2200 ([0.95.11 x64] IRC-style colors (ctrl-k) regression)
Diffstat (limited to 'plugins/TabSRMM')
-rw-r--r-- | plugins/TabSRMM/src/msgdialog.cpp | 44 |
1 files changed, 19 insertions, 25 deletions
diff --git a/plugins/TabSRMM/src/msgdialog.cpp b/plugins/TabSRMM/src/msgdialog.cpp index a44bb25bb5..af564e8b6f 100644 --- a/plugins/TabSRMM/src/msgdialog.cpp +++ b/plugins/TabSRMM/src/msgdialog.cpp @@ -1916,20 +1916,9 @@ LRESULT CMsgDialog::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) if (isCtrl && !isAlt) {
switch (wParam) {
- case 0x02: // bold
- if (m_SendFormat)
- m_btnBold.Click();
- return 0;
- case 0x09:
- if (m_SendFormat)
- m_btnItalic.Click();
- return 0;
- case 21:
- if (m_SendFormat)
- m_btnUnderline.Click();
- return 0;
case 0x0b:
- m_message.SetText(L"");
+ if (!isChat())
+ m_message.SetText(L"");
return 0;
}
}
@@ -1977,19 +1966,24 @@ LRESULT CMsgDialog::WndProc_Message(UINT msg, WPARAM wParam, LPARAM lParam) if (wParam == VK_CAPITAL || wParam == VK_NUMLOCK)
m_message.OnChange(&m_message);
- // tab-autocomplete
- if (isChat() && wParam == VK_TAB && !isCtrl && !isShift) {
- m_message.SendMsg(WM_SETREDRAW, FALSE, 0);
- bool fCompleted = TabAutoComplete();
- m_message.SendMsg(WM_SETREDRAW, TRUE, 0);
- RedrawWindow(m_message.GetHwnd(), nullptr, nullptr, RDW_INVALIDATE);
- if (!fCompleted && !PluginConfig.m_bAllowTab) {
- if ((GetSendButtonState(GetHwnd()) != PBS_DISABLED))
- SetFocus(m_btnOk.GetHwnd());
- else
- SetFocus(m_pLog->GetHwnd());
- return 0;
+ if (isChat()) {
+ // tab-autocomplete
+ if (wParam == VK_TAB && !isCtrl && !isShift) {
+ m_message.SendMsg(WM_SETREDRAW, FALSE, 0);
+ bool fCompleted = TabAutoComplete();
+ m_message.SendMsg(WM_SETREDRAW, TRUE, 0);
+ RedrawWindow(m_message.GetHwnd(), nullptr, nullptr, RDW_INVALIDATE);
+ if (!fCompleted && !PluginConfig.m_bAllowTab) {
+ if ((GetSendButtonState(GetHwnd()) != PBS_DISABLED))
+ SetFocus(m_btnOk.GetHwnd());
+ else
+ SetFocus(m_pLog->GetHwnd());
+ return 0;
+ }
}
+
+ if (ProcessHotkeys(wParam, isShift, isCtrl, isAlt))
+ return 0;
}
if (wParam != VK_RIGHT && wParam != VK_LEFT) {
|