Make adapter toggles actually gate screen-reading
The Settings "Adapters" toggles wrote adapterEnabled but nothing in the capture path ever read it, so flipping one off did nothing — and the caption still said "Inert in Phase 0". The adapters (Zoom/Teams/Signal/Meet) are all live now. SessionController.startVisual now skips visual capture when the detected app's adapter is toggled off (records audio-only; transcription still runs). Update the section caption to describe the real behavior.
This commit is contained in:
@@ -256,6 +256,9 @@ final class SessionController: ObservableObject {
|
|||||||
private func startVisual(t0Host: Double, generation: Int, recorder: AudioRecorder) async {
|
private func startVisual(t0Host: Double, generation: Int, recorder: AudioRecorder) async {
|
||||||
guard let capture = pendingCapture else { return } // manual recording → audio-only
|
guard let capture = pendingCapture else { return } // manual recording → audio-only
|
||||||
pendingCapture = nil
|
pendingCapture = nil
|
||||||
|
// Honor the per-app adapter switch: if the user turned this app's adapter off,
|
||||||
|
// skip screen-reading entirely and record audio-only (transcription still runs).
|
||||||
|
guard settings.adapterEnabled[capture.app.rawValue] ?? true else { return }
|
||||||
guard let vc = VisualCapture(app: capture.app, bundleID: capture.bundleID,
|
guard let vc = VisualCapture(app: capture.app, bundleID: capture.bundleID,
|
||||||
windowID: capture.windowID, t0Host: t0Host) else { return }
|
windowID: capture.windowID, t0Host: t0Host) else { return }
|
||||||
// Register the live capture before the await so a quit (prepareForTermination)
|
// Register the live capture before the await so a quit (prepareForTermination)
|
||||||
|
|||||||
@@ -63,7 +63,7 @@ struct SettingsView: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Section("Adapters") {
|
Section("Adapters") {
|
||||||
Text("Inert in Phase 0 — these toggles only persist for now.")
|
Text("Screen-reading for active-speaker cues. Turn one off to record that app audio-only — transcription still runs, but speakers aren’t identified from the screen.")
|
||||||
.font(.caption)
|
.font(.caption)
|
||||||
.foregroundStyle(.secondary)
|
.foregroundStyle(.secondary)
|
||||||
ForEach(AppSettings.adapterKeys, id: \.key) { adapter in
|
ForEach(AppSettings.adapterKeys, id: \.key) { adapter in
|
||||||
|
|||||||
Reference in New Issue
Block a user