RNA fixes regarding dynamic array properties in functions parameters (reviewed by...
authorBastien Montagne <montagne29@wanadoo.fr>
Mon, 26 Aug 2013 16:08:03 +0000 (16:08 +0000)
committerBastien Montagne <montagne29@wanadoo.fr>
Mon, 26 Aug 2013 16:08:03 +0000 (16:08 +0000)
commitc93750d893e25a9f2ffd98222aa63cc3852f8a37
tree437951b267c83acd04f6aa7e82de64cc00615b99
parentf157753120b0a0cce61f0f4a4f8a24c2cdd7642a
RNA fixes regarding dynamic array properties in functions parameters (reviewed by Brecht, thanks!):

* It was not clear that RNA_parameter_length_get() & co only affected dynamic properties, renamed them to RNA_parameter_dynamic_length_get() and such.

* Fixed RNA_function_find_parameter(), we can't use BLI_findstring() here, need to call RNA_property_identifier()!

* Fixed RNA_parameter_get() and RNA_parameter_set(), which were completely wrong for dynamic properties.

* Fixed RNA_parameter_dynamic_length_get/set_data(), they did not check the property was actually a dynamic one and were using again ugly blackmagic casting intead of ParameterDynAlloc structure!

* makesrna was still using an ugly hackish (and perhaps not always working) code when handling dynamic parameters, now synchronized with RNA_parameter_dynamic_length_get_data and RNA_parameter_get code.
source/blender/makesrna/RNA_access.h
source/blender/makesrna/intern/makesrna.c
source/blender/makesrna/intern/rna_access.c