I have a navigation type app that I'm working on that uses a vertical menu, but I need users to be able to edit/delete menu items. If I add a context menu, it works at the top level (it's always visible), but on the submenus, if I right click to open the context menu, the submenu automatically hides. I still have a reference to the item so the context menu works, but visually it is difficult for the user to track where they were at. Is there a way to override this behavior?
Hello Scott,
I am just checking you need any further assistance on the matter.
I was able to reproduce this behavior and I can say that the first submenu stays open when the context menu is open due to the ExpandOnHover set to false. Because the Popup’s StaysOpen Property is true. Since this property is controlled by code, currently you are not able to set it to be true on the submenus on other levels when the context menu is open, so I can suggest you log a new product idea (ExpandOnHover Property for XamMenuItem element) for future versions (or vote for existing ones) at http://ideas.infragistics.com.
There are many benefits to submitting an product idea:
- Direct communication with our product management team regarding your product idea.
- Notifications whenever new information regarding your idea becomes available.
- Ability to vote on your favorite product ideas to let us know which ones are the most important to you. You will have ten votes for this and can change which ideas you are voting for at any time.
- Allow you to shape the future of our products by requesting new controls and products altogether.
- You and other developers can discuss existing product ideas with members of our Product Management team.
Steps to create your idea:
The Product Idea site puts you in the driver’s seat and allows you to track the progress of your ideas at any time, see how many votes it got, read comments from other developers in the community, and see if someone from the product team has additional questions for you.
If you set the ExpandOnHover="false" on your main menu then go out to a 3 deep menu, it only closes the menu that your on, leaving the second level menu displayed on the screen, so I'm not sure that it's only possible to have 1 popup at a time. Can you take another look to see if there are any other settings that may affect this behavior?
I have been looking into your sample and I can say that in WPF you can only have one opened Popup at a time and since the XamMenu's SubItems are in a Popup and the XamContextMenu is Popup the functionality you want cannot be achieved. Please let me know if you have further questions on this matter.
Looking forward for your reply.
I've attached a zip file with a sample app that I was using to test.
to recreate the issue, run the app, then expand out one of the submenus and then right mouse click an item. the context menu comes up and the menu collapses.