Navigating GoGroups that are in GoBoxNode

I am trying to find out how to navigate GoGroups that are part of a list in a GoBoxNode using the up and down arrow keys. Think the ClassDiagramNode example in Demo1. My code is almost exactly like that. Code reuse. :)
I have searched the forum for “focus”, “arrow”, etc… but have not found anything pertaining to my question.
Thanks for any ideas!

This is an incomplete definition, showing you how to handle the arrow keys. You’ll need to make it smarter so that it operates exactly the way you want in every situation.
public class ArrowSelectingTool : GoToolManager {
public ArrowSelectingTool(GoView view) : base(view) { }
public override void DoKeyDown() {
GoInputEventArgs evt = this.LastInput;
if (evt.Key == Keys.Up || evt.Key == Keys.Down || evt.Key == Keys.Left || evt.Key == Keys.Right) {
ClassDiagramNodeItem item = this.View.Selection.Primary as ClassDiagramNodeItem;
if (item != null) {
int idx = item.Parent.IndexOf(item);
if (idx > 0 && evt.Key == Keys.Up) {
this.View.Selection.Select(item.Parent[idx-1]);
} else if (idx < item.Parent.Count-1 && evt.Key == Keys.Down) {
this.View.Selection.Select(item.Parent[idx+1]);
} else if (evt.Key == Keys.Left && item.Parent != null) {
ClassDiagramNodeItemList list = item.Parent.Parent as ClassDiagramNodeItemList; // note: Parent is a GoListGroup
if (list != null) {
list.Collapse();
this.View.Selection.Select(list);
}
}
} else {
ClassDiagramNodeItemList list = this.View.Selection.Primary as ClassDiagramNodeItemList;
if (list != null) {
int idx = list.Parent.IndexOf(list);
if (idx > 1 && evt.Key == Keys.Up) {
this.View.Selection.Select(list.Parent[idx-1]);
} else if (idx < list.Parent.Count-1 && evt.Key == Keys.Down) {
this.View.Selection.Select(list.Parent[idx+1]);
} else if (!list.IsExpanded && evt.Key == Keys.Right) {
list.Expand();
this.View.Selection.Select(list.List[0]);
}
}
}
return;
}
base.DoKeyDown();
}
}

Install with:
goView1.Tool = goView1.DefaultTool = new ArrowSelectingTool(goView1);

Thanks Walter!
I will give this a try!