private void SelectItem(ThumbnailItem newChild) { if (_lastSelectedChild != null) { _lastSelectedChild.ClearValue(BackgroundProperty); } if (newChild != null) { newChild.SetBinding(BackgroundProperty, new Binding("SelectedBrush") { Source = this }); } _lastSelectedChild = newChild; }