don't invalidate the tree size when pages are added/removed, we don't want the tree size to jump on its own ad the programmer should call FitTree() explicitely if this is desired
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@38980 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
6bd02a4367
commit
26e95a246b
@ -203,8 +203,6 @@ bool wxTreebook::DoInsertPage(size_t pagePos,
|
|||||||
|
|
||||||
DoUpdateSelection(bSelect, pagePos);
|
DoUpdateSelection(bSelect, pagePos);
|
||||||
|
|
||||||
m_bookctrl->InvalidateBestSize();
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -258,8 +256,6 @@ bool wxTreebook::DoInsertSubPage(size_t pagePos,
|
|||||||
|
|
||||||
DoUpdateSelection(bSelect, newPos);
|
DoUpdateSelection(bSelect, newPos);
|
||||||
|
|
||||||
m_bookctrl->InvalidateBestSize();
|
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -308,7 +304,6 @@ wxTreebookPage *wxTreebook::DoRemovePage(size_t pagePos)
|
|||||||
|
|
||||||
tree->DeleteChildren( pageId );
|
tree->DeleteChildren( pageId );
|
||||||
tree->Delete( pageId );
|
tree->Delete( pageId );
|
||||||
tree->InvalidateBestSize();
|
|
||||||
|
|
||||||
return oldPage;
|
return oldPage;
|
||||||
}
|
}
|
||||||
@ -629,10 +624,7 @@ int wxTreebook::DoSetSelection(size_t pagePos)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if ( page )
|
if ( page )
|
||||||
{
|
|
||||||
page->SetSize(GetPageRect());
|
|
||||||
page->Show();
|
page->Show();
|
||||||
}
|
|
||||||
|
|
||||||
tree->SelectItem(DoInternalGetPage(pagePos));
|
tree->SelectItem(DoInternalGetPage(pagePos));
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user