提交 d49d0e68 编写于 作者: I isidor

callstack view: expand is async

上级 8e740979
...@@ -227,21 +227,14 @@ export class CallStackView extends ViewletPanel { ...@@ -227,21 +227,14 @@ export class CallStackView extends ViewletPanel {
updateSelectionAndReveal(session); updateSelectionAndReveal(session);
} }
} else { } else {
this.tryToExpandElement(thread.session); const expansionsPromise = this.tree.expand(thread.session).then(() => this.tree.expand(thread));
this.tryToExpandElement(thread);
if (stackFrame) { if (stackFrame) {
updateSelectionAndReveal(stackFrame); // TODO@isidor need better error handling
expansionsPromise.then(() => updateSelectionAndReveal(stackFrame));
} }
} }
} }
private tryToExpandElement(element: CallStackItem): void {
try {
this.tree.expand(element);
} catch (e) { }
}
setVisible(visible: boolean): void { setVisible(visible: boolean): void {
super.setVisible(visible); super.setVisible(visible);
if (visible && this.needsRefresh) { if (visible && this.needsRefresh) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册