X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/55f42db2fb9228acd93329f702f1f41af7fa8f15..89ba044b378ff9341fc32992cb00021190b2072b:/src/msw/listctrl.cpp diff --git a/src/msw/listctrl.cpp b/src/msw/listctrl.cpp index f90acc0439..6f3a70e136 100644 --- a/src/msw/listctrl.cpp +++ b/src/msw/listctrl.cpp @@ -1893,7 +1893,7 @@ bool wxListCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result) } else #endif // defined(HDN_BEGINTRACKA) - if ( nmhdr->hwndFrom == GetHwnd() ) + if ( nmhdr->hwndFrom == GetHwnd() ) { // almost all messages use NM_LISTVIEW NM_LISTVIEW *nmLV = (NM_LISTVIEW *)nmhdr; @@ -2316,10 +2316,13 @@ bool wxListCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result) } #endif // NM_CUSTOMDRAW - // a little dose of healthy paranoia: as we never use - // LVM_SETCALLBACKMASK we're not supposed to get these ones - wxASSERT_MSG( !(lvi.mask & LVIF_STATE), - _T("we don't support state callbacks yet!") ); + // even though we never use LVM_SETCALLBACKMASK, we still + // can get messages with LVIF_STATE in lvi.mask under Vista + if ( lvi.mask & LVIF_STATE ) + { + // we don't have anything to return from here... + lvi.stateMask = 0; + } return true; }