Treeview Context Menu to delete node

I have a treeview extension and a context menu that I want to delete the node. I have successfully wired up the context menu, but wondering how I can pass a message to the tree widget to remove the item from the model.

@christesene thank you for the discussion, and welcome to the community!

We have many examples on similar functionality, for example you can take a look how the search-in-workspace dismisses results (the x icon for individual nodes):

The functionality namely gets the instance of the widget, and uses the selection to remove the node. I believe you can achieve something similar.

Thank you very much!