title: EventTriggers in ListViewItem should not get triggered by contained ItemTemplate
body: <p>In an wpf application I have a ListView with Drag and Drop functionality, which inserts the dropped element at the position, where it was dropped instead of the end of the list. Thats working fine. What i now want to achieve seemed to be the simple part :) I want to make clear for the user at which position in the list the currently dragged element will be dropped. There should be a gap where the new element will be inserted.</p>
  <p>My approach was to change the Padding of the ListViewItem at the current mousePosition.</p>
  <pre><code>&lt;ControlTemplate TargetType=&quot;ListViewItem&quot;&gt;
      &lt;Border x:Name=&quot;BorderA&quot;&gt;
          &lt;ContentPresenter /&gt;
          &lt;Border.Triggers&gt;
  
              &lt;!--padding for gap when mouse hovers element--&gt;
              &lt;EventTrigger RoutedEvent=&quot;DragEnter&quot; SourceName=&quot;BorderA&quot;&gt;
                  &lt;BeginStoryboard&gt;
                      &lt;Storyboard&gt;
                          &lt;ThicknessAnimation
                              Storyboard.TargetProperty=&quot;Padding&quot;
                              From=&quot;0,0,0,0&quot; To=&quot;0,25,0,0&quot; 
                              BeginTime=&quot;0:0:0&quot; Duration=&quot;0:0:0.5&quot; 
                              AutoReverse=&quot;False&quot; /&gt;
                      &lt;/Storyboard&gt;
                  &lt;/BeginStoryboard&gt;
              &lt;/EventTrigger&gt;
  
              &lt;!--back to normal padding--&gt;
              &lt;EventTrigger RoutedEvent=&quot;DragLeave&quot; SourceName=&quot;BorderA&quot;&gt;
                  &lt;BeginStoryboard&gt;
                      &lt;Storyboard&gt;
                          &lt;ThicknessAnimation
                              Storyboard.TargetProperty=&quot;Padding&quot;
                              From=&quot;0,25,0,0&quot; To=&quot;0,0,0,0&quot; 
                              BeginTime=&quot;0:0:0&quot; Duration=&quot;0:0:0.5&quot; 
                              AutoReverse=&quot;False&quot; /&gt;
                      &lt;/Storyboard&gt;
                  &lt;/BeginStoryboard&gt;
              &lt;/EventTrigger&gt;
  
          &lt;/Border.Triggers&gt;
      &lt;/Border&gt;
  &lt;/ControlTemplate&gt;
  </code></pre>
  <p>I also need a DataTemplate to display my listItems correctly. I simplified that here, which might make it appear nearly redundand, but in reality i need to display a complex viewModel and it seems to be part of the problem.</p>
  <pre><code>&lt;DataTemplate x:Key=&quot;SortableListBoxItemTemplate&quot; DataType=&quot;item:SortableListItemViewModel&quot;&gt;
      &lt;Border Background=&quot;{StaticResource CallToActionBrush}&quot;
              BorderThickness=&quot;{StaticResource BorderThickness}&quot;
              BorderBrush=&quot;{StaticResource PassiveBorderBrush_Strong}&quot;&gt;
      &lt;/Border&gt;
  &lt;/DataTemplate&gt;
  </code></pre>
  <p>That seemd to work. When i hover an element while dragging another, a gap between that element and the previous list element appears. But sometimes when the gap grows the mouse position will be within this gap. That triggeres the DragLeave Event, the gap starts closing until the listItem has reached the mouse position again and so on. That causes an ugly flickering and i am not sure how to avoid that. Everything is fine as long as the DataTemplate hasn't a Background color. But thats not the visual effect i want. Is there a way to trigger that DragEnter and DragLeave events only if they were fired from my listviewItem (or BorderA)? Or is there a complete other way to achieve the effect i want?</p>