Custom slate element delegate

I’ve made a custom Slate widget that’s got some complex behavior, wrapped in a (very simple) UMG widget. I want to create a delegate that can send an int from the Slate widget to UMG on a mouse event. I’ve seen SLATE_EVENT macros before but I can’t really find any documentation (or even if that’s the right thing to do). I’ve been using UObject dynamic delegates throughout the project but SWidget isn’t derived from UObject.

I’d prefer to have mouse events handled by the Slate widget as they are unique to the widget and the SWidget may be decoupled at some point.

Thanks!

Figured it out - should’ve looked into more engine code.

Original code:

Widget
.OnSelected(this, &Class::DOnStarSelect);

Fixed:

Widget
.OnSelected(BIND_UOBJECT_DELEGATE(DelegateType, DOnStarSelect));