Hello,
I’m having some issues with a custom EdModeToolkit Slate editor plugin, each time I interact with the UI the viewport does not update immediately. The OnValueChanged callback is connected to a method that deforms the selected mesh.
- SAssignNew(Slider, SSpinBox<float>)
- .PreventThrottling(true)
- .OnValueChanged(this, &FCustomEdModeToolkit::SpinTestHandler)
The interaction seems slow and laggy. When I put the same method in the OnConstruction construction script override of the actor it self it does update right away without any lags. (Changing UPROPERTY directly on the actor)
I have tried the following:
Refresh issue?
- Change the ‘PreventThrotteling’ setting in the Spinbox to make sure that the viewport refreshes on each value change.
- Force refresh the viewport using FEditorViewportClient and Invalidating the current viewport. Similar issue: How to refresh Viewport when dragging a spinbox (FModeToolkit)? - Pipeline & Plugins - Unreal Engine Forums
Focus issue?
- Tried to change the selection state in the viewport by selecting the same actor again to trick the focus of viewport.
- Tried to call GetEditorMode()->ReceivedFocus() to focus on the current viewport client
Any ideas?
Issue also occurs in 4.22.