feat: subagent list dialog - working

This commit is contained in:
tanzhenxin
2025-09-04 16:34:51 +08:00
parent 9fcc7a4cbe
commit e44e28a640
24 changed files with 1340 additions and 307 deletions

View File

@@ -54,6 +54,7 @@ import {
} from '../services/fileSystemService.js';
import { logCliConfiguration, logIdeConnection } from '../telemetry/loggers.js';
import { IdeConnectionEvent, IdeConnectionType } from '../telemetry/types.js';
import { SubagentManager } from '../subagents/subagent-manager.js';
// Re-export OAuth config type
export type { MCPOAuthConfig };
@@ -316,6 +317,7 @@ export class Config {
private readonly shouldUseNodePtyShell: boolean;
private readonly skipNextSpeakerCheck: boolean;
private initialized: boolean = false;
private subagentManager: SubagentManager | null = null;
constructor(params: ConfigParameters) {
this.sessionId = params.sessionId;
@@ -865,6 +867,13 @@ export class Config {
return this.gitService;
}
getSubagentManager(): SubagentManager {
if (!this.subagentManager) {
this.subagentManager = new SubagentManager(this.targetDir);
}
return this.subagentManager;
}
async createToolRegistry(): Promise<ToolRegistry> {
const registry = new ToolRegistry(this);