Got it!
Your header:
class YourClass {
....
UFUNCTION()
void on_selection_changed(UObject *n_object);
}
In your impl:
GEditor->GetSelectedSet(AActor::StaticClass())->SelectObjectEvent.AddRaw(this, &YourClass::on_selection_changed);
Function will be called when user selects an actor.
Cheers and sorry for the noise…
Stephan