private void Members_GotKeyboardFocus(object sender, KeyboardFocusChangedEventArgs e)
        {
            if (Members.SelectedIndex == -1)
            {
                Members.SelectedIndex = _viewModel.GetStartingSelectionIndex();
            }

            SetFocusToSelectedRow();
        }
        private void Members_GotKeyboardFocus(object sender, KeyboardFocusChangedEventArgs e)
        {
            if (Members.CurrentItem != null)
            {
                // When it has a valid value, CurrentItem is generally more up-to-date than SelectedIndex.
                // For example, if the user clicks on an out of view item in the parameter list (i.e. the
                // parameter list is long and the user scrolls to click another parameter farther down/up
                // in the list), CurrentItem will update immediately while SelectedIndex will not.
                Members.SelectedIndex = Members.Items.IndexOf(Members.CurrentItem);
            }

            if (Members.SelectedIndex == -1)
            {
                Members.SelectedIndex = _viewModel.GetStartingSelectionIndex();
            }

            SetFocusToSelectedRow(true);
        }