Fix problems with overlong directory names: phase #1
[mono.git] / mcs / class / corlib / Microsoft.Win32 / ChangeLog
1 2006-10-29  Miguel de Icaza  <miguel@novell.com>
2
3         * UnixRegistryApi.cs (KeyHandler.MachineStore): Add support for
4         loading/storing values from the system registry, instead of having
5         the system ones be user-based. 
6
7         (KeyHandler, Load): turn IO exceptions into Security exceptions.
8
9 2006-09-03  Gert Driesen  <drieseng@users.sourceforge.net>
10
11         * IRegistryApi.cs: Added OpenRemoteBaseKey method.
12         * Win32ResultCode.cs: Added code for win32 error 53.
13         * RegistryKey.cs: Implemented support for OpenRemoteBaseKEy on
14         Windows. To achieve this, the handle of the remote hive must be
15         stored separately from the RegistryHive value. Removed isRoot field, as
16         we now determine whether we're a root key (hive) by checking if hive
17         is not null. Added internal ctor for registry hives that takes a 
18         RegistryHive, a key handle and a bool to indicate whether its a remote
19         hive. Renamed Data field to handle and added internal property to 
20         access it. Throw ObjectDisposedException in ToString if key is
21         closed/disposed. Added Hive property, which is used in UnixRegistryApi.
22         Added GetHiveName method which translates a RegistryHive value to its
23         (key) name.
24         * Win32RegistryApi.cs: Added pinvoke for RegConnectRegistry. GetHandle
25         no longer needs to know whether the key refers to a hive (base key) 
26         or not. Implemented OpenRemoteBaseKey.
27         * UnixRegistryApi.cs: Added OpenRemoteBaseKey implementation which
28         always throws NotImplementedException.
29         * Registry.cs: The key name of the base key no longer needs to be 
30         passed to the ctor, as it's looked up in the ctor itself. This avoids
31         having a different logical for local or remote base keys.
32
33 2006-08-23  Gert Driesen  <drieseng@users.sourceforge.net>
34
35         * Win32RegistryApi.cs: Use a StringBuilder instead of byte [] for
36         RegEnumKey. Fixed issue in GetSubKeyNames where buffer was not cleared
37         while iterating over subkeys.
38
39 2006-08-20  Gert Driesen  <drieseng@users.sourceforge.net>
40
41         * RegistryValueOptions.cs: Add the real one.
42
43 2006-08-20  Atsushi Enomoto  <atsushi@ximian.com>
44
45         * RegistryValueOptions.cs : build fix, easier than reverting all.
46
47 2006-08-20  Gert Driesen  <drieseng@users.sourceforge.net>
48
49         * IRegistryApi.cs: Modified GetValue to take RegistryValueOptions enum
50         and removed obsolete return_default_value argument.
51         * RegistryKey.cs: Added missing ComVisible attribute on SetValue.
52         Use new GetValue method on IRegistryApi that takes RegistryValueOptions
53         enum. Added GetValue overload that takes RegistryValueOptions (2.0).
54         * Win32RegistryApi.cs: Modified GetValue to take RegistryValueOptions
55         enum, and removed obsolete returnDefaultValue argument. Added support
56         for ExpandString value type. Do no expand if DoNotExpand... is set.
57         * UnixRegistryApi.cs: Modified KeyHandler.GetValue to take
58         RegistryValueOptions enum, and do no expand environment variables in
59         an ExpandString if DoNotExpandEnvironmentNames is set. Modified
60         UnixRegistryApi.GetValue to take RegistryValueOptions enum, and 
61         removed obsolete return_default_value argument.
62
63 2006-08-14  Gert Driesen  <drieseng@users.sourceforge.net>
64
65         * UnixRegistryApi.cs: Undo change for new eventlog implementation that
66         was not rolled back earlier this week, and which does not make sense
67         without that implementation anyway.
68
69 2006-08-14  Gert Driesen  <drieseng@users.sourceforge.net>
70
71         * Win32ResultCode.cs: Added error code for attempting to perform an
72         operation on registry key that is marked for deletion.
73         * RegistryKey.cs: Keep writable state. Automatically flush changes to
74         disk when closing key (to match MS). Allow values to be set on root
75         keys. Throw UnauthorizedAccessException when attempting to set/delete
76         value or create/delete sub key on registry key that is openen 
77         read-only. Fixed DecodeString to only strip trailing nullchars (as
78         documented).
79         * Win32RegistryApi.cs: For a key that is marked for deletion, return
80         null when attempting to get a value of that key (and no default value
81         was specified) or open a subkey. Throw an IOException when attempting
82         to perform the following operation on a key that is marked for
83         deletion:
84                 1) set value on key
85                 2) obtain SubKeyCount
86                 3) obtain ValueCount
87                 4) create a sub key
88                 5) obtain value names
89         and ignore deleting a value. Ignore flushing changes of a key and
90         closing a when the key is closed.
91         * UnixRegistryApi.cs: Maintain handler cache per directory instead of
92         caching registry keys. This allows both a single key to be in memory
93         in both read-only and read-write key configuration, while sharing the
94         KeyHandler. Use case-insensitive hashtable for mapping directory to
95         KeyHandler. Added support for keys that have been marked for deletion
96         by another operation (eg. DeleteSubKeyTree). Allow different file store
97         for machine-level and user-level hives (but have them use the same
98         file store, needs further discussion). Allow KeyHandler failure when
99         create directory, or saving values file to bubble up. Do not save
100         values file when key is marked for deletion. Encapsulate access to
101         values collection. When setting value with null name, use zero-length
102         name instead. Treat key name case-insensitive in DeleteKey to match
103         OpenSubKey.
104
105 2006-08-14  Miguel de Icaza  <miguel@novell.com>
106
107         * RegistryValueKind.cs: Make this public in 2.0, and rename from
108         previous version.
109
110         * Win32RegistryApi.cs: Include version to check for version;
111         Eliminate old internal enum, and instead use the new 2.0 enum.
112
113         * UnixRegistryApi.cs: Add support for typed versions of values.
114
115         Add support for ExpandString.
116
117         * Registry.cs (SetValue): implement version with type arguments.
118
119 2006-08-13  Miguel de Icaza  <miguel@novell.com>
120
121         * Registry.cs (SetValue, GetValue): implement.
122
123         * UnixRegistryApi.cs (KeyHandler.LoadKey, KeyHandler.Save): Add
124         support for qwords.
125
126         (KeyHandler.Save): Do not save the entries if they have been
127         deleted/dropped.   Fixes a crash.
128
129         (UnixRegistryApi.DeleteKey): bug fix, call ToUnix on the keyname.
130
131 2006-08-12  Gert Driesen  <drieseng@users.sourceforge.net>
132
133         * Registry.cs: Fixed copy/paste bug.
134
135 2006-08-11  Gert Driesen  <drieseng@users.sourceforge.net>
136
137         * UnixRegistryApi.cs: Consider HKLM\SYSTEM\CurrentControlSet\Services\
138         EventLog a wellknown key. Required for new EventLog implementation. 
139         Added RegistryStore property.
140
141 2006-06-06  Miguel de Icaza  <miguel@novell.com>
142
143         * UnixRegistryApi.cs: Do not crash if there are no values stored.
144
145 2006-05-28  Gert Driesen <drieseng@users.sourceforge.net>
146
147         * UnixRegistryApi.cs: GetSubKeyNames returns only names of subkeys,
148         not the qualified name. Fixes bug #78519.
149
150 2006-04-20  Gert Driesen <drieseng@users.sourceforge.net>
151
152         * UnixRegistryApi.cs: In KeyHandler.SetValue, immediately convert
153         instances of non-native registry types (meaning int, string, string[]
154         or byte[]) to string. This avoids returning an instance of a non-native
155         registry type in calls to UnixRegistryApi.GetValue. Allow instances of
156         non-native registry types in UnixRegistryApi.SetValue. Fixes bug #78132.
157
158 2006-04-18  Gert Driesen <drieseng@users.sourceforge.net>
159
160         * UnixRegistryApi.cs: Only consider the "software" subkey a well-known
161         key if the parent is either HKEY_USERS or HKEY_LOCAL_MACHINE.
162
163 2006-04-15  Robert Jordan <robertj@gmx.net>
164
165         * UnixRegistryApi.cs (DeleteValue): Avoid crash, fixes bug
166         #77772. Patch reapplied, since r57881 was not applied correctly.
167         
168 2006-04-13 Gonzalo Paniagua Javier <gonzalo@ximian.com>
169
170         * UnixRegistryApi.cs: create well-known keys when trying to open them.
171
172 2006-03-12  Robert Jordan <robertj@gmx.net>
173
174         * UnixRegistryApi.cs (DeleteValue): Avoid crash, fixes bug
175         #77772
176
177 2006-01-14  Robert Jordan  <robertj@gmx.net>
178
179         * RegistryKey.cs: Added internal IsRoot accessor.
180         * Win32RegistryApi.cs: Fixed access to RegistryKey.Data.
181         Fixes bug #77212. Thanks to Don Edvalson (don@edvalson.net)
182         for spotting this out.
183
184 2005-12-02  Atsushi Enomoto  <atsushi@ximian.com>
185
186         * Win32RegistryApi.cs : fixed invalid cast. Now mono is not to blame
187           for not being able to run NAnt on Windows.
188         
189 2005-11-12  Miguel de Icaza  <miguel@novell.com>
190
191         * RegistryKey.cs: Add support for a Registry on Unix based on
192         files under ~/.mono/registry.
193
194         Vastly refactored the code, reworked the interface between the
195         frontend and the backends.  
196
197         If "RegistryKey" was not sealed, things could have been a lot
198         cleaner. 
199
200 2005-01-31  mei (mei@work.email.ne.jp)
201
202         * RegistryKey.cs: Fixes bug 70451: When the key doesn't exist, and
203         the default value is not specified, it is necessary to return
204         null. and DecodeString function's bug is fixed.
205
206 2004-04-10  Gert Driesen (driesen@users.sourceforge.net)
207
208         * RegistryKey.cs: explicit implementation of IDisposable to match 
209         MS corlib
210
211 2004-03-17  Jackson Harper  <jackson@ximian.com>
212
213         * Win32RegistryApi.cs: Fix typo. Patch by Gert Driesen.
214
215 2004-03-03  Jackson Harper  <jackson@ximian.com>
216
217         * Win32RegistryApi.cs: Specify entry points.
218         
219 2004-03-03  Jackson Harper <jackson@ximian.com>
220
221         * Win32RegistryApi.cs: New file - pinvokes to the win32
222         registry. Patch  by Erik LeBel.
223         * IRegistryApi.cs: New file - Interface to a registry backend
224         (win32 on windows, no implementation on unix). This interface will
225         probably change when we write a Linux backend.
226         * Win32ResultCode.cs: New file - Win32 result codes needed to
227         check pinvoke. Patch by Erik LeBel.
228         * Registry.cs: Create the keys. Patch by Erik LeBel.
229         * RegistryKey.cs: Implement. Patch by Erik LeBel.
230         
231 2003-12-27  Nick Drochak  <ndrochak@gol.com>
232
233         * RegistryKey.cs: Add some missing overloads.
234
235 2003-02-10  Nick Drochak  <ndrochak@gol.com>
236
237         * Registry.cs: Class should be sealed and have a private default ctor.
238
239 2002-11-28  Alejandro Sánchez Acosta  <raciel@es.gnu.org>
240
241         * Registry.cs: Added missed field.
242
243 2002-11-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
244
245         * RegistryHive.cs: patch from Jackson Harper that fixes compilation.
246
247 2002-11-27  DennisHayes <dennish@raytek.com>    
248
249         * checkin for Alexandre Pigolkine (pigolkine@gmx.de) with minor changes
250         * needed for System.Windows.Forms
251         
252         * RegistryHive.cs
253         * Registry.cs
254         * added files, fully implmented?
255         
256         * RegistryKey.cs
257         * added more iplmentation
258
259 2002-11-20  Nick Drochak  <ndrochak@gol.com>
260
261         * RegistryKey.cs: Fix typo.