I have UMG widget with draggable item. If I add it to viewport it work correctly. But if it added to Widget Component it not work.
Debug cursor react on hovering widget (red spot becomes larger) but widget element not react on drag event.
Is Widget Component has any “hidden” options to activate drag events?
UMG element is Text Box in Border element. I can print text in Text Box if it on Widget Component but cant drag wrap border.
On viewport all work correct.
You will need to post some screenshots if we are to be able to track down the issue.
Most relevant I think would be:
designer window, including hierarchy, of the umg widget, draggable item and the widget you add it to.
Also how you detect the drag and the drag drop operation.
Sorry, I did not realize this was for widget components, something I have not begun to learn yet.
However, messing around with it a bit, when you click the “add component” and search for widget, there’s this widget interaction component, and it says “… you’ll then tell the component to simulate key presses…”.
So I guess using on mouse button down, which works on a widget added to the view port, does not work with the widget component. So you need to use this widget interaction component for that.
The widget interaction component has an event called “onhoveredwidgetchanged” so that you can get a reference to the hovered widget.
And here’s some links but maybe you already read through them.
Hurray!
It work if call functions from draggable widget. I bind these functions to mouse events via WidgetInteractionComponent and it worked.
But now I need to create a new algorithm for calculating the coordinates but that math only =)