WPF- How to hide a dropdown menu after click
<p>I have a <code>SplitButton</code> in my WPF window, which is borrowed from Xceed's Extended WPF Toolkit. Its dropdown content is consisted of some <code>RadioButton</code>s. Something like:</p>

<pre><code>&lt;Window x:Class="WpfTest.Test3"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:tk="clr-namespace:Xceed.Wpf.Toolkit;assembly=Xceed.Wpf.Toolkit"
        Title="Test3" Height="300" Width="300"&gt;
    &lt;Grid Height="25" Width="150"&gt;
        &lt;tk:SplitButton Content="Default Command"&gt;
            &lt;tk:SplitButton.DropDownContent&gt;
                &lt;StackPanel&gt;
                    &lt;RadioButton Content="Default Command" GroupName="variations" Margin="5" IsChecked="True"/&gt;
                    &lt;RadioButton Content="Alternate Command 1" GroupName="variations" Margin="5"/&gt;
                    &lt;RadioButton Content="Alternate Command 2" GroupName="variations" Margin="5"/&gt;
                &lt;/StackPanel&gt;
            &lt;/tk:SplitButton.DropDownContent&gt;
        &lt;/tk:SplitButton&gt;
    &lt;/Grid&gt;
&lt;/Window&gt;
</code></pre>

<p>which generates something like this:</p>

<p><a href="https://i.stack.imgur.com/AxnKM.png" rel="noreferrer"><img src="https://i.stack.imgur.com/AxnKM.png" alt="test"></a></p>

<p>The problem is, when I click on each of the <code>RadioButton</code>s the dropdown menu doesn't dissappear. I did some googling and realized that I should handle the <code>Click</code> event for each <code>RadioButton</code>. But I don't know how to hide the dropdown menu in that event handler. As a side-note, it seems a <code>MenuItem</code> <a href="https://stackoverflow.com/a/5260880/5358284">has the property of</a> <code>StaysOpenOnClick</code>, but there is no such thing for other controls.</p>

<p>Although doing this programmatically would suffice, but is there an MVVM way for this? </p>