diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/client/views/collections/CollectionTreeView.tsx | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/client/views/collections/CollectionTreeView.tsx b/src/client/views/collections/CollectionTreeView.tsx index 463439762..b27f75837 100644 --- a/src/client/views/collections/CollectionTreeView.tsx +++ b/src/client/views/collections/CollectionTreeView.tsx @@ -550,6 +550,8 @@ class TreeView extends React.Component<TreeViewProps> { </>; } + refocus = () => this.props.treeView.props.focus(this.props.treeView.props.Document); + render() { TraceMobx(); if (this.props.renderedIds.indexOf(this.doc[Id]) !== -1) return null; @@ -595,7 +597,7 @@ class TreeView extends React.Component<TreeViewProps> { fitToBox={this.boundsOfCollectionDocument !== undefined} PanelWidth={this.rtfWidth} PanelHeight={this.rtfOutlineHeight} - focus={returnFalse} + focus={this.refocus} ScreenToLocalTransform={this.docTransform} docFilters={returnEmptyFilter} searchFilterDocs={returnEmptyDoclist} @@ -930,7 +932,7 @@ export class CollectionTreeView extends CollectionSubView<Document, Partial<coll backgroundColor={this.props.backgroundColor} PanelWidth={this.rtfWidth} PanelHeight={this.rtfOutlineHeight} - focus={returnFalse} + focus={this.props.focus} ScreenToLocalTransform={this.titleTransform} docFilters={returnEmptyFilter} searchFilterDocs={returnEmptyDoclist} |