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