On 6/12/22 4:34 PM, Nikolay Sivov wrote:
On 6/12/22 08:31, Ziqing Hui wrote:
+ if (!wcscmp(name, L"DisplayName") + || !wcscmp(name, L"Author") + || !wcscmp(name, L"Category") + || !wcscmp(name, L"Description")) + { + if (type != D2D1_PROPERTY_TYPE_STRING) + return E_INVALIDARG; + ++reg->system_property_count; + }
That's not going to work for nested properties, that likely can have same names as system ones.
Does "nested properties" means sub properties? If it does, I think it's OK because sub properties is ignored. My plan is to ignore sub properties unless we really need them in effect implementation.
So at least for now add_property() will only be called for top level properties.
+ if (j > entry->property_count) + { + hr = D2DERR_INVALID_PROPERTY; + goto done; + }
Should it be j == entry->property_count ?