http://bugs.winehq.org/show_bug.cgi?id=15833 Summary: TreeView control don't save item's state Product: Wine Version: 1.1.7 Platform: PC OS/Version: Linux Status: UNCONFIRMED Severity: enhancement Priority: P1 Component: comctl32 AssignedTo: wine-bugs(a)winehq.org ReportedBy: iwarmouse(a)gmail.com Created an attachment (id=16963) --> (http://bugs.winehq.org/attachment.cgi?id=16963) patch that i offer to fix this bug Hi. BUG: TreeView sends TVS_GETDISPINFO notifycation. Main application catch it and change "mask","state" and "stateMask" in a TVITEM structure. After returning from message handler, item's state don't changed. TreeView don't save new item state in function TREEVIEW_UpdateDispInfo after calling TREEVIEW_SendRealNotify. This is Delphi code sample, TMyTreeView inherits from TCustomTreeView //----------------------------------------------------------------- procedure TMyTreeView.CNNotify(var Message: TWMNotify); var hNode: Integer; begin with Message do case NMHdr^.code of TVN_GETDISPINFO: with PTVDispInfo(NMHdr)^ do begin hNode := item.hItem; with PTVDispInfo(NMHdr)^.item do begin mask := mask or TVIF_STATE or TVIF_HANDLE; stateMask := stateMask or TVIS_STATEIMAGEMASK; state := (state and not TVIS_STATEIMAGEMASK) or UINT(IndexToStateImageMask(MyGetItemImageIndex(hNode))); end; end; end; inherited; end; //----------------------------------------------------------------- This's link to MSDN page, where described how it must work: http://msdn.microsoft.com/en-us/library/bb773456(VS.85).aspx I'm offer this patch (attached) to fix this bug. -- Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email Do not reply to this email, post in Bugzilla using the above URL to reply. ------- You are receiving this mail because: ------- You are watching all bug changes.