SymbolExplorer.MainWindow.MemberTree_SelectedItemChanged C# (CSharp) Method

MemberTree_SelectedItemChanged() private method

private MemberTree_SelectedItemChanged ( object sender, RoutedPropertyChangedEventArgs e ) : void
sender object
e RoutedPropertyChangedEventArgs
return void
        private void MemberTree_SelectedItemChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
        {
            if (((TabItem)ViewTabs.SelectedItem).Visibility != Visibility.Visible)
            {
                foreach (TabItem tab in ViewTabs.Items)
                {
                    if (tab.Visibility == Visibility.Visible)
                    {
                        ViewTabs.SelectedItem = tab;
                        break;
                    }
                }
            }
        }