]> git.saurik.com Git - wxWidgets.git/blame - include/wx/listbase.h
use wxEventLoop in wxApp under wxMSW; factored out common code from wxX11/wxMotif...
[wxWidgets.git] / include / wx / listbase.h
CommitLineData
e81a301c
JS
1///////////////////////////////////////////////////////////////////////////////
2// Name: wx/listctrl.h
3// Purpose: wxListCtrl class
4// Author: Vadim Zeitlin
5// Modified by:
6// Created: 04.12.99
7// RCS-ID: $Id$
8// Copyright: (c) wxWindows team
9// Licence: wxWindows licence
10///////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_LISTBASE_H_BASE_
13#define _WX_LISTBASE_H_BASE_
14
12028905 15#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
e81a301c
JS
16// #pragma interface "listctrlbase.h"
17#endif
18
19#if wxUSE_LISTCTRL
20
87f086bc 21#include "wx/colour.h"
ec64c745 22#include "wx/font.h"
87f086bc
VZ
23#include "wx/gdicmn.h"
24
25#include "wx/event.h"
ec64c745 26
e81a301c
JS
27// ----------------------------------------------------------------------------
28// types
29// ----------------------------------------------------------------------------
30
31// type of compare function for wxListCtrl sort operation
32typedef int (wxCALLBACK *wxListCtrlCompare)(long item1, long item2, long sortData);
33
34// ----------------------------------------------------------------------------
35// wxListCtrl constants
36// ----------------------------------------------------------------------------
37
38// style flags
39#define wxLC_VRULES 0x0001
40#define wxLC_HRULES 0x0002
41
42#define wxLC_ICON 0x0004
43#define wxLC_SMALL_ICON 0x0008
44#define wxLC_LIST 0x0010
45#define wxLC_REPORT 0x0020
46
47#define wxLC_ALIGN_TOP 0x0040
48#define wxLC_ALIGN_LEFT 0x0080
49#define wxLC_AUTOARRANGE 0x0100
50#define wxLC_VIRTUAL 0x0200
51#define wxLC_EDIT_LABELS 0x0400
52#define wxLC_NO_HEADER 0x0800
53#define wxLC_NO_SORT_HEADER 0x1000
54#define wxLC_SINGLE_SEL 0x2000
55#define wxLC_SORT_ASCENDING 0x4000
56#define wxLC_SORT_DESCENDING 0x8000
57
58#define wxLC_MASK_TYPE (wxLC_ICON | wxLC_SMALL_ICON | wxLC_LIST | wxLC_REPORT)
59#define wxLC_MASK_ALIGN (wxLC_ALIGN_TOP | wxLC_ALIGN_LEFT)
60#define wxLC_MASK_SORT (wxLC_SORT_ASCENDING | wxLC_SORT_DESCENDING)
61
62// for compatibility only
63#define wxLC_USER_TEXT wxLC_VIRTUAL
64
65// Omitted because
66// (a) too much detail
67// (b) not enough style flags
68// (c) not implemented anyhow in the generic version
69//
70// #define wxLC_NO_SCROLL
71// #define wxLC_NO_LABEL_WRAP
72// #define wxLC_OWNERDRAW_FIXED
73// #define wxLC_SHOW_SEL_ALWAYS
74
75// Mask flags to tell app/GUI what fields of wxListItem are valid
76#define wxLIST_MASK_STATE 0x0001
77#define wxLIST_MASK_TEXT 0x0002
78#define wxLIST_MASK_IMAGE 0x0004
79#define wxLIST_MASK_DATA 0x0008
80#define wxLIST_SET_ITEM 0x0010
81#define wxLIST_MASK_WIDTH 0x0020
82#define wxLIST_MASK_FORMAT 0x0040
83
84// State flags for indicating the state of an item
85#define wxLIST_STATE_DONTCARE 0x0000
86#define wxLIST_STATE_DROPHILITED 0x0001 // MSW only
87#define wxLIST_STATE_FOCUSED 0x0002
88#define wxLIST_STATE_SELECTED 0x0004
89#define wxLIST_STATE_CUT 0x0008 // MSW only
c220541d
DW
90#define wxLIST_STATE_DISABLED 0x0010 // OS2 only
91#define wxLIST_STATE_FILTERED 0x0020 // OS2 only
92#define wxLIST_STATE_INUSE 0x0040 // OS2 only
93#define wxLIST_STATE_PICKED 0x0080 // OS2 only
94#define wxLIST_STATE_SOURCE 0x0100 // OS2 only
e81a301c
JS
95
96// Hit test flags, used in HitTest
97#define wxLIST_HITTEST_ABOVE 0x0001 // Above the client area.
98#define wxLIST_HITTEST_BELOW 0x0002 // Below the client area.
99#define wxLIST_HITTEST_NOWHERE 0x0004 // In the client area but below the last item.
100#define wxLIST_HITTEST_ONITEMICON 0x0020 // On the bitmap associated with an item.
101#define wxLIST_HITTEST_ONITEMLABEL 0x0080 // On the label (string) associated with an item.
102#define wxLIST_HITTEST_ONITEMRIGHT 0x0100 // In the area to the right of an item.
103#define wxLIST_HITTEST_ONITEMSTATEICON 0x0200 // On the state icon for a tree view item that is in a user-defined state.
104#define wxLIST_HITTEST_TOLEFT 0x0400 // To the left of the client area.
105#define wxLIST_HITTEST_TORIGHT 0x0800 // To the right of the client area.
106
107#define wxLIST_HITTEST_ONITEM (wxLIST_HITTEST_ONITEMICON | wxLIST_HITTEST_ONITEMLABEL | wxLIST_HITTEST_ONITEMSTATEICON)
108
109// Flags for GetNextItem (MSW only except wxLIST_NEXT_ALL)
110enum
111{
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
117};
118
119// Alignment flags for Arrange (MSW only except wxLIST_ALIGN_LEFT)
120enum
121{
122 wxLIST_ALIGN_DEFAULT,
123 wxLIST_ALIGN_LEFT,
124 wxLIST_ALIGN_TOP,
125 wxLIST_ALIGN_SNAP_TO_GRID
126};
127
128// Column format (MSW only except wxLIST_FORMAT_LEFT)
129enum wxListColumnFormat
130{
131 wxLIST_FORMAT_LEFT,
132 wxLIST_FORMAT_RIGHT,
133 wxLIST_FORMAT_CENTRE,
134 wxLIST_FORMAT_CENTER = wxLIST_FORMAT_CENTRE
135};
136
137// Autosize values for SetColumnWidth
138enum
139{
140 wxLIST_AUTOSIZE = -1,
141 wxLIST_AUTOSIZE_USEHEADER = -2 // partly supported by generic version
142};
143
144// Flag values for GetItemRect
145enum
146{
147 wxLIST_RECT_BOUNDS,
148 wxLIST_RECT_ICON,
149 wxLIST_RECT_LABEL
150};
151
152// Flag values for FindItem (MSW only)
153enum
154{
155 wxLIST_FIND_UP,
156 wxLIST_FIND_DOWN,
157 wxLIST_FIND_LEFT,
158 wxLIST_FIND_RIGHT
159};
160
161// ----------------------------------------------------------------------------
162// wxListItemAttr: a structure containing the visual attributes of an item
163// ----------------------------------------------------------------------------
164
165class WXDLLEXPORT wxListItemAttr
166{
167public:
168 // ctors
169 wxListItemAttr() { }
170 wxListItemAttr(const wxColour& colText,
171 const wxColour& colBack,
172 const wxFont& font)
173 : m_colText(colText), m_colBack(colBack), m_font(font) { }
174
175 // setters
176 void SetTextColour(const wxColour& colText) { m_colText = colText; }
177 void SetBackgroundColour(const wxColour& colBack) { m_colBack = colBack; }
178 void SetFont(const wxFont& font) { m_font = font; }
179
180 // accessors
181 bool HasTextColour() const { return m_colText.Ok(); }
182 bool HasBackgroundColour() const { return m_colBack.Ok(); }
183 bool HasFont() const { return m_font.Ok(); }
184
185 const wxColour& GetTextColour() const { return m_colText; }
186 const wxColour& GetBackgroundColour() const { return m_colBack; }
187 const wxFont& GetFont() const { return m_font; }
188
189private:
190 wxColour m_colText,
191 m_colBack;
192 wxFont m_font;
193};
194
195// ----------------------------------------------------------------------------
196// wxListItem: the item or column info, used to exchange data with wxListCtrl
197// ----------------------------------------------------------------------------
198
199class WXDLLEXPORT wxListItem : public wxObject
200{
201public:
202 wxListItem() { Init(); m_attr = NULL; }
203 wxListItem(const wxListItem& item)
204 : wxObject(),
205 m_mask(item.m_mask),
206 m_itemId(item.m_itemId),
207 m_col(item.m_col),
208 m_state(item.m_state),
209 m_stateMask(item.m_stateMask),
210 m_text(item.m_text),
211 m_image(item.m_image),
212 m_data(item.m_data),
213 m_format(item.m_format),
214 m_width(item.m_width),
215 m_attr(NULL)
216 {
217 // copy list item attributes
218 if( item.HasAttributes() )
219 m_attr = new wxListItemAttr(*item.GetAttributes());
220 }
221 virtual ~wxListItem() { delete m_attr; }
222
223 // resetting
224 void Clear() { Init(); m_text.clear(); ClearAttributes(); }
225 void ClearAttributes() { if ( m_attr ) { delete m_attr; m_attr = NULL; } }
226
227 // setters
6770762d
VZ
228 void SetMask(long mask)
229 { m_mask = mask; }
230 void SetId(long id)
231 { m_itemId = id; }
232 void SetColumn(int col)
233 { m_col = col; }
234 void SetState(long state)
235 { m_mask |= wxLIST_MASK_STATE; m_state = state; m_stateMask |= state; }
236 void SetStateMask(long stateMask)
237 { m_stateMask = stateMask; }
238 void SetText(const wxString& text)
239 { m_mask |= wxLIST_MASK_TEXT; m_text = text; }
240 void SetImage(int image)
241 { m_mask |= wxLIST_MASK_IMAGE; m_image = image; }
242 void SetData(long data)
243 { m_mask |= wxLIST_MASK_DATA; m_data = data; }
244 void SetData(void *data)
245 { m_mask |= wxLIST_MASK_DATA; m_data = (long)data; }
246
247 void SetWidth(int width)
248 { m_mask |= wxLIST_MASK_WIDTH; m_width = width; }
249 void SetAlign(wxListColumnFormat align)
250 { m_mask |= wxLIST_MASK_FORMAT; m_format = align; }
e81a301c
JS
251
252 void SetTextColour(const wxColour& colText)
253 { Attributes().SetTextColour(colText); }
254 void SetBackgroundColour(const wxColour& colBack)
255 { Attributes().SetBackgroundColour(colBack); }
256 void SetFont(const wxFont& font)
257 { Attributes().SetFont(font); }
258
259 // accessors
260 long GetMask() const { return m_mask; }
261 long GetId() const { return m_itemId; }
262 int GetColumn() const { return m_col; }
263 long GetState() const { return m_state & m_stateMask; }
264 const wxString& GetText() const { return m_text; }
265 int GetImage() const { return m_image; }
266 long GetData() const { return m_data; }
267
268 int GetWidth() const { return m_width; }
269 wxListColumnFormat GetAlign() const { return (wxListColumnFormat)m_format; }
270
271 wxListItemAttr *GetAttributes() const { return m_attr; }
272 bool HasAttributes() const { return m_attr != NULL; }
273
274 wxColour GetTextColour() const
275 { return HasAttributes() ? m_attr->GetTextColour() : wxNullColour; }
276 wxColour GetBackgroundColour() const
277 { return HasAttributes() ? m_attr->GetBackgroundColour()
278 : wxNullColour; }
279 wxFont GetFont() const
280 { return HasAttributes() ? m_attr->GetFont() : wxNullFont; }
281
282 // this conversion is necessary to make old code using GetItem() to
283 // compile
284 operator long() const { return m_itemId; }
285
286 // these members are public for compatibility
287
288 long m_mask; // Indicates what fields are valid
289 long m_itemId; // The zero-based item position
290 int m_col; // Zero-based column, if in report mode
291 long m_state; // The state of the item
292 long m_stateMask;// Which flags of m_state are valid (uses same flags)
293 wxString m_text; // The label/header text
294 int m_image; // The zero-based index into an image list
295 long m_data; // App-defined data
296
297 // For columns only
298 int m_format; // left, right, centre
299 int m_width; // width of column
300
c220541d
DW
301#ifdef __WXPM__
302 int m_miniImage; // handle to the mini image for OS/2
303#endif
304
e81a301c
JS
305protected:
306 // creates m_attr if we don't have it yet
307 wxListItemAttr& Attributes()
308 {
309 if ( !m_attr )
310 m_attr = new wxListItemAttr;
311
312 return *m_attr;
313 }
314
315 void Init()
316 {
317 m_mask = 0;
318 m_itemId = 0;
319 m_col = 0;
320 m_state = 0;
321 m_stateMask = 0;
322 m_image = 0;
323 m_data = 0;
324
325 m_format = wxLIST_FORMAT_CENTRE;
326 m_width = 0;
327 }
328
329 wxListItemAttr *m_attr; // optional pointer to the items style
330
331private:
332 // VZ: this is strange, we have a copy ctor but not operator=(), why?
333 wxListItem& operator=(const wxListItem& item);
334
335 DECLARE_DYNAMIC_CLASS(wxListItem)
336};
337
338// ----------------------------------------------------------------------------
339// wxListEvent - the event class for the wxListCtrl notifications
340// ----------------------------------------------------------------------------
341
342class WXDLLEXPORT wxListEvent : public wxNotifyEvent
343{
344public:
345 wxListEvent(wxEventType commandType = wxEVT_NULL, int id = 0)
346 : wxNotifyEvent(commandType, id)
347 , m_code(0)
348 , m_oldItemIndex(0)
349 , m_itemIndex(0)
350 , m_col(0)
351 , m_pointDrag()
352 , m_item()
353 { }
354
355 wxListEvent(const wxListEvent& event)
356 : wxNotifyEvent(event)
357 , m_code(event.m_code)
358 , m_oldItemIndex(event.m_oldItemIndex)
359 , m_itemIndex(event.m_itemIndex)
360 , m_col(event.m_col)
361 , m_pointDrag(event.m_pointDrag)
362 , m_item(event.m_item)
363 { }
364
365 int GetKeyCode() const { return m_code; }
366 long GetIndex() const { return m_itemIndex; }
367 int GetColumn() const { return m_col; }
368 wxPoint GetPoint() const { return m_pointDrag; }
369 const wxString& GetLabel() const { return m_item.m_text; }
370 const wxString& GetText() const { return m_item.m_text; }
371 int GetImage() const { return m_item.m_image; }
372 long GetData() const { return m_item.m_data; }
373 long GetMask() const { return m_item.m_mask; }
374 const wxListItem& GetItem() const { return m_item; }
375
376 // for wxEVT_COMMAND_LIST_CACHE_HINT only
377 long GetCacheFrom() const { return m_oldItemIndex; }
378 long GetCacheTo() const { return m_itemIndex; }
379
380#if WXWIN_COMPATIBILITY_2_2
381 // these methods don't do anything at all
382 long GetOldIndex() const { return 0; }
383 long GetOldItem() const { return 0; }
384
385 // this one is superseded by GetKeyCode()
386 int GetCode() const { return GetKeyCode(); }
387#endif // WXWIN_COMPATIBILITY_2_2
388
389 virtual wxEvent *Clone() const { return new wxListEvent(*this); }
390
391//protected: -- not for backwards compatibility
392 int m_code;
393 long m_oldItemIndex; // only for wxEVT_COMMAND_LIST_CACHE_HINT
394 long m_itemIndex;
395 int m_col;
396 wxPoint m_pointDrag;
397
398 wxListItem m_item;
399
400private:
fc7a2a60 401 DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxListEvent)
e81a301c
JS
402};
403
404// ----------------------------------------------------------------------------
405// wxListCtrl event macros
406// ----------------------------------------------------------------------------
407
408BEGIN_DECLARE_EVENT_TYPES()
409 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_BEGIN_DRAG, 700)
410 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_BEGIN_RDRAG, 701)
411 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT, 702)
412 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_END_LABEL_EDIT, 703)
413 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_DELETE_ITEM, 704)
414 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS, 705)
415 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_GET_INFO, 706)
416 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_SET_INFO, 707)
417 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_SELECTED, 708)
418 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_DESELECTED, 709)
419 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_KEY_DOWN, 710)
420 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_INSERT_ITEM, 711)
421 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_CLICK, 712)
422 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, 713)
423 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, 714)
424 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_ACTIVATED, 715)
425 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_CACHE_HINT, 716)
426 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_RIGHT_CLICK, 717)
427 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_BEGIN_DRAG, 718)
428 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_DRAGGING, 719)
429 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_COL_END_DRAG, 720)
430 DECLARE_EVENT_TYPE(wxEVT_COMMAND_LIST_ITEM_FOCUSED, 721)
431END_DECLARE_EVENT_TYPES()
432
433typedef void (wxEvtHandler::*wxListEventFunction)(wxListEvent&);
434
435#define EVT_LIST_BEGIN_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_BEGIN_DRAG, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
436#define EVT_LIST_BEGIN_RDRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_BEGIN_RDRAG, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
437#define EVT_LIST_BEGIN_LABEL_EDIT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_BEGIN_LABEL_EDIT, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
438#define EVT_LIST_END_LABEL_EDIT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_END_LABEL_EDIT, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
439#define EVT_LIST_DELETE_ITEM(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_DELETE_ITEM, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
440#define EVT_LIST_DELETE_ALL_ITEMS(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_DELETE_ALL_ITEMS, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
441#define EVT_LIST_GET_INFO(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_GET_INFO, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
442#define EVT_LIST_SET_INFO(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_SET_INFO, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
443#define EVT_LIST_KEY_DOWN(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_KEY_DOWN, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
444#define EVT_LIST_INSERT_ITEM(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_INSERT_ITEM, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
445
446#define EVT_LIST_COL_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_COL_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
447#define EVT_LIST_COL_RIGHT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_COL_RIGHT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
448#define EVT_LIST_COL_BEGIN_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_COL_BEGIN_DRAG, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
449#define EVT_LIST_COL_DRAGGING(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_COL_DRAGGING, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
450#define EVT_LIST_COL_END_DRAG(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_COL_END_DRAG, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
451
452#define EVT_LIST_ITEM_SELECTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_ITEM_SELECTED, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
453#define EVT_LIST_ITEM_DESELECTED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_ITEM_DESELECTED, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, NULL ),
454#define EVT_LIST_ITEM_RIGHT_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL ),
455#define EVT_LIST_ITEM_MIDDLE_CLICK(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_ITEM_MIDDLE_CLICK, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL ),
456#define EVT_LIST_ITEM_ACTIVATED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_ITEM_ACTIVATED, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL ),
457#define EVT_LIST_ITEM_FOCUSED(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_ITEM_FOCUSED, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL ),
458
459#define EVT_LIST_CACHE_HINT(id, fn) DECLARE_EVENT_TABLE_ENTRY( wxEVT_COMMAND_LIST_CACHE_HINT, id, -1, (wxObjectEventFunction) (wxEventFunction) (wxListEventFunction) & fn, (wxObject *) NULL ),
460
461#endif // wxUSE_LISTCTRL
462
463#endif
464 // _WX_LISTCTRL_H_BASE_