MenuFlyout

As the preceding chapter pointed out, both Flyout and MenuFlyout derive from FlyoutBase. Rather than a Content property, MenuFlyout has an Items property. However, unlike items controls, this Items property is a collection of MenuFlyoutItemBase controls. Therefore, you can only put the following types of built-in controls inside a MenuFlyout:

MenuFlyoutItem—Looks like a standard menu item and acts like a Button. Like Button, it has a Click event and Command/CommandParameter properties for supporting the loosely-coupled commanding pattern. It is not able to host generic content, however. Instead, its content property is a string property called Text.

ToggleMenuFlyoutItem—Derives from MenuFlyoutItem and adds an IsChecked property. ...

Get Universal Windows® Apps with XAML and C# Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.