Don't think we'll fix this, it's only good for visible slate widgets to prevent the game from doing stuff. It's possible we should look for some new flag to distinguish those from visible and visible but non-blocking.
Licensee is adding a widget to the viewport overlay via AddViewportWidgetContent(). The widget receives mouse input when hovered. They return unhandled from all their widget's onmouse functions and expect to see ActorBeginCursorOver, ActorEndCursorOver and ActorOnClicked events on the primitive component underneath the pointer.
What they actually see:
1) When bEnableMouseOverEvents=true the cursor over events occur but only when the mouse is clicked. Kind of makes sense that the mouse over doesn't bubble up through something just because it isn't handling stuff. I don't think we handle/unhandle the mouse enter/exit messages.
2) When bEnableMouseOverEvents=true ActorOnClicked is never seen, only the mouse over events. Seems like the ClickedPrimitive in APlayerController::InputKey() is determined differently when bEnableMouseOverEvents is set and it isn't being set when there's a widget in the way.
3) When bEnableMouseOverEvents=false the ActorOnClicked event comes through fine. Its code path in APlayerController::InputKey is different.
Result:
The widget will cover the entire screen and moving the mouse over the BP instance does not show the print string messages for the begin nor end cursor over events. With the mouse hovering over the cube, clicking LMB will print both begin and end messages.
Expected:
When set to unhandled, mouse can interact with both the widget as well as the game world beneath the widget.
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-25033 in the post.
0 |
Component | UE - Editor - UI Systems - Slate |
---|---|
Affects Versions | 4.10 |
Created | Jan 7, 2016 |
---|---|
Resolved | Mar 15, 2016 |
Updated | Jul 14, 2021 |