Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
150
ItemTemplateSelector for RadialMenuItem
posted

Hi. I was wondering if there is a simple way to implement an itemtemplateselector property for the RadialMenuItem?

I have the following:

<XamRadialMenu>

<ig:RadialMenuItem
Visibility="{Binding HasContextualItems, Converter={StaticResource BoolToHiddenVisibility}}"
IsEnabled="{Binding HasContextualItems}"
ToolTip="{Binding ContextualMenuHeader}"
Header="{Binding ContextualMenuHeader}" Command="{Binding OpenCommand}"
CommandParameter="{Binding RelativeSource={RelativeSource Self}}"
OuterRingButtonFill="{Binding ContextualMenuBrush}"
OuterRingButtonHotTrackFill="{Binding ContextualMenuHotTrackBrush}"
ItemsSource="{Binding ContextualMenuItems}"
AutoUpdateRecentItem="False"> // Here instead of explicitly using one itemContainderTemplate i'd like to use a selector
<ig:RadialMenuItem.ItemContainerTemplate>
<DataTemplate DataType="local:ContextualMenuItem">
<ig:RadialMenuItem CheckBehavior="CheckBox"
Header="{Binding Header}"
ToolTip="{Binding Header}"
Command="{Binding Command}"
CommandParameter="{Binding RelativeSource={RelativeSource Self}}"
OuterRingButtonFill="{Binding Brush}"
OuterRingButtonHotTrackFill="{Binding HotTrackBrush}"
ItemsSource="{Binding Items}"
AutoUpdateRecentItem="False"
Visibility="{Binding UseMtvPresetListDataTemplate, Converter={StaticResource InvBoolToVisibility}}">
<ig:RadialMenuItem.ItemContainerTemplate>
<DataTemplate DataType="local:ContextualMenuItem">
<ig:RadialMenuItem CheckBehavior="CheckBox"
Header="{Binding Header}"
ToolTip="{Binding Header}"
Command="{Binding Command}"
CommandParameter="{Binding RelativeSource={RelativeSource Self}}" />
</DataTemplate>
</ig:RadialMenuItem.ItemContainerTemplate>
</ig:RadialMenuItem>
</DataTemplate>
</ig:RadialMenuItem.ItemContainerTemplate>
</ig:RadialMenuItem>

<XamRadialMenu>

Thanks for the help!

Nathan

Parents
No Data
Reply
  • 7535
    Offline posted

    Hello Nathan,

    Thank you for posting. After investigating itemtemplateselector property for the RadialMenuItem and doing some research, itemtemplateselector in built support for RadialMenuItem has been determined to be a new feature idea. You can suggest new feature ideas for future versions (or vote for existing ones) at <ideas.infragistics.com>.

    Best thing I can probably recommend to try is that you builds the DataTemplates externally and gives them an x:Key. Doing that, you can get those templates programmatically and assign them. Completely spit-balling though, don't really know if that would work out of the box, for us in-built support of that in a new feature idea.

    Sincerely,
    Divya Jain
    Associate Software Developer

Children