wxWidgets / wxWidgets

Cross-Platform C++ GUI Library
https://www.wxwidgets.org/
6.57k stars 1.82k forks source link

wxCheckList GetItemAtPosition #5508

Closed wxtrac closed 3 years ago

wxtrac commented 22 years ago

Issue migrated from trac ticket # 5508

component: wxMSW | priority: normal

2002-08-13 11:35:51: frabcus created the issue


Adds a function to wxCheckList to get the item at a given mouse position.

I'm using this so right clicking can perform a selection (so I can have right click menus in my wxCheckList).

This also will enable some code to be moved to be more cross platform. In particular I think if GetItemAtPosition implemented on all platforms, wxCheckListBox::OnLeftClick would then be sharable.

wxtrac commented 22 years ago

2002-08-20 15:10:37: @vadz commented


There is/are no file(s) attached to this patch. Maybe you hadn't logged in before attaching them? Please note that you must be logged in to be able to attach any files (this is a SF feature). Please retry attaching the files after logging in. Thank you!

wxtrac commented 22 years ago

2002-08-20 17:25:47: frabcus uploaded file checklist_position_wx.patch (2.5 KiB)

wxCheckList GetItemAtPosition patch

wxtrac commented 22 years ago

2002-08-20 17:26:48: frabcus commented


Sorry Vadim, I forgot to check the box saying "Attach a file", I onlly browsed for the file with the browse button. Appears to be there now for me.

wxtrac commented 22 years ago

2002-08-21 00:55:38: @vadz commented


I've applied it now but I renamed the method to HitTest() for consistency with the other classes. BTW, I see quiet a few improvements to this patch:

a) this method should be in wxListBox, not wxCheckListBox b) it should be implemented for the other ports... c) it should be documented

So if you have some free time, please feel welcome to improve it! :-)