]> git.saurik.com Git - wxWidgets.git/blame - include/wx/motif/ctrlsub.h
Add test for context menu, fixed mem leak, fixed focus problem when re-editing same...
[wxWidgets.git] / include / wx / motif / ctrlsub.h
CommitLineData
a236aa20
VZ
1///////////////////////////////////////////////////////////////////////////////
2// Name: wx/motif/ctrlsub.h
3// Purpose: common functionality of wxItemContainer-derived controls
4// Author: Vadim Zeitlin
5// Created: 2007-07-25
6// RCS-ID: $Id$
7// Copyright: (c) 2007 Vadim Zeitlin <vadim@wxwindows.org>
8// Licence: wxWindows licence
9///////////////////////////////////////////////////////////////////////////////
10
11#ifndef _WX_MOTIF_CTRLSUB_H_
12#define _WX_MOTIF_CTRLSUB_H_
13
14#include "wx/dynarray.h"
15#include "wx/generic/ctrlsub.h"
16
17// ----------------------------------------------------------------------------
18// wxControlWithItems
19// ----------------------------------------------------------------------------
20
21class wxControlWithItems : public wxControlWithItemsGeneric
22{
23public:
24 wxControlWithItems() { }
25
26protected:
27 // Motif functions inserting items in the control interpret positions
28 // differently from wx: they're 1-based and 0 means to append
29 unsigned int GetMotifPosition(unsigned int pos) const
30 {
31 return pos == GetCount() ? 0 : pos + 1;
32 }
33
34private:
35 DECLARE_ABSTRACT_CLASS(wxControlWithItems)
36 DECLARE_NO_COPY_CLASS(wxControlWithItems)
37};
38
39#endif // _WX_MOTIF_CTRLSUB_H_
40