]> git.saurik.com Git - wxWidgets.git/blame - utils/configtool/src/custompropertydialog.h
Change 'test -e' to 'test -f' for Sun
[wxWidgets.git] / utils / configtool / src / custompropertydialog.h
CommitLineData
d7463f75
JS
1/////////////////////////////////////////////////////////////////////////////
2// Name: custompropertydialog.h
3// Purpose: Custom property dialog
4// Author: Julian Smart
5// Modified by:
6// Created: 2003-06-04
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence:
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _CUSTOMPROPERTYDIALOG_H_
13#define _CUSTOMPROPERTYDIALOG_H_
14
71ada1a5 15#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
f8105809 16#pragma interface "custompropertydialog.cpp"
d7463f75
JS
17#endif
18
19/*!
20 * Includes
21 */
22
23////@begin includes
24////@end includes
25
26/*!
27 * Forward declarations
28 */
29
30////@begin forward declarations
31////@end forward declarations
32
33/*!
34 * Control identifiers
35 */
36
37////@begin control identifiers
38#define ID_CUSTOMPROPERTYDIALOG 10000
d7463f75
JS
39#define ID_PROPERTY_CHOICES 10001
40#define ID_PROPERTY_CHOICE_ADD 10005
41#define ID_PROPERTY_CHOICE_REMOVE 10006
d7463f75
JS
42////@end control identifiers
43
44/*!
45 * ctCustomPropertyDialog class declaration
46 */
47
48class ctCustomPropertyDialog: public wxDialog
49{
50public:
51 /// Constructor
d9ab621e 52 ctCustomPropertyDialog( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& caption = _("Edit Custom Property"));
d7463f75
JS
53
54 /// Creates the controls and sizers
55 void CreateControls();
56
57////@begin ctCustomPropertyDialog event handler declarations
58
59 /// Update event handler for ID_PROPERTY_CHOICES
60 void OnUpdatePropertyChoices( wxUpdateUIEvent& event );
61
62 /// Event handler for ID_PROPERTY_CHOICE_ADD
63 void OnPropertyChoiceAdd( wxCommandEvent& event );
64
65 /// Update event handler for ID_PROPERTY_CHOICE_ADD
66 void OnUpdatePropertyChoiceAdd( wxUpdateUIEvent& event );
67
68 /// Event handler for ID_PROPERTY_CHOICE_REMOVE
69 void OnPropertyChoiceRemove( wxCommandEvent& event );
70
71 /// Update event handler for ID_PROPERTY_CHOICE_REMOVE
72 void OnUpdatePropertyChoiceRemove( wxUpdateUIEvent& event );
73
74////@end ctCustomPropertyDialog event handler declarations
75
76////@begin ctCustomPropertyDialog member function declarations
77
78////@end ctCustomPropertyDialog member function declarations
79
80 /// Should we show tooltips?
81 static bool ShowToolTips();
82
83 void SetPropertyName(const wxString& name) { m_name = name; }
84 wxString GetPropertyName() { return m_name; }
85
86 void SetPropertyType(const wxString& type) { m_type = type; }
87 wxString GetPropertyType() { return m_type; }
88
89 void SetEditorType(const wxString& type) { m_editorType = type; }
90 wxString GetEditorType() { return m_editorType; }
91
92 void SetPropertyDescription(const wxString& descr) { m_description = descr; }
93 wxString GetPropertyDescription() { return m_description; }
94
95 void SetChoices(const wxArrayString& choices) ;
96 wxArrayString GetChoices() { return m_choices; }
97
98 DECLARE_CLASS( ctCustomPropertyDialog )
99 DECLARE_EVENT_TABLE()
100
d9ab621e
WS
101protected:
102 wxString m_name;
103 wxString m_type;
104 wxString m_description;
105 wxString m_editorType;
d7463f75 106 wxArrayString m_choices;
d9ab621e
WS
107
108 // Dialog controls
109 wxTextCtrl* m_customPropertyName;
110 wxTextCtrl* m_customPropertyDescription;
111 wxChoice* m_customPrototype;
112 wxChoice* m_customPropertyEditorType;
113 wxListBox* m_propertyChoices;
d7463f75
JS
114};
115
116#endif
117 // _CUSTOMPROPERTYDIALOG_H_