http://bugs.winehq.org/show_bug.cgi?id=56431
--- Comment #29 from Wagner.a18@yahoo.com --- Okay I had to adjust my workaround again, because whith my last change the insert of new nodes was not longer working corectly.
Now it seems I have a working workaround: The problem is, at collapse the "children" parameter is set to 0... so the treeview thinks we do not longer need a plus sign, because there are no childs.
As hotfix I changed the resulting lines to set children to 1 instead of 0:
# Change 1: TREEVIEW_UnlinkItem(const TREEVIEW_ITEM *item) { TREEVIEW_ITEM *parentItem;
assert(item != NULL); assert(item->parent != NULL); /* i.e. it must not be the root */
parentItem = item->parent;
if (parentItem->firstChild == item) parentItem->firstChild = item->nextSibling;
if (parentItem->lastChild == item) parentItem->lastChild = item->prevSibling;
if (parentItem->firstChild == NULL && parentItem->lastChild == NULL && parentItem->cChildren > 0) parentItem->cChildren = 1; // !!!!!!!!!!!originally it is set to 0 here !!!!!!!!!!!!
# Change 2: TREEVIEW_RemoveAllChildren(TREEVIEW_INFO *infoPtr, const TREEVIEW_ITEM *parentItem) { TREEVIEW_ITEM *kill = parentItem->firstChild;
while (kill != NULL) { TREEVIEW_ITEM *next = kill->nextSibling;
TREEVIEW_RemoveItem(infoPtr, kill);
kill = next; }
// !!!!!!!!!!!originally it is compared against 0 here !!!!!!!!!!!! assert(parentItem->cChildren <= 1); /* I_CHILDRENCALLBACK or 0 */