Ticket #4448 (closed defect: fixed)
wxTR_MULTIPLE breaks EVT_LEFT_DOWN on MS Windows
| Reported by: | bdimm | Owned by: | |
|---|---|---|---|
| Priority: | high | Milestone: | |
| Component: | wxMSW | Version: | |
| Keywords: | wxTR_MULTIPLE, EVT_LEFT_DOWN | Cc: | bdimm, wx@…, wxscary@…, net147@… |
| Blocked By: | Patch: | no | |
| Blocking: |
Description
On Microsoft Windows, if you create a wxTextCtrl with style wxTR_MULTIPLE, left mouse button down events (EVT_LEFT_DOWN) are not triggered correctly. Specifically, you will only get an EVT_LEFT_DOWN if you click on a tree item that is already selected (either by a previous click or by moving the selection with the cursor keys). If you click on a tree item that is not selected, no EVT_LEFT_DOWN occurs. You will, however, get the EVT_LEFT_UP event. This does not occur on Linux/GTK, or when wxTR_MULTIPLE is not used.
I've attached a sample program. It just displays a little tree and displays a wxMessageBox on a EVT_LEFT_DOWN or EVT_LEFT_UP. On Windows, you'll find that you get a "Left Up" without any preceeding "Left Down" when you click on an item that is not already selected.

