Fix wxEVT_TREE_STATE_IMAGE_CLICK generation in wxMSW wxTreeCtrl.
Use GET_{X,Y}_LPARAM() to extract them from the event position, which handle negative coordinates (and coordinates can perfectly well be negative when using multiple displays) correctly, unlike {LO,HI}WORD(). Closes #16812. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_3_0_BRANCH@78419 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -600,6 +600,7 @@ wxMSW:
|
|||||||
- Fix autosize after expanding/collapsing items in wxDataViewCtrl (ciglesias).
|
- Fix autosize after expanding/collapsing items in wxDataViewCtrl (ciglesias).
|
||||||
- Fix inserting tools removed from wxToolBar back into it (sbrowne).
|
- Fix inserting tools removed from wxToolBar back into it (sbrowne).
|
||||||
- Fix disabling submenu items in the menus (Artur Wieczorek).
|
- Fix disabling submenu items in the menus (Artur Wieczorek).
|
||||||
|
- Fix wxEVT_TREE_STATE_IMAGE_CLICK generation (Antal).
|
||||||
|
|
||||||
wxOSX:
|
wxOSX:
|
||||||
|
|
||||||
|
@@ -3639,8 +3639,8 @@ bool wxTreeCtrl::MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result)
|
|||||||
{
|
{
|
||||||
DWORD pos = GetMessagePos();
|
DWORD pos = GetMessagePos();
|
||||||
POINT point;
|
POINT point;
|
||||||
point.x = LOWORD(pos);
|
point.x = GET_X_LPARAM(pos);
|
||||||
point.y = HIWORD(pos);
|
point.y = GET_Y_LPARAM(pos);
|
||||||
::MapWindowPoints(HWND_DESKTOP, GetHwnd(), &point, 1);
|
::MapWindowPoints(HWND_DESKTOP, GetHwnd(), &point, 1);
|
||||||
int htFlags = 0;
|
int htFlags = 0;
|
||||||
wxTreeItemId item = HitTest(wxPoint(point.x, point.y), htFlags);
|
wxTreeItemId item = HitTest(wxPoint(point.x, point.y), htFlags);
|
||||||
|
Reference in New Issue
Block a user