]> git.saurik.com Git - wxWidgets.git/blob - src/palmos/regconf.cpp
math.h/PI integration
[wxWidgets.git] / src / palmos / regconf.cpp
1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: palmos/regconf.cpp
3 // Purpose:
4 // Author: William Osborne
5 // Modified by:
6 // Created: 10/13/04
7 // RCS-ID: $Id:
8 // Copyright: (c) William Osborne
9 // Licence: wxWindows licence
10 ///////////////////////////////////////////////////////////////////////////////
11
12 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
13 #pragma implementation "regconf.h"
14 #endif
15
16 // For compilers that support precompilation, includes "wx.h".
17 #include "wx/wxprec.h"
18
19 #ifdef __BORLANDC__
20 #pragma hdrstop
21 #endif
22
23 #ifndef WX_PRECOMP
24 #include "wx/string.h"
25 #include "wx/intl.h"
26 #endif //WX_PRECOMP
27
28 #include "wx/event.h"
29 #include "wx/app.h"
30 #include "wx/log.h"
31
32 #if wxUSE_CONFIG
33
34 #include "wx/config.h"
35
36 #include "wx/palmos/registry.h"
37 #include "wx/palmos/regconf.h"
38
39 // ----------------------------------------------------------------------------
40 // constants
41 // ----------------------------------------------------------------------------
42
43 // we put our data in HKLM\SOFTWARE_KEY\appname
44 #define SOFTWARE_KEY wxString(wxT("Software\\"))
45
46 // ----------------------------------------------------------------------------
47 // global functions
48 // ----------------------------------------------------------------------------
49
50 // get the value if the key is opened and it exists
51 bool TryGetValue(const wxRegKey& key, const wxString& str, wxString& strVal)
52 {
53 return false;
54 }
55
56 bool TryGetValue(const wxRegKey& key, const wxString& str, long *plVal)
57 {
58 return false;
59 }
60
61 // ============================================================================
62 // implementation
63 // ============================================================================
64
65 // ----------------------------------------------------------------------------
66 // ctor/dtor
67 // ----------------------------------------------------------------------------
68
69 // create the config object which stores its data under HKCU\vendor\app and, if
70 // style & wxCONFIG_USE_GLOBAL_FILE, under HKLM\vendor\app
71 wxRegConfig::wxRegConfig(const wxString& appName, const wxString& vendorName,
72 const wxString& strLocal, const wxString& strGlobal,
73 long style)
74 : wxConfigBase(appName, vendorName, strLocal, strGlobal, style)
75 {
76 }
77
78 wxRegConfig::~wxRegConfig()
79 {
80 }
81
82 // ----------------------------------------------------------------------------
83 // path management
84 // ----------------------------------------------------------------------------
85
86 void wxRegConfig::SetPath(const wxString& strPath)
87 {
88 }
89
90 // ----------------------------------------------------------------------------
91 // enumeration (works only with current group)
92 // ----------------------------------------------------------------------------
93
94 #define LOCAL_MASK 0x8000
95 #define IS_LOCAL_INDEX(l) (((l) & LOCAL_MASK) != 0)
96
97 bool wxRegConfig::GetFirstGroup(wxString& str, long& lIndex) const
98 {
99 return false;
100 }
101
102 bool wxRegConfig::GetNextGroup(wxString& str, long& lIndex) const
103 {
104 return false;
105 }
106
107 bool wxRegConfig::GetFirstEntry(wxString& str, long& lIndex) const
108 {
109 return false;
110 }
111
112 bool wxRegConfig::GetNextEntry(wxString& str, long& lIndex) const
113 {
114 return false;
115 }
116
117 size_t wxRegConfig::GetNumberOfEntries(bool WXUNUSED(bRecursive)) const
118 {
119 return 0;
120 }
121
122 size_t wxRegConfig::GetNumberOfGroups(bool WXUNUSED(bRecursive)) const
123 {
124 return 0;
125 }
126
127 // ----------------------------------------------------------------------------
128 // tests for existence
129 // ----------------------------------------------------------------------------
130
131 bool wxRegConfig::HasGroup(const wxString& key) const
132 {
133 return false;
134 }
135
136 bool wxRegConfig::HasEntry(const wxString& key) const
137 {
138 return false;
139 }
140
141 wxConfigBase::EntryType wxRegConfig::GetEntryType(const wxString& key) const
142 {
143 return wxConfigBase::Type_Integer;
144 }
145
146 // ----------------------------------------------------------------------------
147 // reading/writing
148 // ----------------------------------------------------------------------------
149
150 bool wxRegConfig::DoReadString(const wxString& key, wxString *pStr) const
151 {
152 return FALSE;
153 }
154
155 // this exactly reproduces the string version above except for ExpandEnvVars(),
156 // we really should avoid this code duplication somehow...
157
158 bool wxRegConfig::DoReadLong(const wxString& key, long *plResult) const
159 {
160 return FALSE;
161 }
162
163 bool wxRegConfig::DoWriteString(const wxString& key, const wxString& szValue)
164 {
165 return false;
166 }
167
168 bool wxRegConfig::DoWriteLong(const wxString& key, long lValue)
169 {
170 return false;
171 }
172
173 // ----------------------------------------------------------------------------
174 // renaming
175 // ----------------------------------------------------------------------------
176
177 bool wxRegConfig::RenameEntry(const wxString& oldName, const wxString& newName)
178 {
179 return false;
180 }
181
182 bool wxRegConfig::RenameGroup(const wxString& oldName, const wxString& newName)
183 {
184 return false;
185 }
186
187 // ----------------------------------------------------------------------------
188 // deleting
189 // ----------------------------------------------------------------------------
190
191 bool wxRegConfig::DeleteEntry(const wxString& value, bool bGroupIfEmptyAlso)
192 {
193 return false;
194 }
195
196 bool wxRegConfig::DeleteGroup(const wxString& key)
197 {
198 return false;
199 }
200
201 bool wxRegConfig::DeleteAll()
202 {
203 return false;
204 }
205
206 #endif
207 // wxUSE_CONFIG