Skip to content

Commit

Permalink
calls - adjust to new root
Browse files Browse the repository at this point in the history
  • Loading branch information
jrieken committed Sep 12, 2019
1 parent ad9950b commit 275e632
Showing 1 changed file with 2 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -366,10 +366,7 @@ export class CallHierarchyTreePeekWidget extends PeekViewWidget {
const viewState = this._treeViewStates.get(this._direction);
await this._tree.setInput(item, viewState);

const [root] = this._tree.getNode(item).children;
await this._tree.expand(root.element as callHTree.Call);
const firstChild = this._tree.getFirstElementChild(root.element);
if (!(firstChild instanceof callHTree.Call)) {
if (this._tree.getNode(item).children.length === 0) {
//
this.showMessage(this._direction === CallHierarchyDirection.CallsFrom
? localize('empt.callsFrom', "No calls from '{0}'", item.word)
Expand All @@ -379,7 +376,7 @@ export class CallHierarchyTreePeekWidget extends PeekViewWidget {
this._parent.dataset['state'] = State.Data;
this._tree.domFocus();
if (!viewState) {
this._tree.setFocus([firstChild]);
this._tree.focusFirst();
}
}

Expand Down

0 comments on commit 275e632

Please sign in to comment.