1 //####COPYRIGHTBEGIN####
3 // ----------------------------------------------------------------------------
4 // Copyright (C) 1998, 1999, 2000 Red Hat, Inc.
6 // This program is part of the eCos host tools.
8 // This program is free software; you can redistribute it and/or modify it
9 // under the terms of the GNU General Public License as published by the Free
10 // Software Foundation; either version 2 of the License, or (at your option)
13 // This program is distributed in the hope that it will be useful, but WITHOUT
14 // ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
15 // FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
18 // You should have received a copy of the GNU General Public License along with
19 // this program; if not, write to the Free Software Foundation, Inc.,
20 // 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22 // ----------------------------------------------------------------------------
24 //####COPYRIGHTEND####
27 //===========================================================================
28 //#####DESCRIPTIONBEGIN####
31 // Contact(s): julians
35 // Description: Header file for ecPropertyListCtrl
42 //####DESCRIPTIONEND####
44 //===========================================================================
46 #ifndef _ECOS_PROPERTYWIN_H_
47 #define _ECOS_PROPERTYWIN_H_
50 #pragma interface "propertywin.h"
53 #include "wx/listctrl.h"
57 class ecPropertyListCtrl : public wxListCtrl
60 enum ecFieldType {ecType, ecValue, ecDefaultValue, ecMacro, ecFile, ecURL, ecEnabled, ecMAXFIELDTYPE};
63 ecPropertyListCtrl(wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style);
67 void OnRightClick(wxMouseEvent& event);
68 void OnDoubleClick(wxMouseEvent& event);
71 int SetItem (ecFieldType f, const wxString& value);
72 int SetItem (const wxString& item, const wxString& value,int nInsertAs,int nRepeat=1);
73 int SetProperty (const wxString& value, CdlProperty prop);
74 static bool PropertyInConflictsList (CdlProperty property, const std::list<CdlConflict> & conflicts);
78 void Fill(ecConfigItem *pti);
85 DECLARE_CLASS(ecPropertyListCtrl)
89 double m_f[NCOLS]; // relative proportions of columns
91 int m_nOnSizeRecursionCount;
96 static const std::string ecPropertyListCtrl::visible_properties [];
97 static const wxChar* sm_fieldTypeImage[ecMAXFIELDTYPE];
102 // _ECOS_PROPERTYWIN_H_