I'll first explain a bit what I'm doing so that the code paste will make a bit more sense. I'm creating a circular menu control for Microsoft Surface (this question is far from Surface specific though, but otherwise this type of control wouldn't make sense
:) ), it has some 'pieces' which are all buttons. I've created a 'Menu' control which contains the menu items, I made a custom control for these items (so I could add them to the menu within XAML), and I made a Button control which actually does the drawing
of the path etc. I've done this in this specific way because the angle of the button's path will depend on the number of pieces within the menu. Anyway the above all works fine and dandy and I'm happy with the result. However now I'm trying to get all of this
What I want to do is to use MVVM in my application and bind the MenuItems to a command in my ViewModel. So I have an AdminToolbox which is a view containing the menu and there's an AdminToolboxViewModel which is the ViewModel with the command and the items
that I'd need to bind to my menu to create the menu items.
Some code pastes:
View Complete Post