[Interest] Dynamic QML menu from C++ data?

Murphy, Sean smurphy at walbro.com
Mon Aug 28 18:27:39 CEST 2017


I'd think this is a pretty easy thing to do, but I'm struggling to find an example that shows it. In my QML, I have a button. When the button is clicked, a popup menu should open. That part I have working, what I'm struggling with is I need to be able to dynamically populate the popup menu from the C++ side, and then get which menu item was clicked on back to the C++ side. 

I'm struggling to find just a simple example of how to do this. Does anyone have a quick link to something like that?

Sean



More information about the Interest mailing list