title: ListViewItem IsKeyboardFocusWithin not triggering IsSelectedChange on view model
body: <p>I have a Style for a <code>TreeListViewItem</code>...really just a <code>ListViewItem</code> in a "tree structure".  The <code>DataContext</code> of the <code>ListViewItem</code> is set to my view model that has an <code>IsSelected</code> property bound to the item's <code>IsSelected</code>.  I made a change so that when the item is selected, style the item differently, and the property on my viewmodel gets set to 'true'.  This works well, but when I added a trigger for <code>IsKeyboardFocusWithin</code>, the viewmodel property no longer gets set.  The style of the item still changes, but I need the property on the viewmodel to change as well.  Any help would be great.</p>
  
  <p><strong>XAML:</strong></p>
  
  <pre><code>&lt;Style TargetType="{x:Type zcorectl:ZynTreeListViewItem}"&gt;
      &lt;Setter Property="KeyboardNavigation.TabNavigation" Value="Continue"/&gt;
      &lt;Setter Property="IsExpanded" Value="{Binding Path=IsExpanded, Mode=TwoWay}"/&gt;
      &lt;Setter Property="IsSelected" Value="{Binding Path=IsSelected, UpdateSourceTrigger=PropertyChanged}"/&gt;
      &lt;Setter Property="Template"&gt;
          &lt;Setter.Value&gt;
               &lt;ControlTemplate TargetType="{x:Type zcorectl:ZynTreeListViewItem}"&gt;
                  &lt;StackPanel&gt;
                      &lt;Border x:Name="Bd" Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}"&gt;
                          &lt;GridViewRowPresenter x:Name="PART_Header" Content="{TemplateBinding Header}" Columns="{StaticResource columns}" /&gt;
                      &lt;/Border&gt;
                      &lt;ItemsPresenter x:Name="ItemsHost"/&gt;
                  &lt;/StackPanel&gt;
                  &lt;ControlTemplate.Triggers&gt;
                      &lt;Trigger Property="IsExpanded" Value="false"&gt;
                          &lt;Setter TargetName="ItemsHost" Property="Visibility" Value="Collapsed"/&gt;
                      &lt;/Trigger&gt;
                      &lt;MultiTrigger&gt;
                          &lt;MultiTrigger.Conditions&gt;
                              &lt;Condition Property="HasHeader" Value="false"/&gt;
                              &lt;Condition Property="Width" Value="Auto"/&gt;
                          &lt;/MultiTrigger.Conditions&gt;
                          &lt;Setter TargetName="PART_Header" Property="MinWidth" Value="75"/&gt;
                      &lt;/MultiTrigger&gt;
                      &lt;MultiTrigger&gt;
                          &lt;MultiTrigger.Conditions&gt;
                              &lt;Condition Property="HasHeader" Value="false"/&gt;
                              &lt;Condition Property="Height" Value="Auto"/&gt;
                          &lt;/MultiTrigger.Conditions&gt;
                          &lt;Setter TargetName="PART_Header" Property="MinHeight" Value="19"/&gt;
                       &lt;/MultiTrigger&gt;
                       &lt;Trigger Property="IsKeyboardFocusWithin" Value="True"&gt;
                            &lt;Setter Property="IsSelected" Value="True"/&gt;
                       &lt;/Trigger&gt;
                       &lt;Trigger Property="IsSelected" Value="true"&gt;
                           &lt;Setter TargetName="Bd" Property="BorderBrush" Value="{DynamicResource {x:Static SystemColors.HighlightBrushKey}}"/&gt; 
                           &lt;Setter TargetName="Bd" Property="BorderThickness" Value="0,2"/&gt;                                                        
                           &lt;Setter TargetName="Bd" Property="Height" Value="45"/&gt;                                                        
                           &lt;Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.HighlightTextBrushKey}}"/&gt;
                        &lt;/Trigger&gt;
                        &lt;MultiTrigger&gt;                                                        
                            &lt;MultiTrigger.Conditions&gt;
                                &lt;Condition Property="IsSelected" Value="true"/&gt;
                                &lt;Condition Property="IsSelectionActive" Value="false"/&gt;                                                                
                            &lt;/MultiTrigger.Conditions&gt;                                                        
                            &lt;Setter TargetName="Bd" Property="BorderBrush" Value="{DynamicResource {x:Static SystemColors.ControlBrushKey}}"/&gt;
                            &lt;Setter TargetName="Bd" Property="BorderThickness" Value="0,2"/&gt;                                                        
                            &lt;Setter TargetName="Bd" Property="Height" Value="45"/&gt;                                                        
                            &lt;Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}"/&gt;                                                         
                        &lt;/MultiTrigger&gt;
                        &lt;Trigger Property="IsEnabled" Value="false"&gt;
                            &lt;Setter Property="Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}"/&gt;
                        &lt;/Trigger&gt;
                     &lt;/ControlTemplate.Triggers&gt;
                 &lt;/ControlTemplate&gt;
             &lt;/Setter.Value&gt;
          &lt;/Setter&gt;
  </code></pre>
  
  <p><strong>ViewModel Code:</strong></p>
  
  <pre><code>private bool _isSelected = false;
  public bool IsSelected
  {
      get { return _isSelected; }
      set
      {
          if (_isSelected != value)
          {
              _isSelected = value;
              OnPropertyChanged("IsSelected");
          }
      }
  }
  </code></pre>