[PATCH v2 4/5] comctl32: LVM_INSERTITEM handler should send LVN_ITEMCHANGING/LVN_ITEMCHANGED notifications when the item state is being set.
Nikolay Sivov
nsivov at codeweavers.com
Fri Feb 11 06:49:28 CST 2022
On 2/11/22 15:36, Dmitry Timoshkov wrote:
> - if (lpItem && !isNew && (infoPtr->notify_mask & NOTIFY_MASK_ITEM_CHANGE))
> + if (lpItem && (!isNew || (uChanged & LVIF_STATE)) && (infoPtr->notify_mask & NOTIFY_MASK_ITEM_CHANGE))
> {
> HWND hwndSelf = infoPtr->hwndSelf;
>
> @@ -4352,8 +4353,8 @@ static BOOL set_main_item(LISTVIEW_INFO *infoPtr, const LVITEMW *lpLVItem, BOOL
> }
> }
>
> - /* if we're inserting the item, we're done */
> - if (isNew) return TRUE;
> + /* if we're inserting the item and its state is not being set, we're done */
> + if (isNew && !(uChanged & LVIF_STATE)) return TRUE;
This isn't right either. On Windows, inserting with e.g.
LVIF_STATE/LVIS_CUT does not produce a change notification.
More information about the wine-devel
mailing list