don't call EnsureVisible(tree->GetRootItem()) for a tree with hidden root, this crashes under MSW
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@40855 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -578,7 +578,9 @@ void WidgetsFrame::InitBook()
|
||||
|
||||
// but ensure that the top of the tree is shown nevertheless
|
||||
wxTreeCtrl * const tree = m_book->GetTreeCtrl();
|
||||
tree->EnsureVisible(tree->GetRootItem());
|
||||
|
||||
wxTreeItemIdValue cookie;
|
||||
tree->EnsureVisible(tree->GetFirstChild(tree->GetRootItem(), cookie));
|
||||
#endif // USE_TREEBOOK
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user