chore(core-app): CB-339 export ElementsTree component

This commit is contained in:
Wroud
2020-10-21 16:32:57 +03:00
parent 0e1069534b
commit ea6d143517
2 changed files with 10 additions and 2 deletions
+2
View File
@@ -22,6 +22,8 @@ export * from './shared/NavigationTabs/TabNavigationContext';
export * from './shared/ToolsPanel/LogViewTab/LogViewerMenuService';
export * from './shared/ToolsPanel/LogViewTab/LogViewerService';
export * from './shared/SessionExpireDialog/SessionExpiredDialogService';
export * from './NavigationTree/ElementsTree';
export * from './NavigationTree/TreeContext';
export * from './NavigationTree/NavigationTreeService';
export * from './NavigationTree/NavigationTreeContextMenuService';
export * from './AppLocaleService';
@@ -120,7 +120,7 @@ export class NavNodeManagerService extends Bootstrap {
this.connectionInfo.onItemAdd.subscribe(this.connectionUpdateHandler.bind(this));
this.connectionInfo.onItemDelete.subscribe(this.connectionRemoveHandler.bind(this));
this.connectionInfo.onConnectionCreate.subscribe(this.connectionCreateHandler.bind(this));
this.sessionResource.onDataUpdate.subscribe(this.updateRootChildren.bind(this));
this.sessionResource.onDataUpdate.subscribe(this.refreshRoot.bind(this));
}
load(): void {}
@@ -319,7 +319,13 @@ export class NavNodeManagerService extends Bootstrap {
};
};
private async updateRootChildren() {
async updateRoot(): Promise<void> {
if (await this.isNavTreeEnabled()) {
await this.navTree.refresh(ROOT_NODE_PATH);
}
}
async refreshRoot(): Promise<void> {
this.navTree.delete(ROOT_NODE_PATH);
if (await this.isNavTreeEnabled()) {
await this.navTree.refresh(ROOT_NODE_PATH);