@@ -466,18 +466,18 @@ void JsonViewDlg::AppendNodeCount(HTREEITEM node, unsigned elementCount, bool bA
466466 m_pTreeView->UpdateNodeText (node, txt);
467467}
468468
469- void JsonViewDlg::UpdateNodePath (HTREEITEM htiNode)
469+ void JsonViewDlg::UpdateNodePath (HTREEITEM htiNode) const
470470{
471471 std::wstring nodePath = m_pTreeView->GetNodePath (htiNode);
472472 CUtility::SetEditCtrlText (::GetDlgItem (_hSelf, IDC_EDT_NODEPATH), nodePath);
473473}
474474
475- void JsonViewDlg::GoToLine (size_t nLineToGo)
475+ void JsonViewDlg::GoToLine (size_t nLineToGo) const
476476{
477477 m_pEditor->GoToLine (nLineToGo);
478478}
479479
480- void JsonViewDlg::GoToPosition (size_t nLineToGo, size_t nPos, size_t nLen)
480+ void JsonViewDlg::GoToPosition (size_t nLineToGo, size_t nPos, size_t nLen) const
481481{
482482 m_pEditor->GoToPosition (nLineToGo, nPos, nLen);
483483}
@@ -673,7 +673,7 @@ void JsonViewDlg::AdjustDocPanelSize(int nWidth, int nHeight)
673673 const auto moveWindowIDs = {IDC_BTN_SEARCH};
674674
675675 // elements which requires both resizing and move
676- const auto resizeAndmoveWindowIDs = {IDC_EDT_NODEPATH};
676+ const auto resizeAndMoveWindowIDs = {IDC_EDT_NODEPATH};
677677
678678 const UINT flags = SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOACTIVATE | SWP_NOCOPYBITS | SWP_SHOWWINDOW;
679679
@@ -700,7 +700,7 @@ void JsonViewDlg::AdjustDocPanelSize(int nWidth, int nHeight)
700700 ::SetWindowPos (hWnd, NULL , rc.left + addWidth, rc.top, 0 , 0 , SWP_NOSIZE | flags);
701701 }
702702
703- for (int id : resizeAndmoveWindowIDs )
703+ for (int id : resizeAndMoveWindowIDs )
704704 {
705705 HWND hWnd = GetDlgItem (_hSelf, id);
706706
@@ -895,7 +895,7 @@ void JsonViewDlg::EnableControls(const std::vector<DWORD>& ids, bool enable)
895895 EnableWindow (GetDlgItem (getHSelf (), id), enable ? TRUE : FALSE );
896896}
897897
898- void JsonViewDlg::HandleTreeEvents (LPARAM lParam)
898+ void JsonViewDlg::HandleTreeEvents (LPARAM lParam) const
899899{
900900 LPNMHDR lpnmh = reinterpret_cast <LPNMHDR>(lParam);
901901 if (!lpnmh || lpnmh->idFrom != IDC_TREE)
@@ -1029,7 +1029,7 @@ INT_PTR JsonViewDlg::run_dlgProc(UINT message, WPARAM wParam, LPARAM lParam)
10291029 // Save ourselves in GWLP_USERDATA.
10301030 ::SetWindowLongPtr (getHSelf(), GWLP_USERDATA, reinterpret_cast<LONG_PTR>(this ));
10311031
1032- m_pTreeView->OnInit (getHSelf ());
1032+ m_pTreeView->OnInit (getHSelf (), IDC_TREE );
10331033
10341034 PrepareButtons ();
10351035
0 commit comments