(patch: Partial<AppState>)
| 1365 | } |
| 1366 | |
| 1367 | setAppState(patch: Partial<AppState>): void { |
| 1368 | if (!hasPatchChanges(this.state.appState, patch)) return; |
| 1369 | const additionalDirsChanged = |
| 1370 | 'additionalDirs' in patch && |
| 1371 | !sameStringArrays(this.state.appState.additionalDirs, patch.additionalDirs ?? []); |
| 1372 | const busyChanged = 'streamingPhase' in patch || 'isCompacting' in patch; |
| 1373 | Object.assign(this.state.appState, patch); |
| 1374 | if ('planMode' in patch) this.updateEditorBorderHighlight(); |
| 1375 | this.state.footer.setState(this.state.appState); |
| 1376 | this.updateActivityPane(); |
| 1377 | if (busyChanged) { |
| 1378 | this.updateQueueDisplay(); |
| 1379 | this.sessionEventHandler.retryQueuedGoalPromotion(); |
| 1380 | } |
| 1381 | if (additionalDirsChanged) this.setupAutocomplete(); |
| 1382 | this.state.ui.requestRender(); |
| 1383 | } |
| 1384 | |
| 1385 | patchLivePane(patch: Partial<LivePaneState>): void { |
| 1386 | if (!hasPatchChanges(this.state.livePane, patch)) return; |
no test coverage detected