Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix InlineDictionary Behavior for Single Item Reassignment (#17370)
* Fix InlineDictionary Behavior for Single Item Reassignment Previous Behavior: - When the `Set` method was called, it ignored the `overwrite` parameter if the dictionary contained only one item. - This caused the `Set` method to behave like the `Add` method, leading to unexpected behavior in composition animations. - Specifically, the second composition animation would not play because it could not replace the first animation. Instead, it was added after the first animation, preventing it from being executed. Updated Behavior: - The `InlineDictionary` now respects the `overwrite` parameter even when it contains only one item. - This ensures that the second composition animation can overwrite the first one, allowing it to play correctly. * Append unit test for InlineDictionary * keep the `(TKey)_data` in a variable and reuse it below line 90 so we avoid a double cast * Rename the test method * Remove the unnecessary assignment code.
- Loading branch information