title: Change background of disabled listView
body: <p>I want to set the style of a disabled ListView. But no matter what I do, the listView stays at the default style when disabled.</p>
  
  <p><strong>What I've already tried</strong>:</p>
  
  <ol>
  <li>Setting the System Color <code>SystemColors.ControlBrushKey</code> to <code>Transparent</code> according to this thread: <a href="https://stackoverflow.com/questions/15773669/change-disabled-listbox-background-to-gray">Change disabled listbox background to gray</a></li>
  <li>I also looked at the style of the listView at <a href="https://msdn.microsoft.com/en-us/library/vstudio/ms788747%28v=vs.100%29.aspx" rel="nofollow noreferrer">MSDN</a> and redefined the <code>DisabledBorderLightColor</code></li>
  <li>And of course I created a Trigger</li>
  </ol>
  
  <p>All these tries can be seen in the resource-section of the window:</p>
  
  <pre><code>&lt;Window.Resources&gt;
      &lt;Style TargetType="{x:Type ListView}"&gt;
          &lt;Style.Resources&gt;
              &lt;Color x:Key="DisabledBorderLightColor"&gt;#FF00FF00&lt;/Color&gt;
              &lt;SolidColorBrush x:Key="{x:Static SystemColors.ControlBrushKey}" Color="Transparent"/&gt;
          &lt;/Style.Resources&gt;
          &lt;Setter Property="Background" Value="Green"/&gt;
          &lt;Style.Triggers&gt;
              &lt;Trigger Property="IsEnabled" Value="False"&gt;
                  &lt;Setter Property="Background" Value="Red"/&gt;
              &lt;/Trigger&gt;
          &lt;/Style.Triggers&gt;
      &lt;/Style&gt;
  &lt;/Window.Resources&gt;
  &lt;Grid&gt;
      &lt;Grid.RowDefinitions&gt;
          &lt;RowDefinition Height="25"/&gt;
          &lt;RowDefinition/&gt;
      &lt;/Grid.RowDefinitions&gt;
      &lt;Button Content="Unselect" Click="UnselectItem"&gt;&lt;/Button&gt;
      &lt;ListView x:Name="_listView" 
                Grid.Row="1"
                d:DataContext="{d:DesignData ObjectToShow}" 
                IsEnabled="True"
                SelectionChanged="SelectItem"&gt;
          &lt;ListView.View&gt;
              &lt;GridView&gt;
                  &lt;GridView.Columns&gt;
                      &lt;GridViewColumn Header="Header1" DisplayMemberBinding="{Binding Property1}"/&gt;
                      &lt;GridViewColumn Header="Header2" DisplayMemberBinding="{Binding Property2}"/&gt;
                  &lt;/GridView.Columns&gt;
              &lt;/GridView&gt;
          &lt;/ListView.View&gt;
      &lt;/ListView&gt;
  &lt;/Grid&gt;
  </code></pre>
  
  <p>This is the according c#:</p>
  
  <pre><code>public partial class MainWindow : Window
  {
      public MainWindow()
      {
          InitializeComponent();
  
          var objectsToShow = new List&lt;ObjectToShow&gt;
          {
              new ObjectToShow
              {
                  Property1 = "Content1Property1",
                  Property2 = "Content1Property2"
              },
              new ObjectToShow
              {
                  Property1 = "Content2Property1",
                  Property2 = "Content2Property2"
              },
          };
  
          _listView.ItemsSource = objectsToShow;
      }
  
      private void SelectItem(object sender, SelectionChangedEventArgs e)
      {
          _listView.IsEnabled = false;
      }
  
      private void UnselectItem(object sender, RoutedEventArgs e)
      {
          _listView.SelectedItem = null;
          _listView.IsEnabled = true;
      }
  }
  
  public class ObjectToShow
  {
      public string Property1 { get; set; }
  
      public string Property2 { get; set; }
  }
  </code></pre>
  
  <p>I just want the listView to have the Red background when it is disabled. How can I achieve that?</p>