comctl32: Correct listview hittest check to include the state rect.
authorLei Zhang <thestig@google.com>
Thu, 20 Mar 2008 00:11:56 +0000 (17:11 -0700)
committerAlexandre Julliard <julliard@winehq.org>
Thu, 20 Mar 2008 13:27:36 +0000 (14:27 +0100)
dlls/comctl32/listview.c

index 524d84514e4abd3faf999d6cd123bd9cfd137db7..706e92b01ab91d3962e5f9a55e49938af5584ac1 100644 (file)
@@ -6256,7 +6256,10 @@ static INT LISTVIEW_HitTest(const LISTVIEW_INFO *infoPtr, LPLVHITTESTINFO lpht,
     if (uView == LVS_REPORT)
        rcBounds = rcBox;
     else
-       UnionRect(&rcBounds, &rcIcon, &rcLabel);
+    {
+        UnionRect(&rcBounds, &rcIcon, &rcLabel);
+        UnionRect(&rcBounds, &rcBounds, &rcState);
+    }
     TRACE("rcBounds=%s\n", wine_dbgstr_rect(&rcBounds));
     if (!PtInRect(&rcBounds, opt)) return -1;