@@ -466,18 +466,18 @@ void JsonViewDlg::AppendNodeCount(HTREEITEM node, unsigned elementCount, bool bA
466
466
m_pTreeView->UpdateNodeText (node, txt);
467
467
}
468
468
469
- void JsonViewDlg::UpdateNodePath (HTREEITEM htiNode)
469
+ void JsonViewDlg::UpdateNodePath (HTREEITEM htiNode) const
470
470
{
471
471
std::wstring nodePath = m_pTreeView->GetNodePath (htiNode);
472
472
CUtility::SetEditCtrlText (::GetDlgItem (_hSelf, IDC_EDT_NODEPATH), nodePath);
473
473
}
474
474
475
- void JsonViewDlg::GoToLine (size_t nLineToGo)
475
+ void JsonViewDlg::GoToLine (size_t nLineToGo) const
476
476
{
477
477
m_pEditor->GoToLine (nLineToGo);
478
478
}
479
479
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
481
481
{
482
482
m_pEditor->GoToPosition (nLineToGo, nPos, nLen);
483
483
}
@@ -673,7 +673,7 @@ void JsonViewDlg::AdjustDocPanelSize(int nWidth, int nHeight)
673
673
const auto moveWindowIDs = {IDC_BTN_SEARCH};
674
674
675
675
// elements which requires both resizing and move
676
- const auto resizeAndmoveWindowIDs = {IDC_EDT_NODEPATH};
676
+ const auto resizeAndMoveWindowIDs = {IDC_EDT_NODEPATH};
677
677
678
678
const UINT flags = SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOACTIVATE | SWP_NOCOPYBITS | SWP_SHOWWINDOW;
679
679
@@ -700,7 +700,7 @@ void JsonViewDlg::AdjustDocPanelSize(int nWidth, int nHeight)
700
700
::SetWindowPos (hWnd, NULL , rc.left + addWidth, rc.top, 0 , 0 , SWP_NOSIZE | flags);
701
701
}
702
702
703
- for (int id : resizeAndmoveWindowIDs )
703
+ for (int id : resizeAndMoveWindowIDs )
704
704
{
705
705
HWND hWnd = GetDlgItem (_hSelf, id);
706
706
@@ -895,7 +895,7 @@ void JsonViewDlg::EnableControls(const std::vector<DWORD>& ids, bool enable)
895
895
EnableWindow (GetDlgItem (getHSelf (), id), enable ? TRUE : FALSE );
896
896
}
897
897
898
- void JsonViewDlg::HandleTreeEvents (LPARAM lParam)
898
+ void JsonViewDlg::HandleTreeEvents (LPARAM lParam) const
899
899
{
900
900
LPNMHDR lpnmh = reinterpret_cast <LPNMHDR>(lParam);
901
901
if (!lpnmh || lpnmh->idFrom != IDC_TREE)
@@ -1029,7 +1029,7 @@ INT_PTR JsonViewDlg::run_dlgProc(UINT message, WPARAM wParam, LPARAM lParam)
1029
1029
// Save ourselves in GWLP_USERDATA.
1030
1030
::SetWindowLongPtr (getHSelf(), GWLP_USERDATA, reinterpret_cast<LONG_PTR>(this ));
1031
1031
1032
- m_pTreeView->OnInit (getHSelf ());
1032
+ m_pTreeView->OnInit (getHSelf (), IDC_TREE );
1033
1033
1034
1034
PrepareButtons ();
1035
1035
0 commit comments