# HG changeset patch # User bsmith@81767d24-ef19-dc11-ae90-00e081727c95 # Date 1074356342 0 # Node ID 56ea525c1a246cc135639354532ab534729b1aa7 # Parent 8267a3066476dbb4b51183bd7f6dd05d1c6528c4 Only activate the container select callback when the item state changes, not other item changes. (Fixes an infinite loop in Mark's testcase). diff -r 8267a3066476 -r 56ea525c1a24 win/dw.c --- a/win/dw.c Fri Dec 19 03:25:49 2003 +0000 +++ b/win/dw.c Sat Jan 17 16:19:02 2004 +0000 @@ -1615,6 +1615,7 @@ tmp->message == TVN_ITEMEXPANDED) { NMTREEVIEW FAR *tem=(NMTREEVIEW FAR *)mp2; + NMLISTVIEW FAR *lem=(NMLISTVIEW FAR *)mp2; char tmpbuf[100]; GetClassName(tem->hdr.hwndFrom, tmpbuf, 99); @@ -1689,7 +1690,7 @@ } else if(strnicmp(tmpbuf, WC_LISTVIEW, strlen(WC_LISTVIEW)+1)==0) { - if(tem->hdr.code == LVN_ITEMCHANGED && tmp->message == TVN_SELCHANGED) + if((lem->hdr.code == LVN_ITEMCHANGED && (lem->uChanged & LVIF_STATE)) && tmp->message == TVN_SELCHANGED) { if(tmp->window == tem->hdr.hwndFrom) {