comctl32/listview: Enable column reordering.

This commit is contained in:
Nikolay Sivov 2009-08-04 00:42:51 +04:00 committed by Alexandre Julliard
parent 8c6d91052d
commit c96900b904
2 changed files with 11 additions and 11 deletions

View File

@ -52,7 +52,6 @@
* -- Support CustomDraw options for _WIN32_IE >= 0x560 (see NMLVCUSTOMDRAW docs).
* -- LVA_SNAPTOGRID not implemented
* -- LISTVIEW_ApproximateViewRect partially implemented
* -- LISTVIEW_[GS]etColumnOrderArray stubs
* -- LISTVIEW_SetColumnWidth ignores header images & bitmap
* -- LISTVIEW_SetIconSpacing is incomplete
* -- 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
* 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)
return FALSE;
if (!lpiArray || !IsWindow(infoPtr->hwndHeader)) return FALSE;
return TRUE;
infoPtr->colRectsDirty = TRUE;
return SendMessageW(infoPtr->hwndHeader, HDM_SETORDERARRAY, iCount, (LPARAM)lpiArray);
}
/***
* DESCRIPTION:
* 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;
case HDN_ENDDRAG:
FIXME("Changing column order not implemented\n");
infoPtr->colRectsDirty = TRUE;
LISTVIEW_InvalidateList(infoPtr);
notify_forward_header(infoPtr, lpnmh);
return TRUE;
return FALSE;
case HDN_ITEMCHANGINGW:
case HDN_ITEMCHANGINGA:

View File

@ -3159,7 +3159,7 @@ static void test_getitemrect(void)
r = SendMessage(hwnd, LVM_GETITEMPOSITION, 0, (LPARAM)&pt);
expect(TRUE, r);
/* 1 indexed column width + padding */
todo_wine expect(102, pt.x);
expect(102, pt.x);
/* rect is at zero too */
rect.left = LVIR_BOUNDS;
rect.right = rect.top = rect.bottom = -1;
@ -3174,7 +3174,7 @@ static void test_getitemrect(void)
r = SendMessage(hwnd, LVM_GETITEMRECT, 0, (LPARAM)&rect);
expect(TRUE, r);
/* column width + padding */
todo_wine expect(102, rect.left);
expect(102, rect.left);
/* back to initial order */
order[0] = 0; order[1] = 1;