title: WPF: ComboBox with reset item
body: <p>I want to make a ComboBox in WPF that has one <code>null</code> item on the top, when this gets selected, the SelectedItem should be set to null (reset to default state). I've searched like forever, but didn't find a solution that was satisfying.</p>
  
  <p>If possible I would want it to do it only with XAML code or an attached behaviour, because I don't really like changing stuff in the ViewModel for the View, or overriding standard controls.</p>
  
  <p>Here is what I've come up with so far (shortened code):</p>
  
  <pre><code>[...]
  &lt;Popup x:Name="PART_Popup" [...]&gt;
      &lt;Border x:Name="PopupBorder" [...]&gt;
          &lt;ScrollViewer x:Name="DropDownScrollViewer" [...]&gt;
              &lt;StackPanel [...]&gt;
                  &lt;ComboBoxItem&gt;(None)&lt;/ComboBoxItem&gt;
                  &lt;ItemsPresenter x:Name="ItemsPresenter"/&gt;
              &lt;/StackPanel&gt;
          &lt;/ScrollViewer&gt;
      &lt;/Border&gt;
  &lt;/Popup&gt;
  [...]
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/T5Fie.png" alt="OpenCombo"></p>
  
  <p>I think the best way would be to somehow add an event trigger that sets the <code>SelectedIndex</code> to <code>-1</code> when the item gets selected, but here is where I've got stuck.</p>
  
  <p>Any ideas how to do this? Or an better way, like an attached behaviour?</p>