151
152
moveHistory(location: ChatAgentLocation, fromHistoryKey: string, toHistoryKey: string): void {
154
return;
155
}
157
>
const fromHistory = this.getHistory(location, fromHistoryKey);
158
>
if (fromHistory.length === 0) {
159
return;
160
}
162
>
this.viewState.history ??= {};
163
>
164
>
const fromKey = this.getKey(location, fromHistoryKey);
165
>
const toKey = this.getKey(location, toHistoryKey);
166
>
this.viewState.history[toKey] = this.getHistory(location, toHistoryKey).concat(fromHistory).slice(-ChatInputHistoryMaxEntries);
167
>
delete this.viewState.history[fromKey];
168
>
this.changed = true;
169
>
this._onDidChangeHistory.fire({ kind: 'move', location, fromHistoryKey, toHistoryKey });
170
>
}
171
172
clearHistory(): void {