Overview
This topic covers the specific events exposed by the RadMenu control.
The RadMenu is an ItemsControl. Almost all of the exposed events are inherited from the ItemsControl class. The RadMenu and the RadMenuItem add several additional events for the developers.
The RadMenu control raises the following specific event:
-
ItemClick - occurs each time an item in the RadMenu gets clicked. The event handler receives two arguments:
The sender argument contains the RadMenu. This argument is of type object, but can be cast to the RadMenu type.
A RadRoutedEventArgs object.
By default this event won't fire for items that contain child menu items. You can change this behavior by setting the NotifyOnHeaderClick property of the RadMenu to True.
The ItemClick event is fired after the Click event of the clicked RadMenuItem.
The RadMenuItem raises the following specific events:
-
Checked - occurs each time the item gets checked (occurs only for checkable items). The event handler receives two arguments:
The sender argument contains the RadMenuItem. This argument is of type object, but can be cast to the RadMenuItem type.
An RoutedEventArgs object.
-
Click - occurs each time the item gets clicked. The event handler receives two arguments:
The sender argument contains the RadMenuItem. This argument is of type object, but can be cast to the RadMenuItem type.
A RadRoutedEventArgs object.
By default this event won't fire for items that contain child menu items. You can change this behavior by setting the NotifyOnHeaderClick property of the RadMenu to True.
-
SubmenuClosed - occurs each time the child items of the item get hidden. The event handler receives two arguments:
The sender argument contains the RadMenuItem. This argument is of type object, but can be cast to the RadMenuItem type.
A RadRoutedEventArgs object.
-
SubmenuOpened - occurs each time the child items of the item get displayed. The event handler receives two arguments:
The sender argument contains the RadMenuItem. This argument is of type object, but can be cast to the RadMenuItem type.
A RadRoutedEventArgs object.
-
Unchecked - occurs each time the item gets unchecked (occurs only for checkable items). The event handler receives two arguments:
The sender argument contains the RadMenuItem. This argument is of type object, but can be cast to the RadMenuItem type.
A RoutedEventArgs object.
If a checkable item is clicked, the Click of the RadMenuItem and the ItemClick of the RadMenu events will occur first and then the Checked/Unchecked events.