SObjectPropertyEntryBox, SAssetProperty and IDetailBuilder

Greetings.
In my saga of trying to get things done in UE 4, I have a need to be able to select a static mesh object via a slate widget as is given all over the Unreal Editor. I have found what are called widget properties to do this.
SObjectPropertyEntryBox and SAssetProperty.

SObjectPropertyEntryBox gives me the ability to select a static mesh as the code snippet below illustrates

SNew(SObjectPropertyEntryBox)
     .OnObjectChanged(this, &MyProject::on_static_mesh_changed)
     .AllowedClass(UStaticMesh::StaticClass())
     .DisplayThumbnail(true)

However, I cannot find out anywhere any documentation or example on what the function on_static_mesh_changed function structure should be. The API for this function seems to return a type void and have an input variable of type const FAssetData &. as follows

void MyProject::on_static_mesh_changed(const FAssetData &static_mesh)

This passes the selected static mesh made from the widgets drop down list to this function, but does not update the selected mesh name in the displayed widget selection tab. So question one, how can I get this widget to update the selected mesh in the drop down widget instead of it remaining None? Also the expected thumbnail image is not displayed, is there something that I am missing in getting a thumbnail image displayed ?

Second question is to do with the SAssetProperty. According to the documentation given by,

there is a SAssetProperty that looks to be the same as the asset selector widgets used in the UE editor. But in all my attempts to get this to work, It seems I need to define a pointer to a created IDetailBuilder class. But I have found once again as in many cases in Unreal engine, I cannot create this pointer by a simple statement like

IDetailBuilder *MyDetailBuilder = new IDetailBuilder;

And I cannot find in all my searches on the net, here in the answer hub or in the source code how to correctly define a pointer to this IDetailBuilder class. So the question is, how does one do this because it is not explained anywhere how this is done ? This is shocking that this is not documented anywhere as it seems to be such a crucial step for building customised panels that are used extensively such as in the Landscape plugin source code I have looked at.

Thanks in advance and much appreciated for any information than can help.

Regards

Editor documentation is very sparse, and editor APIs are even more complex then the engine it self so it’s not really surprising. also i think you mean IDetailLayoutBuilder because i can not find any reference of IDetailBuilder in the code

You missing one important thing, IDetailLayoutBuilder has a I prefix, it means it’s not a object but interface containing class that implements it and can’t be created sperately. And by looking on the code it is just set to the function as argument to respond with construction of detail customization. And ot os interface to either body guard the implementing object or to let use different classes as augments.

As for main question i don’t know, by looking on the code it should just work, maybe you doing something wrong.

Yes I mean’t IDetailLayoutBuilder. When one sees DetailBuilder used as a variable name to in the code every where, it can get burnt into my head that that is the also the class name. When I write my own code I will use the name DetailLayoutBuilder in one form or another so as to know what class my variable refers to as I do in all the code I write when referring variables to class or structure types so it is easy to keep track of what refers to what.

Also what you you said about IDetailLayoutBuilder not being able to be created is something I suspected. I do not really understand at this stage how to set up a plugin application correctly so as to access many of the editor inbuilt features, variables etc like this. I suspect there will be many more and given I have only begun to look at editor plugin creation, there is much more to learn.

I will spend some more time and effort however in part one of my question to get the schematics of this widget to work. As I said, I can select the static mesh as I need and I can use this and continue on.

Thank you.