diff options
author | George Hazan <ghazan@miranda.im> | 2019-08-09 14:10:20 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2019-08-09 14:10:20 +0300 |
commit | edba1adf6418cc8d096acb56db05871762b0ff7d (patch) | |
tree | acc13f82771730b8cbe8659e088707a1b13ed2b0 /src/mir_core | |
parent | 8d9e22cfcb01180289388f06142ffcab7f93d7d4 (diff) |
fixes #2023 (Cannot edit "Open new chat rooms in the default container" setting when using a screen reader on Windows)
Diffstat (limited to 'src/mir_core')
-rw-r--r-- | src/mir_core/src/CCtrlTreeView.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/src/mir_core/src/CCtrlTreeView.cpp b/src/mir_core/src/CCtrlTreeView.cpp index 8463f4d16e..34eb171da7 100644 --- a/src/mir_core/src/CCtrlTreeView.cpp +++ b/src/mir_core/src/CCtrlTreeView.cpp @@ -33,8 +33,8 @@ int ImageList_AddIcon_IconLibLoaded(HIMAGELIST hIml, int iconId) ///////////////////////////////////////////////////////////////////////////////////////// // CCtrlTreeView -CCtrlTreeView::CCtrlTreeView(CDlgBase *dlg, int ctrlId) - : CCtrlBase(dlg, ctrlId), +CCtrlTreeView::CCtrlTreeView(CDlgBase *dlg, int ctrlId) : + CCtrlBase(dlg, ctrlId), m_dwFlags(0), m_hDragItem(nullptr) {} @@ -58,8 +58,7 @@ void CCtrlTreeView::OnInit() { CSuper::OnInit(); - if (m_bDndEnabled) - Subclass(); + Subclass(); if (m_bCheckBox) { HIMAGELIST himlCheckBoxes = ::ImageList_Create(16, 16, ILC_COLOR32 | ILC_MASK, 2, 2); @@ -115,6 +114,13 @@ LRESULT CCtrlTreeView::CustomWndProc(UINT msg, WPARAM wParam, LPARAM lParam) TVHITTESTINFO hti; switch (msg) { + case WM_KEYDOWN: + if (wParam == VK_SPACE) { + if ((GetItemState(this->GetSelection(), TVIS_STATEIMAGEMASK) >> 12) == 0) + return TRUE; + } + break; + case WM_MOUSEMOVE: if (m_bDragging) { hti.pt.x = (short)LOWORD(lParam); |