void TranscriptWindow::SkeinShowNode(Skein::Node* node, Skein::Show why)
{
    if (GetSafeHwnd() == 0)
        return;

    switch (why)
    {
    case Skein::ShowSelect:
        m_skeinSelected = node; // Intentional fall-through
    case Skein::JustShow:
        if (ScrollToNode(node) == false)
        {
            m_skeinEndThread = m_skein->GetThreadBottom(node);
            Layout();
            ScrollToNode(node);
        }
        Invalidate();
        break;
    case Skein::ShowNewLine:
        break;
    case Skein::ShowNewTranscript:
        ScrollToNode(node);
        break;
    default:
        ASSERT(FALSE);
        break;
    }
}
void
JXTreeListWidget::ScrollToShowChildren
	(
	const JIndex index
	)
{
	const JTreeNode* node = itsTreeList->GetNode(index);
	if (!node->HasChildren())
		{
		return;
		}

	// scroll minimum to show last child

	const JTreeNode* lastChild = node->GetChild(node->GetChildCount());
	ScrollToNode(lastChild);

	// if original node not visible, force it to be

	const JCoordinate y = GetRowTop(index);
	if (y < (GetAperture()).top)
		{
		ScrollTo(0, y);
		}
}
void
GPMProcessTreeList::SelectProcess
	(
	const GPMProcessEntry& entry
	)
{
	JTableSelection& s = GetTableSelection();
	s.ClearSelection();

	GetTreeList()->MakeVisible(&entry);

	JIndex index;
	if (GetTreeList()->FindNode(&entry, &index))
		{
		s.SelectRow(index);
		ScrollToNode(&entry);
		}
}