pub unsafe extern "C" fn SDL_SetPointerPropertyWithCleanup(
props: SDL_PropertiesID,
name: *const c_char,
value: *mut c_void,
cleanup: SDL_CleanupPropertyCallback,
userdata: *mut c_void,
) -> boolExpand description
Set a pointer property in a group of properties with a cleanup function that is called when the property is deleted.
The cleanup function is also called if setting the property fails for any reason.
For simply setting basic data types, like numbers, bools, or strings, use SDL_SetNumberProperty, SDL_SetBooleanProperty, or SDL_SetStringProperty instead, as those functions will handle cleanup on your behalf. This function is only for more complex, custom data.
Parameter: props the properties to modify. Parameter: name the name of the property to modify. Parameter: value the new value of the property, or NULL to delete the property. Parameter: cleanup the function to call when this property is deleted, or NULL if no cleanup is necessary. Parameter: userdata a pointer that is passed to the cleanup function. Returns: true on success or false on failure; call SDL_GetError() for more information.
Thread Safety: It is safe to call this function from any thread.
Available Since: This function is available since SDL 3.2.0.
See Also: SDL_GetPointerProperty See Also: SDL_SetPointerProperty See Also: SDL_CleanupPropertyCallback