reorder items in TreeCtrl
Vadim Zeitlin
vadim at wxwindows.org
Fri Jun 1 12:10:06 PDT 2007
On Fri, 1 Jun 2007 17:37:04 +0200 wx at 61131.com wrote:
> In the past I have done this quite often and soon will have to program it
> again. Reordering a TreeCtrl isn't rare and could become a contribution to
> wxTreeCtrl.
Well, yes, why not.
> Any idea about the member functions? Maybe like
> bool MoveSubTree(const wxTreeItemId& after, const wxTreeItemId& source);
> bool MoveSubTree(const wxTreeItemId& before, const wxTreeItemId& source);
> bool MoveSubTree(const wxTreeItemId& into, size_t before, const
> wxTreeItemId& source);
I think it should be something like
wxTreeItemId MoveBefore(const wxTreeItemId& source,
const wxTreeItemId& target);
wxTreeItemId MoveAfter(const wxTreeItemId& source,
const wxTreeItemId& target);
(the functions would return the new item id).
Regards,
VZ
--
TT-Solutions: wxWidgets consultancy and technical support
http://www.tt-solutions.com/
More information about the wx-users
mailing list