macOS: fold agent control into GatewayConnection

This commit is contained in:
Peter Steinberger
2025-12-17 17:10:30 +01:00
parent 557ffdbe35
commit 17a27fd312
19 changed files with 443 additions and 201 deletions

View File

@@ -332,14 +332,7 @@ final class AppState {
self.voiceWakeGlobalSyncTask?.cancel()
self.voiceWakeGlobalSyncTask = Task { [sanitized] in
try? await Task.sleep(nanoseconds: 650_000_000)
do {
_ = try await GatewayConnection.shared.request(
method: "voicewake.set",
params: ["triggers": AnyCodable(sanitized)],
timeoutMs: 10000)
} catch {
// Best-effort only.
}
await GatewayConnection.shared.voiceWakeSetTriggers(sanitized)
}
}