2010-07-05 Carlos Alberto Cortez <calberto.cortez@gmail.com>
[mono.git] / mcs / class / corlib / System.Resources / ChangeLog
1 2010-07-05  Carlos Alberto Cortez <calberto.cortez@gmail.com>
2
3         * ResourceWriter.cs: Implement 4.0 AddResource overloads taking a
4         Stream, as well as implement the same support in our AddResource that
5         takes an object too.
6
7 2010-03-16  Jb Evain  <jbevain@novell.com>
8
9         * ResourceManager.cs: use MOONLIGHT symbol to disambiguate
10         MonoTouch and Moonlight code.
11
12 2010-03-01  Miguel de Icaza  <miguel@novell.com>
13
14         * Win32Resources.cs: Prevent infinite loops if the resource that
15         we are reading is invalid.   Fixes the mscorlib part of #327500
16
17 2009-11-01  Sebastien Pouliot  <sebastien@ximian.com>
18
19         * ResourceManager.cs (GetResourceFilePath): Don't use 
20         'resourceDir' which should always be null for Moonlight
21
22 2009-10-19  Jb Evain  <jbevain@novell.com>
23
24         * ResourceReader.cs: fix the build.
25
26 2009-10-18  Sebastien Pouliot  <sebastien@ximian.com>
27
28         * ResourceReader.cs, ResourceSet.cs, RuntimeResourceSet.cs: Use 
29         UnmanagedMemoryStream (instead of IntPtrStream)
30
31 2009-04-16  Geoff Norton  <gnorton@novell.com>
32
33         * ResourceWriter.cs: The magic internal type here is required to match
34         Microsofts for SL2 resource deserialization.
35
36 2009-03-06 Gonzalo Paniagua Javier <gonzalo@novell.com>
37
38         * ResourceSet.cs: for custom resource sets without a reader, pretende
39         that's we've already read the stream.
40
41 2009-02-27 Gonzalo Paniagua Javier <gonzalo@novell.com>
42
43         * ResourceSet.cs: populating the resource should be locked because the
44         resourceset could be shared.
45
46 2009-01-24 Gonzalo Paniagua Javier <gonzalo@novell.com>
47
48         * ResourceManager.cs: don't throw every time we try to load a resource
49         satellite assembly that does not exist.
50
51 2008-12-22 Gonzalo Paniagua Javier <gonzalo@novell.com>
52
53         * ResourceManager.cs: cache negative results too.
54
55 2008-12-18 Gonzalo Paniagua Javier <gonzalo@novell.com>
56
57         * ResourceManager.cs: avoid duplication of keys if more than one
58         thread is creating the ResourceSet.
59
60 2008-12-17 Gonzalo Paniagua Javier <gonzalo@novell.com>
61
62         * ResourceManager.cs: cache ResourceSets instead of loading them from
63         their assembly every time they are needed.
64
65 2008-08-11  Larry Ewing  <lewing@novell.com>
66
67         * ResourceReader.cs: fix reading/writing beyond the end of the
68         current resource when the resource is larger than 1024 bytes.
69
70 2008-06-30  Marek Safar  <marek.safar@gmail.com>
71
72         * ResourceReader.cs: Cache resources enumerator in ResourceReader.
73
74 2008-06-30  Marek Safar  <marek.safar@gmail.com>
75
76         * ResourceReader.cs: Sealed ResourceEnumerator.
77
78 2008-06-28  Rodrigo Kumpera  <rkumpera@novell.com>
79
80         * ResourceReader.cs (LoadResourceValues): Kill ununsed local.
81
82         * ResourceReader.cs (CreateResourceInfo): Don't return a big
83         struct on stack, pass it as a reference argument.
84
85 2008-06-27  Rodrigo Kumpera  <rkumpera@novell.com>
86
87         * ResourceReader.cs: Avoid an extra array copy for the resource arrays.
88
89 2008-06-27  Zoltan Varga  <vargaz@gmail.com>
90
91         * ResourceManager.cs: Add a negative cache for culture->resource set mappings
92         which caches lookup failures.
93
94         * ResourceSet.cs (GetObjectInternal): Search the hash table in the ignoreCase
95         case too.
96
97 2008-06-27  Andreas Nahr <ClassDevelopment@A-SoftTech.com>
98
99         * MissingManifestResourceException.cs:
100         * MissingSatelliteAssemblyException.cs:
101         * ResourceManager.cs: Fix parameter names
102
103 2008-05-27  Marek Habersack  <mhabersack@novell.com>
104
105         * ResourceReader.cs: reimplement the way resources are read when
106         enumerator is used. The resource indexes and names are read in
107         ReadHeaders when ResourceReader is created and the resource values
108         are read and cached when the enumerator is created. This removed a
109         lot of unnecessary locking and made the whole process more
110         efficient and faster (a test application would acquire the locks
111         40000 times durng a 1.7s run, right now it acquires the lock 1
112         time).
113
114 2008-05-08  Miguel de Icaza  <miguel@novell.com>
115
116         * ResourceSet.cs: Pass the ignoreCase argument, needed to
117         implement ResourceManager.IgnoreCase.
118
119         Silverlight 2.0 applications store "page.xaml" as the key in the
120         resource keys, but request Page.xaml ones.
121
122         * ResourceManager.cs: Avoid exception throwing and catching.
123
124         * RutimeResourceSet.cs: Add a constructor that is required to
125         deserialize Silverlight 2.0 applications when deserializing the
126         resources that contains the XAML files in assemblies.
127
128         We do not take advantage of this new constructor that uses an
129         IntPtrStream, instead we stick to the Stream API.
130
131 2008-03-29  Gert Driesen  <drieseng@users.sourceforge.net>
132
133         * Win32Resources.cs: On 2.0 profile, initiale fixed info to zero-length
134         string when emitting versioninfo in compiler context. Default to
135         neutral language in compiler context. On 1.0 profile, use 0xffff as
136         default value for version parts. In Version, abort on first invalid
137         version part and also set FileVersion string. In ProductVersion and
138         FileVersion, parse version string and abort on first invalid version
139         part.  
140
141 2008-03-15  Gert Driesen  <drieseng@users.sourceforge.net>
142
143         * ResourceManager.cs: Default to RuntimeResourceSet for all ctors.
144         * ResourceSet.cs: Avoid duplicate argument checks. On 2.0 profile,
145         throw ObjectDisposedException when ResourceSet is disposed.
146         * RuntimeResourceSet.cs: On 2.0 profile, throw ObjectDisposedException
147         when ResourceSet is disposed.
148
149 2008-03-04  Sebastien Pouliot  <sebastien@ximian.com>
150
151         * ResourceManager.cs: Use RuntimeResourceSet, an internal type, just
152         like MS does (and tell us indirectly with a Type property).
153         * ResourceSet.cs: Fix a few problems found with new unit tests. Also
154         fix some exception parameters.
155         * RuntimeResourceSet.cs: New. Internal type used by ResourceManager.
156         ResouceSet cannot be used, as is, because it does not clone objects,
157         when possible, leading to problems when those objects are disposed.
158
159 2008-01-26  Gert Driesen  <drieseng@users.sourceforge.net>
160
161         * ResourceWriter.cs: On 2.0 profile, do not mistakenly identify an
162         enum as a predefined type. Fixes bug #325223.
163
164 2007-11-10  Gert Driesen  <drieseng@users.sourceforge.net>
165
166         * ResourceWriter.cs: On 2.0 profile, use case-insensitive SortedList.
167         Changed exception messages and params to match MS. Allow null values
168         in AddResource overloads. In Dispose (bool), also generate resources
169         (header) if no resources were added. Fixes bug #339074. When Generate
170         is done, reset resources to null to prevent further editing.  This
171         also avoids the need for a separate bool to indicate whether generate
172         was already invoked. Code formatting.
173
174 2007-10-27  Gert Driesen  <drieseng@users.sourceforge.net>
175
176         * ResourceManager.cs: Removed temporary workaround for bug #43567.
177         Reworked basename to only throw ArgumentException if resource with
178         name ending on ".resources" does not actually exist. Fixes bug
179         #336283. Do not throw exception in GetStream since this is already
180         done in InternalGetResourceSet. In InternalGetResourceSet, do not
181         throw MissingManifestResourceException when culture is null. Fixed
182         MissingManifestResourceException message to match MS. When using
183         file-based ResourceManager, then also throw an exception when file
184         does not exist for neutral culture.
185
186 2007-09-17  Gert Driesen  <drieseng@users.sourceforge.net>
187
188         * ResourceManager.cs: Move code for determining manifest resource
189         name into separate method. Only use satellite assemblies for
190         non-invariant cultures. For invariant culture, only load resources
191         from main assembly.
192
193 2007-09-17  Gert Driesen  <drieseng@users.sourceforge.net>
194
195         * ResourceManager.cs: BaseName(Field) should return only the name.
196         Added resourceSource field to store the actual type, which we need for
197         the namespace. Added CheckBaseName method to avoid code duplication.
198         Only check whether basename does not end in '.resources' on 1.0
199         profile. Fixed paramname of ArgumentNullExceptions to match MS.
200         Modified GetManifestResourceStreamNoCase to use resourceSource field
201         to construct manifest resource name. Modified GetStream to use
202         CurrentUICulture when culture is null. Fixed InternalGetResourceSet
203         to use invariant resources when culture is the neutral culture.
204         Code formatting.
205 >
206 2007-08-24  Gert Driesen  <drieseng@users.sourceforge.net>
207
208         * ResourceReader.cs: Fixed exception message to match MS. Removed
209         duplicate checks from string ctor.
210
211 2007-08-09  Atsushi Enomoto  <atsushi@ximian.com>
212
213         * ResourceReader.cs : implemented GetResourceData(). Resources with
214           unresolvable types could still be parsed, so hold type names
215           instead of types.
216
217 2007-07-16  Rodrigo Kumpera  <rkumpera@novell.com>
218
219         * ResourceReader.cs (ResourceValue): Put the null resource check
220           before the resource version 2 check, this fixes bug #81757
221
222 2007-05-28  Atsushi Enomoto  <atsushi@ximian.com>
223
224         * ResourceWriter.cs : fix for runtime serialization type index.
225           Fixed bug #81759.
226
227 2007-05-28  Atsushi Enomoto  <atsushi@ximian.com>
228
229         * ResourceWriter.cs : temporarily disable 2.0 output until I get
230           bug #81759 fixed.
231
232 2007-05-28  Atsushi Enomoto  <atsushi@ximian.com>
233
234         * IResourceWriter.cs NeutralResourcesLanguageAttribute.cs
235           SatelliteContractVersionAttribute.cs ResourceManager.cs
236           IResourceReader.cs ResourceSet.cs ResourceWriter.cs
237           ResourceReader.cs UltimateResourceFallbackLocation.cs
238           MissingManifestResourceException.cs :
239           implemented 2.0 resource support (write, and remaining read bits)
240           and GetStream(). Cosmetic attributes fixes.
241
242 2007-05-25  Atsushi Enomoto  <atsushi@ximian.com>
243
244         * MissingSatelliteAssemblyException.cs : new file.
245
246 2007-02-16  Gert Driesen  <drieseng@users.sourceforge.net>
247
248         * ResourceReader.cs: Fixed typo.
249
250 2006-12-30  Alexander Olk  <alex.olk@googlemail.com>
251
252         * ResourceManager.cs: Don't create the ResourceSets hashtable in the
253         protected ctor, instead move it to the public ctors. Fixes some not
254         working nunit tests. Also, return a closed ResourceSet instead of
255         creating a new one. Fixes one more test. If only BaseNameField is
256         provided, try to create a resource set from the BaseNameField. One
257         more test that passes now.
258         * ResourceSet.cs: Remove isDisposed. Not needed anymore.
259
260 2006-12-30  Alexander Olk  <alex.olk@googlemail.com>
261
262         * ResourceManager.cs: Iterate through the values of the ResourceSets
263         hashtable in ReleaseAllResources instead through the hashtable itself.
264
265 2006-12-30  Gert Driesen  <drieseng@users.sourceforge.net>
266
267         * ResourceReader.cs: Support reading byte arrays in v2 resource files.
268         Patch provided by Red Forks. Fixes bug #79976.
269
270 2006-10-29  Alexander Olk  <alex.olk@googlemail.com>
271
272         * ResourceSet.cs, ResourceManager.cs: Calling ResourceSet.Close()
273           disposes a resource set. A closed resource set will now be
274           removed from ResourceSets. Fixes bug #79182.
275
276 2006-03-14  Robert Jordan  <robertj@gmx.net>
277
278         * ResourceManager.cs: Don't stop the resource set lookup until
279         the invariant culture is reached. Fixes bug #77242.
280
281 2005-11-19  Zoltan Varga  <vargaz@gmail.com>
282
283         * Win32Resources.cs: Add a new 'FileVersion' property.
284
285 2005-07-25  Marek Safar  <marek.safar@seznam.cz>
286
287         *  ResourceReader.cs: Implemented reading of primitives for version 2.
288
289 2005-03-31  Sebastien Pouliot  <sebastien@ximian.com>
290
291         *  ResourceReader.cs, ResourceSet.cs: Added a LinkDemand for 
292         SerializationFormatter when using a Stream constructor (other ctors
293         have different security - e.g. FileIOPermission for opening a file).
294
295 2005-03-22 Gonzalo Paniagua Javier <gonzalo@ximian.com>
296
297         * ResourceManager.cs: use culture.Equals in InternalGetResourceSet().
298
299 2005-02-12  Geoff Norton  <gnorton@customerdna.com>
300
301         * ResourceReader.cs: If a resource type index is -1 return null 
302         instead of throwing an exception
303         * ResourceWriter.cs: If an object is null; encode it with type index
304         -1 instead of throwing an exception.
305         
306 2005-02-11  Zoltan Varga  <vargaz@freemail.hu>
307
308         * Win32Resources.cs: Fix warning.
309
310 2004-12-06  Ben Maurer  <bmaurer@ximian.com>
311
312         * ResourceManager.cs (InternalResourceManager): on msft, they
313         search for a case-insenstitive match too here.
314
315 2004-05-02  Sebastien Pouliot  <sebastien@ximian.com>
316
317         * ResourceManager.cs: Avoid endless recursion when a resource file
318         isn't found.
319
320 2004-04-08  Lluis Sanchez <lluis@ximian.com>
321
322         * ResourceSet.cs: Added minor null check.
323
324 2004-02-03  Jackson Harper <jackson@ximian.com>
325
326         * ResourceSet.cs: Do not throw an exception for null strings.
327         
328 2004-01-13  Zoltan Varga  <vargaz@freemail.hu>
329
330         * Win32Resources.cs (Win32VersionInfoResource): Add more properties.
331
332 2004-01-09  Zoltan Varga  <vargaz@freemail.hu>
333
334         * Win32Resources.cs (Win32VersionInfoResource:WriteTo): Add padding
335         at the end of each string entry.
336
337         * Win32Resources.cs: Fix warnings not detected by mcs.
338
339 2004-01-08  Zoltan Varga  <vargaz@freemail.hu>
340
341         * Win32Resources.cs: Organize win32 resources into a class hierarchy
342         with the class Win32Resource as the abstract superclass. Add 
343         Win32ResFileReader and Win32IconFileReader classes and the 
344         corresponding resource types.
345
346         * Win32Resources.cs (Win32VersionInfoResource): Fix version number 
347         calculation. Add Language property.
348
349 2004-01-05  Zoltan Varga  <vargaz@freemail.hu>
350
351         * Win32Resources.cs: New file.
352
353         * Win32Resources.cs: The value of properties can't be empty.
354
355         * Win32Resources.cs: Add Win32ResourceType enumeration. Add accessors
356         for well-known property names. Add missing namespace declaration.
357
358 2003-12-17  Zoltan Varga  <vargaz@freemail.hu>
359
360         * ResourceWriter.cs (Stream): New internal property used by Ref.Emit.
361
362 2003-11-28  Dick Porter  <dick@ximian.com>
363
364         * ResourceSet.cs: Do string compares with the Invariant culture.
365
366 2003-11-18  Andreas Nahr <ClassDevelopment@A-SoftTech.com>
367
368         * ResourceSet.cs: Implemented v1.1 updates
369
370 2003-09-07  Dick Porter  <dick@ximian.com>
371
372         * Temporary workaround for bug 43567, so that Npgsql at least
373         can run.
374
375 2003-05-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
376
377         * ResourceManager.cs: fixed infinite loop when the resource is not
378         found. Also fixes bug #34196.
379
380 2003-05-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
381
382         * ResourceManager.cs: enabled the code that calls GetSatelliteAssembly
383         and ignore the exception thrown if the assembly cannot be loaded.
384
385 2003-05-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
386
387         * ResourceManager.cs: fixed the name for the file when the culture is
388         not de invariant culture. Commented out the GetSatelliteAssembly code
389         to avoid NotImplementedException being thrown.
390
391 2002-08-19  Dick Porter  <dick@ximian.com>
392
393         * ResourceWriter.cs: Implemented all methods
394
395         * ResourceReader.cs: Cope with our ResourceSet class name, as well
396         as theirs
397
398 2002-08-18  Dick Porter  <dick@ximian.com>
399
400         * ResourceReader.cs: Finished basic implementation.  Some
401         optimisation in conjunction with ResourceSet still possible though
402
403 2002-08-14  Dick Porter  <dick@ximian.com>
404
405         * ResourceSet.cs: Throw the correct exceptions
406
407         * ResourceManager.cs: Implemented all unfinished methods
408
409 2002-03-12  Duncan Mak  <duncan@ximian.com>
410
411         * MissingManifestResourceException.cs: This should inherit from
412         SystemException, not Exception.
413
414 2002-01-26  Nick Drochak  <ndrochak@gol.com>
415
416         * ResourceReader.cs: Finsished reading resource files with just strings
417         in them.  Need to figure out other types, and also resources with
418         multiple types in the same file.
419
420 2002-01-24  Nick Drochak  <ndrochak@gol.com>
421
422         * ResourceReader.cs: Implemented constructors. Started on the 
423         GetEnumerator() method.  Not done yet, but comitting for 
424         'disaster recovery' purposes.
425
426 2002-01-19  Duncan Mak  <duncan@ximian.com>
427
428         * *.cs: Fixed indentation. There was a stupid bug in my .emacs file.
429
430 2002-1-17  Duncan Mak  <duncan@duncan@ximian.com>
431
432         * ResourceSet.cs: Implemented GetObject (string, bool) and GetString
433         (string, bool). ResourceSet has no more MonoTODOs! Also added in the
434         Serializable attribute.
435         
436         * *.cs: convert to Miguel's brace style.
437
438 2002-01-17  Duncan Mak  <duncan@ximian.com>
439
440         * ResourceManager.cs: Fixed GetNeutralResourcesLanguage () and added
441         new attributes documented in 1.0 SDK.
442
443 2002-01-17  Duncan Mak  <duncan@ximian.com>
444
445         * ResourceWriter.cs: Added MonoTODO decorations.
446
447         * SatelliteContractVersionAttribute.cs: added new attributes in 1.0 SDK.
448
449         * NeutralResoucesLanguageAttribute.cs: added new attributes in 1.0 SDK
450         
451 2002-01-16  Duncan Mak  <duncan@ximian.com>
452
453         * ResourceReader.cs: Fixed some typos.
454
455         * ResourceManager.cs: After reading the tutorial from the SDK,
456         finished all the ResourceManager constructors and removed those
457         MonoTODO tags.
458         
459         Removed MonoTODO from GetNeutralResourcesLanguage (Assembly)
460         because Miguel just implemented the whole class, including the
461         constructor that I needed (CultureInfo (string)).
462
463         Updated fields after reading the new docs from the final SDK.
464
465         * ResXFileRef.cs, ResXResourceReader.cs: Removed. They are part of
466         Windows.Forms and require System.Xml, which we don't have access to.
467
468 2002-01-13  Duncan Mak  <duncan@ximian.com>
469
470         * ResourceManager.cs: Added more MonoTODOs and cleaned up some 
471         indenting.
472
473 2002-01-09  Duncan Mak  <duncan@ximian.com>
474
475         * ResourceManager.cs: Fixed the GetSatelliteContractVersion()
476         method. It was missing a cast before. Removed MonoTODO
477         attribute. ;-) It was tested by John Barnette, so this shouldn't break
478         the build.
479
480         * ResourceManager.cs: Removed MonoTODO attribute on GetString
481         (string), as I believe it's correct. However, GetString
482         (string, CultureInfo) is definitely broken, so I'm marking it with
483         MonoTODO there. I also added MonoTODO to IntenalGetResourceSet().
484
485 2002-01-06  Duco Fijma <duco@lorentz.xs4all.nl>
486         * Finalizing IResourceReader and IResourceWriter interfaces: 
487           Added "new"-modifier to IResourceReader.GetEnumerator
488         * Fixed compilation issues in other *.cs, so that the 
489           System.Resources namespaces can be included in the corlib build.
490
491 2002-01-05  Ravi Pratap  <ravi@ximian.com>
492
493         * ResourceManager.cs : MonoTODO attribute decoration.
494         
495 Tue Dec 18 13:18:32 CET 2001 Paolo Molaro <lupus@ximian.com>
496
497         * *.cs: fixed some of the compilation issues: missing
498         using directives, typos.
499
500 2001-12-11  Duncan Mak  <duncan@ximian.com>
501
502         * Checked in to CVS.
503
504 2001-12-10  Duncan Mak  <duncan@ximian.com>
505
506         * ResourceManager.cs (GetNeutralResourcesLanguage):
507         (GetSatelliteContractVersion): Implemented.
508         
509 2001-12-09  Duncan Mak  <duncan@ximian.com>
510
511         * ResXResourceReader.cs: Initial attempt.
512
513         * ResXFileRef.cs: Initial attempt.
514
515         * ResourceWriter.cs: Initial attempt.
516
517         * ResourceSet.cs (ReadResources): Implemented, with help from Radek Doulik.
518
519 2001-11-28  Duncan Mak <duncan@ximian.com>      
520
521         * ResourceManager.cs: First attempt.
522
523 2001-11-27  Duncan Mak <duncan@ximian.com>
524
525         * ResourceSet.cs:
526         First attempt, can't continue until ResourceReader and ResourceWriter are implemented.
527                 
528         * SatelliteContractVersionAttribute.cs: First attempt. The spec is quite amibiguous here.
529
530         * NeutralResoucesLanguageAttribute.cs: Complete.
531
532         * MissingManifestResourceException.cs: Complete.
533
534         * IResourceReader.cs: Complete.
535
536         * IResourceWriter.cs: Complete.