Description

If multiple game objects are selected at once and their text field is edited, instead of getting N events, it produces N-squared events.

It looks like FPropertyHandleBase::SetPerObjectValue is calling FPropertyValueImpl::ImportText once per updated field, as expected, and that in turn is tripping FPropertyNode::NotifyPostChange once per item as well. However, inside FPropertyNode::NotifyPostChange, when it collects the affected weak objects, it acquires the full original set modified objects and fires an event for each of them instead of only for the target which was just modified, which results in a total of N-squared events firing.

Steps to Reproduce
  • Hook to the FCoreUObjectDelegates::OnObjectPropertyChanged event
  • Modify text on game objects
  • Observe the number of times your event handler method fires, and notice it is more than intended

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-189758 in the post.

1
Login to Vote

Backlogged
ComponentUE - Editor
Affects Versions5.15.2
CreatedJun 28, 2023
UpdatedJan 24, 2024
View Jira Issue