1 ///////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxListCtrl class
4 // Author: Vadim Zeitlin
8 // Copyright: (c) wxWidgets team
9 // Licence: wxWindows licence
10 ///////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_LISTBASE_H_BASE_
13 #define _WX_LISTBASE_H_BASE_
15 #include "wx/colour.h"
17 #include "wx/gdicmn.h"
19 #include "wx/control.h"
21 class WXDLLIMPEXP_FWD_CORE wxImageList
;
23 // ----------------------------------------------------------------------------
25 // ----------------------------------------------------------------------------
27 // type of compare function for wxListCtrl sort operation
29 int (wxCALLBACK
*wxListCtrlCompare
)(wxIntPtr item1
, wxIntPtr item2
, wxIntPtr sortData
);
31 // ----------------------------------------------------------------------------
32 // wxListCtrl constants
33 // ----------------------------------------------------------------------------
36 #define wxLC_VRULES 0x0001
37 #define wxLC_HRULES 0x0002
39 #define wxLC_ICON 0x0004
40 #define wxLC_SMALL_ICON 0x0008
41 #define wxLC_LIST 0x0010
42 #define wxLC_REPORT 0x0020
44 #define wxLC_ALIGN_TOP 0x0040
45 #define wxLC_ALIGN_LEFT 0x0080
46 #define wxLC_AUTOARRANGE 0x0100
47 #define wxLC_VIRTUAL 0x0200
48 #define wxLC_EDIT_LABELS 0x0400
49 #define wxLC_NO_HEADER 0x0800
50 #define wxLC_NO_SORT_HEADER 0x1000
51 #define wxLC_SINGLE_SEL 0x2000
52 #define wxLC_SORT_ASCENDING 0x4000
53 #define wxLC_SORT_DESCENDING 0x8000
55 #define wxLC_MASK_TYPE (wxLC_ICON | wxLC_SMALL_ICON | wxLC_LIST | wxLC_REPORT)
56 #define wxLC_MASK_ALIGN (wxLC_ALIGN_TOP | wxLC_ALIGN_LEFT)
57 #define wxLC_MASK_SORT (wxLC_SORT_ASCENDING | wxLC_SORT_DESCENDING)
59 // for compatibility only
60 #define wxLC_USER_TEXT wxLC_VIRTUAL
63 // (a) too much detail
64 // (b) not enough style flags
65 // (c) not implemented anyhow in the generic version
67 // #define wxLC_NO_SCROLL
68 // #define wxLC_NO_LABEL_WRAP
69 // #define wxLC_OWNERDRAW_FIXED
70 // #define wxLC_SHOW_SEL_ALWAYS
72 // Mask flags to tell app/GUI what fields of wxListItem are valid
73 #define wxLIST_MASK_STATE 0x0001
74 #define wxLIST_MASK_TEXT 0x0002
75 #define wxLIST_MASK_IMAGE 0x0004
76 #define wxLIST_MASK_DATA 0x0008
77 #define wxLIST_SET_ITEM 0x0010
78 #define wxLIST_MASK_WIDTH 0x0020
79 #define wxLIST_MASK_FORMAT 0x0040
81 // State flags for indicating the state of an item
82 #define wxLIST_STATE_DONTCARE 0x0000
83 #define wxLIST_STATE_DROPHILITED 0x0001 // MSW only
84 #define wxLIST_STATE_FOCUSED 0x0002
85 #define wxLIST_STATE_SELECTED 0x0004
86 #define wxLIST_STATE_CUT 0x0008 // MSW only
87 #define wxLIST_STATE_DISABLED 0x0010 // OS2 only
88 #define wxLIST_STATE_FILTERED 0x0020 // OS2 only
89 #define wxLIST_STATE_INUSE 0x0040 // OS2 only
90 #define wxLIST_STATE_PICKED 0x0080 // OS2 only
91 #define wxLIST_STATE_SOURCE 0x0100 // OS2 only
93 // Hit test flags, used in HitTest
94 #define wxLIST_HITTEST_ABOVE 0x0001 // Above the client area.
95 #define wxLIST_HITTEST_BELOW 0x0002 // Below the client area.
96 #define wxLIST_HITTEST_NOWHERE 0x0004 // In the client area but below the last item.
97 #define wxLIST_HITTEST_ONITEMICON 0x0020 // On the bitmap associated with an item.
98 #define wxLIST_HITTEST_ONITEMLABEL 0x0080 // On the label (string) associated with an item.
99 #define wxLIST_HITTEST_ONITEMRIGHT 0x0100 // In the area to the right of an item.
100 #define wxLIST_HITTEST_ONITEMSTATEICON 0x0200 // On the state icon for a tree view item that is in a user-defined state.
101 #define wxLIST_HITTEST_TOLEFT 0x0400 // To the left of the client area.
102 #define wxLIST_HITTEST_TORIGHT 0x0800 // To the right of the client area.
104 #define wxLIST_HITTEST_ONITEM (wxLIST_HITTEST_ONITEMICON | wxLIST_HITTEST_ONITEMLABEL | wxLIST_HITTEST_ONITEMSTATEICON)
106 // GetSubItemRect constants
107 #define wxLIST_GETSUBITEMRECT_WHOLEITEM -1l
109 // Flags for GetNextItem (MSW only except wxLIST_NEXT_ALL)
112 wxLIST_NEXT_ABOVE
, // Searches for an item above the specified item
113 wxLIST_NEXT_ALL
, // Searches for subsequent item by index
114 wxLIST_NEXT_BELOW
, // Searches for an item below the specified item
115 wxLIST_NEXT_LEFT
, // Searches for an item to the left of the specified item
116 wxLIST_NEXT_RIGHT
// Searches for an item to the right of the specified item
119 // Alignment flags for Arrange (MSW only except wxLIST_ALIGN_LEFT)
122 wxLIST_ALIGN_DEFAULT
,
125 wxLIST_ALIGN_SNAP_TO_GRID
128 // Column format (MSW only except wxLIST_FORMAT_LEFT)
129 enum wxListColumnFormat
133 wxLIST_FORMAT_CENTRE
,
134 wxLIST_FORMAT_CENTER
= wxLIST_FORMAT_CENTRE
137 // Autosize values for SetColumnWidth
140 wxLIST_AUTOSIZE
= -1,
141 wxLIST_AUTOSIZE_USEHEADER
= -2 // partly supported by generic version
144 // Flag values for GetItemRect
152 // Flag values for FindItem (MSW only)
161 // ----------------------------------------------------------------------------
162 // wxListItemAttr: a structure containing the visual attributes of an item
163 // ----------------------------------------------------------------------------
165 // TODO: this should be renamed to wxItemAttr or something general like this
166 // and used as base class for wxTextAttr which duplicates this class
167 // entirely currently
168 class WXDLLIMPEXP_CORE wxListItemAttr
173 wxListItemAttr(const wxColour
& colText
,
174 const wxColour
& colBack
,
176 : m_colText(colText
), m_colBack(colBack
), m_font(font
)
180 // default copy ctor, assignment operator and dtor are ok
184 void SetTextColour(const wxColour
& colText
) { m_colText
= colText
; }
185 void SetBackgroundColour(const wxColour
& colBack
) { m_colBack
= colBack
; }
186 void SetFont(const wxFont
& font
) { m_font
= font
; }
189 bool HasTextColour() const { return m_colText
.IsOk(); }
190 bool HasBackgroundColour() const { return m_colBack
.IsOk(); }
191 bool HasFont() const { return m_font
.IsOk(); }
193 const wxColour
& GetTextColour() const { return m_colText
; }
194 const wxColour
& GetBackgroundColour() const { return m_colBack
; }
195 const wxFont
& GetFont() const { return m_font
; }
198 // this is almost like assignment operator except it doesn't overwrite the
199 // fields unset in the source attribute
200 void AssignFrom(const wxListItemAttr
& source
)
202 if ( source
.HasTextColour() )
203 SetTextColour(source
.GetTextColour());
204 if ( source
.HasBackgroundColour() )
205 SetBackgroundColour(source
.GetBackgroundColour());
206 if ( source
.HasFont() )
207 SetFont(source
.GetFont());
216 // ----------------------------------------------------------------------------
217 // wxListItem: the item or column info, used to exchange data with wxListCtrl
218 // ----------------------------------------------------------------------------
220 class WXDLLIMPEXP_CORE wxListItem
: public wxObject
223 wxListItem() { Init(); m_attr
= NULL
; }
224 wxListItem(const wxListItem
& item
)
227 m_itemId(item
.m_itemId
),
229 m_state(item
.m_state
),
230 m_stateMask(item
.m_stateMask
),
232 m_image(item
.m_image
),
234 m_format(item
.m_format
),
235 m_width(item
.m_width
),
238 // copy list item attributes
239 if ( item
.HasAttributes() )
240 m_attr
= new wxListItemAttr(*item
.GetAttributes());
243 wxListItem
& operator=(const wxListItem
& item
)
247 m_mask
= item
.m_mask
;
248 m_itemId
= item
.m_itemId
;
250 m_state
= item
.m_state
;
251 m_stateMask
= item
.m_stateMask
;
252 m_text
= item
.m_text
;
253 m_image
= item
.m_image
;
254 m_data
= item
.m_data
;
255 m_format
= item
.m_format
;
256 m_width
= item
.m_width
;
257 m_attr
= item
.m_attr
? new wxListItemAttr(*item
.m_attr
) : NULL
;
263 virtual ~wxListItem() { delete m_attr
; }
266 void Clear() { Init(); m_text
.clear(); ClearAttributes(); }
267 void ClearAttributes() { if ( m_attr
) { delete m_attr
; m_attr
= NULL
; } }
270 void SetMask(long mask
)
274 void SetColumn(int col
)
276 void SetState(long state
)
277 { m_mask
|= wxLIST_MASK_STATE
; m_state
= state
; m_stateMask
|= state
; }
278 void SetStateMask(long stateMask
)
279 { m_stateMask
= stateMask
; }
280 void SetText(const wxString
& text
)
281 { m_mask
|= wxLIST_MASK_TEXT
; m_text
= text
; }
282 void SetImage(int image
)
283 { m_mask
|= wxLIST_MASK_IMAGE
; m_image
= image
; }
284 void SetData(long data
)
285 { m_mask
|= wxLIST_MASK_DATA
; m_data
= data
; }
286 void SetData(void *data
)
287 { m_mask
|= wxLIST_MASK_DATA
; m_data
= wxPtrToUInt(data
); }
289 void SetWidth(int width
)
290 { m_mask
|= wxLIST_MASK_WIDTH
; m_width
= width
; }
291 void SetAlign(wxListColumnFormat align
)
292 { m_mask
|= wxLIST_MASK_FORMAT
; m_format
= align
; }
294 void SetTextColour(const wxColour
& colText
)
295 { Attributes().SetTextColour(colText
); }
296 void SetBackgroundColour(const wxColour
& colBack
)
297 { Attributes().SetBackgroundColour(colBack
); }
298 void SetFont(const wxFont
& font
)
299 { Attributes().SetFont(font
); }
302 long GetMask() const { return m_mask
; }
303 long GetId() const { return m_itemId
; }
304 int GetColumn() const { return m_col
; }
305 long GetState() const { return m_state
& m_stateMask
; }
306 const wxString
& GetText() const { return m_text
; }
307 int GetImage() const { return m_image
; }
308 wxUIntPtr
GetData() const { return m_data
; }
310 int GetWidth() const { return m_width
; }
311 wxListColumnFormat
GetAlign() const { return (wxListColumnFormat
)m_format
; }
313 wxListItemAttr
*GetAttributes() const { return m_attr
; }
314 bool HasAttributes() const { return m_attr
!= NULL
; }
316 wxColour
GetTextColour() const
317 { return HasAttributes() ? m_attr
->GetTextColour() : wxNullColour
; }
318 wxColour
GetBackgroundColour() const
319 { return HasAttributes() ? m_attr
->GetBackgroundColour()
321 wxFont
GetFont() const
322 { return HasAttributes() ? m_attr
->GetFont() : wxNullFont
; }
324 // this conversion is necessary to make old code using GetItem() to
326 operator long() const { return m_itemId
; }
328 // these members are public for compatibility
330 long m_mask
; // Indicates what fields are valid
331 long m_itemId
; // The zero-based item position
332 int m_col
; // Zero-based column, if in report mode
333 long m_state
; // The state of the item
334 long m_stateMask
;// Which flags of m_state are valid (uses same flags)
335 wxString m_text
; // The label/header text
336 int m_image
; // The zero-based index into an image list
337 wxUIntPtr m_data
; // App-defined data
340 int m_format
; // left, right, centre
341 int m_width
; // width of column
344 int m_miniImage
; // handle to the mini image for OS/2
348 // creates m_attr if we don't have it yet
349 wxListItemAttr
& Attributes()
352 m_attr
= new wxListItemAttr
;
367 m_format
= wxLIST_FORMAT_CENTRE
;
371 wxListItemAttr
*m_attr
; // optional pointer to the items style
374 DECLARE_DYNAMIC_CLASS(wxListItem
)
377 // ----------------------------------------------------------------------------
378 // wxListCtrlBase: the base class for the main control itself.
379 // ----------------------------------------------------------------------------
381 // Unlike other base classes, this class doesn't currently define the API of
382 // the real control class but is just used for implementation convenience. We
383 // should define the public class functions as pure virtual here in the future
385 class WXDLLIMPEXP_CORE wxListCtrlBase
: public wxControl
390 // Image list methods.
391 // -------------------
393 // Associate the given (possibly NULL to indicate that no images will be
394 // used) image list with the control. The ownership of the image list
395 // passes to the control, i.e. it will be deleted when the control itself
398 // The value of "which" must be one of wxIMAGE_LIST_{NORMAL,SMALL,STATE}.
399 virtual void AssignImageList(wxImageList
* imageList
, int which
) = 0;
401 // Same as AssignImageList() but the control does not delete the image list
402 // so it can be shared among several controls.
403 virtual void SetImageList(wxImageList
* imageList
, int which
) = 0;
405 // Return the currently used image list, may be NULL.
406 virtual wxImageList
* GetImageList(int which
) const = 0;
409 // Column-related methods.
410 // -----------------------
412 // All these methods can only be used in report view mode.
414 // Appends a new column.
416 // Returns the index of the newly inserted column or -1 on error.
417 long AppendColumn(const wxString
& heading
,
418 int format
= wxLIST_FORMAT_LEFT
,
421 // Add a new column to the control at the position "col".
423 // Returns the index of the newly inserted column or -1 on error.
424 long InsertColumn(long col
, const wxListItem
& info
);
425 long InsertColumn(long col
,
426 const wxString
& heading
,
427 int format
= wxLIST_FORMAT_LEFT
,
428 int width
= wxLIST_AUTOSIZE
);
430 // Delete the given or all columns.
431 virtual bool DeleteColumn(int col
) = 0;
432 virtual bool DeleteAllColumns() = 0;
434 // Return the current number of columns.
435 virtual int GetColumnCount() const = 0;
437 // Get or update information about the given column. Set item mask to
438 // indicate the fields to retrieve or change.
440 // Returns false on error, e.g. if the column index is invalid.
441 virtual bool GetColumn(int col
, wxListItem
& item
) const = 0;
442 virtual bool SetColumn(int col
, const wxListItem
& item
) = 0;
444 // Convenient wrappers for the above methods which get or update just the
446 virtual int GetColumnWidth(int col
) const = 0;
447 virtual bool SetColumnWidth(int col
, int width
) = 0;
450 // Other miscellaneous accessors.
451 // ------------------------------
453 // Convenient functions for testing the list control mode:
454 bool InReportView() const { return HasFlag(wxLC_REPORT
); }
455 bool IsVirtual() const { return HasFlag(wxLC_VIRTUAL
); }
458 // Real implementations methods to which our public forwards.
459 virtual long DoInsertColumn(long col
, const wxListItem
& info
) = 0;
461 // Overridden methods of the base class.
462 virtual wxSize
DoGetBestClientSize() const;
465 // ----------------------------------------------------------------------------
466 // wxListEvent - the event class for the wxListCtrl notifications
467 // ----------------------------------------------------------------------------
469 class WXDLLIMPEXP_CORE wxListEvent
: public wxNotifyEvent
472 wxListEvent(wxEventType commandType
= wxEVT_NULL
, int winid
= 0)
473 : wxNotifyEvent(commandType
, winid
)
480 , m_editCancelled(false)
483 wxListEvent(const wxListEvent
& event
)
484 : wxNotifyEvent(event
)
485 , m_code(event
.m_code
)
486 , m_oldItemIndex(event
.m_oldItemIndex
)
487 , m_itemIndex(event
.m_itemIndex
)
489 , m_pointDrag(event
.m_pointDrag
)
490 , m_item(event
.m_item
)
491 , m_editCancelled(event
.m_editCancelled
)
494 int GetKeyCode() const { return m_code
; }
495 long GetIndex() const { return m_itemIndex
; }
496 int GetColumn() const { return m_col
; }
497 wxPoint
GetPoint() const { return m_pointDrag
; }
498 const wxString
& GetLabel() const { return m_item
.m_text
; }
499 const wxString
& GetText() const { return m_item
.m_text
; }
500 int GetImage() const { return m_item
.m_image
; }
501 long GetData() const { return static_cast<long>(m_item
.m_data
); }
502 long GetMask() const { return m_item
.m_mask
; }
503 const wxListItem
& GetItem() const { return m_item
; }
505 // for wxEVT_COMMAND_LIST_CACHE_HINT only
506 long GetCacheFrom() const { return m_oldItemIndex
; }
507 long GetCacheTo() const { return m_itemIndex
; }
509 // was label editing canceled? (for wxEVT_COMMAND_LIST_END_LABEL_EDIT only)
510 bool IsEditCancelled() const { return m_editCancelled
; }
511 void SetEditCanceled(bool editCancelled
) { m_editCancelled
= editCancelled
; }
513 virtual wxEvent
*Clone() const { return new wxListEvent(*this); }
515 //protected: -- not for backwards compatibility
517 long m_oldItemIndex
; // only for wxEVT_COMMAND_LIST_CACHE_HINT
525 bool m_editCancelled
;
528 DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxListEvent
)
531 // ----------------------------------------------------------------------------
532 // wxListCtrl event macros
533 // ----------------------------------------------------------------------------
535 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_BEGIN_DRAG
, wxListEvent
);
536 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_BEGIN_RDRAG
, wxListEvent
);
537 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT
, wxListEvent
);
538 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_END_LABEL_EDIT
, wxListEvent
);
539 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_DELETE_ITEM
, wxListEvent
);
540 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS
, wxListEvent
);
542 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_ITEM_SELECTED
, wxListEvent
);
543 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_ITEM_DESELECTED
, wxListEvent
);
544 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_KEY_DOWN
, wxListEvent
);
545 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_INSERT_ITEM
, wxListEvent
);
546 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_COL_CLICK
, wxListEvent
);
547 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK
, wxListEvent
);
548 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK
, wxListEvent
);
549 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_ITEM_ACTIVATED
, wxListEvent
);
550 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_CACHE_HINT
, wxListEvent
);
551 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_COL_RIGHT_CLICK
, wxListEvent
);
552 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_COL_BEGIN_DRAG
, wxListEvent
);
553 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_COL_DRAGGING
, wxListEvent
);
554 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_COL_END_DRAG
, wxListEvent
);
555 wxDECLARE_EXPORTED_EVENT( WXDLLIMPEXP_CORE
, wxEVT_COMMAND_LIST_ITEM_FOCUSED
, wxListEvent
);
557 typedef void (wxEvtHandler::*wxListEventFunction
)(wxListEvent
&);
559 #define wxListEventHandler(func) \
560 wxEVENT_HANDLER_CAST(wxListEventFunction, func)
562 #define wx__DECLARE_LISTEVT(evt, id, fn) \
563 wx__DECLARE_EVT1(wxEVT_COMMAND_LIST_ ## evt, id, wxListEventHandler(fn))
565 #define EVT_LIST_BEGIN_DRAG(id, fn) wx__DECLARE_LISTEVT(BEGIN_DRAG, id, fn)
566 #define EVT_LIST_BEGIN_RDRAG(id, fn) wx__DECLARE_LISTEVT(BEGIN_RDRAG, id, fn)
567 #define EVT_LIST_BEGIN_LABEL_EDIT(id, fn) wx__DECLARE_LISTEVT(BEGIN_LABEL_EDIT, id, fn)
568 #define EVT_LIST_END_LABEL_EDIT(id, fn) wx__DECLARE_LISTEVT(END_LABEL_EDIT, id, fn)
569 #define EVT_LIST_DELETE_ITEM(id, fn) wx__DECLARE_LISTEVT(DELETE_ITEM, id, fn)
570 #define EVT_LIST_DELETE_ALL_ITEMS(id, fn) wx__DECLARE_LISTEVT(DELETE_ALL_ITEMS, id, fn)
571 #define EVT_LIST_KEY_DOWN(id, fn) wx__DECLARE_LISTEVT(KEY_DOWN, id, fn)
572 #define EVT_LIST_INSERT_ITEM(id, fn) wx__DECLARE_LISTEVT(INSERT_ITEM, id, fn)
574 #define EVT_LIST_COL_CLICK(id, fn) wx__DECLARE_LISTEVT(COL_CLICK, id, fn)
575 #define EVT_LIST_COL_RIGHT_CLICK(id, fn) wx__DECLARE_LISTEVT(COL_RIGHT_CLICK, id, fn)
576 #define EVT_LIST_COL_BEGIN_DRAG(id, fn) wx__DECLARE_LISTEVT(COL_BEGIN_DRAG, id, fn)
577 #define EVT_LIST_COL_DRAGGING(id, fn) wx__DECLARE_LISTEVT(COL_DRAGGING, id, fn)
578 #define EVT_LIST_COL_END_DRAG(id, fn) wx__DECLARE_LISTEVT(COL_END_DRAG, id, fn)
580 #define EVT_LIST_ITEM_SELECTED(id, fn) wx__DECLARE_LISTEVT(ITEM_SELECTED, id, fn)
581 #define EVT_LIST_ITEM_DESELECTED(id, fn) wx__DECLARE_LISTEVT(ITEM_DESELECTED, id, fn)
582 #define EVT_LIST_ITEM_RIGHT_CLICK(id, fn) wx__DECLARE_LISTEVT(ITEM_RIGHT_CLICK, id, fn)
583 #define EVT_LIST_ITEM_MIDDLE_CLICK(id, fn) wx__DECLARE_LISTEVT(ITEM_MIDDLE_CLICK, id, fn)
584 #define EVT_LIST_ITEM_ACTIVATED(id, fn) wx__DECLARE_LISTEVT(ITEM_ACTIVATED, id, fn)
585 #define EVT_LIST_ITEM_FOCUSED(id, fn) wx__DECLARE_LISTEVT(ITEM_FOCUSED, id, fn)
587 #define EVT_LIST_CACHE_HINT(id, fn) wx__DECLARE_LISTEVT(CACHE_HINT, id, fn)
591 // _WX_LISTCTRL_H_BASE_