Freeze wxTreeCtrl in wxMSW by hiding it.

This is far from perfect but better than alternative as freezing this control
by sending WM_SETREDRAW to it can result in completely broken behaviour as
explained in http://support.microsoft.com/kb/130611. And not freezing it at
all shows horrible flicker when adding even a relatively small number of items
at once to the control because it recalculates and repositions its scrollbars
after every parent node addition.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@72665 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2012-10-13 22:52:35 +00:00
parent 861bdae474
commit 6754c300cf
2 changed files with 32 additions and 0 deletions

View File

@@ -212,6 +212,10 @@ public:
virtual bool CanApplyThemeBorder() const { return false; }
protected:
// Implement "update locking" in a custom way for this control.
virtual void DoFreeze();
virtual void DoThaw();
// SetImageList helper
void SetAnyImageList(wxImageList *imageList, int which);