comctl32/listview: Enable column reordering.
This commit is contained in:
parent
8c6d91052d
commit
c96900b904
|
@ -52,7 +52,6 @@
|
||||||
* -- Support CustomDraw options for _WIN32_IE >= 0x560 (see NMLVCUSTOMDRAW docs).
|
* -- Support CustomDraw options for _WIN32_IE >= 0x560 (see NMLVCUSTOMDRAW docs).
|
||||||
* -- LVA_SNAPTOGRID not implemented
|
* -- LVA_SNAPTOGRID not implemented
|
||||||
* -- LISTVIEW_ApproximateViewRect partially implemented
|
* -- LISTVIEW_ApproximateViewRect partially implemented
|
||||||
* -- LISTVIEW_[GS]etColumnOrderArray stubs
|
|
||||||
* -- LISTVIEW_SetColumnWidth ignores header images & bitmap
|
* -- LISTVIEW_SetColumnWidth ignores header images & bitmap
|
||||||
* -- LISTVIEW_SetIconSpacing is incomplete
|
* -- LISTVIEW_SetIconSpacing is incomplete
|
||||||
* -- LISTVIEW_StyleChanged doesn't handle some changes too well
|
* -- LISTVIEW_StyleChanged doesn't handle some changes too well
|
||||||
|
@ -7556,17 +7555,17 @@ static BOOL LISTVIEW_SetColumnT(const LISTVIEW_INFO *infoPtr, INT nColumn,
|
||||||
* SUCCESS : TRUE
|
* SUCCESS : TRUE
|
||||||
* FAILURE : FALSE
|
* FAILURE : FALSE
|
||||||
*/
|
*/
|
||||||
static BOOL LISTVIEW_SetColumnOrderArray(const LISTVIEW_INFO *infoPtr, INT iCount, const INT *lpiArray)
|
static BOOL LISTVIEW_SetColumnOrderArray(LISTVIEW_INFO *infoPtr, INT iCount, const INT *lpiArray)
|
||||||
{
|
{
|
||||||
FIXME("iCount %d lpiArray %p\n", iCount, lpiArray);
|
TRACE("iCount %d lpiArray %p\n", iCount, lpiArray);
|
||||||
|
|
||||||
if (!lpiArray)
|
if (!lpiArray || !IsWindow(infoPtr->hwndHeader)) return FALSE;
|
||||||
return FALSE;
|
|
||||||
|
|
||||||
return TRUE;
|
infoPtr->colRectsDirty = TRUE;
|
||||||
|
|
||||||
|
return SendMessageW(infoPtr->hwndHeader, HDM_SETORDERARRAY, iCount, (LPARAM)lpiArray);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/***
|
/***
|
||||||
* DESCRIPTION:
|
* DESCRIPTION:
|
||||||
* Sets the width of a column
|
* Sets the width of a column
|
||||||
|
@ -9541,9 +9540,10 @@ static LRESULT LISTVIEW_HeaderNotification(LISTVIEW_INFO *infoPtr, const NMHEADE
|
||||||
return (infoPtr->dwLvExStyle & LVS_EX_HEADERDRAGDROP) == 0;
|
return (infoPtr->dwLvExStyle & LVS_EX_HEADERDRAGDROP) == 0;
|
||||||
|
|
||||||
case HDN_ENDDRAG:
|
case HDN_ENDDRAG:
|
||||||
FIXME("Changing column order not implemented\n");
|
infoPtr->colRectsDirty = TRUE;
|
||||||
|
LISTVIEW_InvalidateList(infoPtr);
|
||||||
notify_forward_header(infoPtr, lpnmh);
|
notify_forward_header(infoPtr, lpnmh);
|
||||||
return TRUE;
|
return FALSE;
|
||||||
|
|
||||||
case HDN_ITEMCHANGINGW:
|
case HDN_ITEMCHANGINGW:
|
||||||
case HDN_ITEMCHANGINGA:
|
case HDN_ITEMCHANGINGA:
|
||||||
|
|
|
@ -3159,7 +3159,7 @@ static void test_getitemrect(void)
|
||||||
r = SendMessage(hwnd, LVM_GETITEMPOSITION, 0, (LPARAM)&pt);
|
r = SendMessage(hwnd, LVM_GETITEMPOSITION, 0, (LPARAM)&pt);
|
||||||
expect(TRUE, r);
|
expect(TRUE, r);
|
||||||
/* 1 indexed column width + padding */
|
/* 1 indexed column width + padding */
|
||||||
todo_wine expect(102, pt.x);
|
expect(102, pt.x);
|
||||||
/* rect is at zero too */
|
/* rect is at zero too */
|
||||||
rect.left = LVIR_BOUNDS;
|
rect.left = LVIR_BOUNDS;
|
||||||
rect.right = rect.top = rect.bottom = -1;
|
rect.right = rect.top = rect.bottom = -1;
|
||||||
|
@ -3174,7 +3174,7 @@ static void test_getitemrect(void)
|
||||||
r = SendMessage(hwnd, LVM_GETITEMRECT, 0, (LPARAM)&rect);
|
r = SendMessage(hwnd, LVM_GETITEMRECT, 0, (LPARAM)&rect);
|
||||||
expect(TRUE, r);
|
expect(TRUE, r);
|
||||||
/* column width + padding */
|
/* column width + padding */
|
||||||
todo_wine expect(102, rect.left);
|
expect(102, rect.left);
|
||||||
|
|
||||||
/* back to initial order */
|
/* back to initial order */
|
||||||
order[0] = 0; order[1] = 1;
|
order[0] = 0; order[1] = 1;
|
||||||
|
|
Loading…
Reference in New Issue