I am working on a project implemented using WIN32 APIs, where I need some of the tree-view items at run time to be visible/invisible, based on some data entered by user. I have done some work, where I found that I can add/delete item in a tree-view control but can't find anywhere how to set item visible or invisible(I found some examples where it can be done through MFC).
I am looking for the way to set them as visible/invisible is simply because when I add an item, it requires significant back-end calculations, that repeated addition or removal will result in performance issues. I only want to do that calculation only once per tree view item.
One of the solution, I have thought, if setting tree-view item is not possible, is to simply have a linked list of tree-view items present, and add/delete only those items that are required to be visible/invisible.
Please, tell me if it is possible to set tree-view item's state as visible/invisible, If yes, then how? And if no, what can be other alternate solutions?
std::map
for the cache, or you might need some kind of tree. – arxTVM_GETITEMRECT
message to zero out the bounding rectangle on "hidden" items? Note that you'll need to hook other messages in order to prevent "hidden" items from being selected. – Jay