mirror of
https://github.com/D-Modem/app.git
synced 2026-11-28 17:38:05 -08:00
iOS: the greeting's timer is Foundation's (the shared Kotlin has a Timer too)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01B82eRTvbHMpudRfQWK4c4H
This commit is contained in:
1 file changed
+2
-2
@@ -234,7 +234,7 @@ final class GreetingRecorder: ObservableObject {
|
||||
@Published private(set) var seconds = 0
|
||||
private let sound = VoiceSound()
|
||||
private var samples: [Float] = []
|
||||
private var timer: Timer?
|
||||
private var timer: Foundation.Timer?
|
||||
|
||||
/// the greeting's length read (0: none)
|
||||
func reload() {
|
||||
@@ -246,7 +246,7 @@ final class GreetingRecorder: ObservableObject {
|
||||
guard !recording, sound.start(record: true, loud: true) else { return }
|
||||
samples = []
|
||||
recording = true
|
||||
timer = Timer.scheduledTimer(withTimeInterval: 0.1, repeats: true) { [weak self] _ in
|
||||
timer = Foundation.Timer.scheduledTimer(withTimeInterval: 0.1, repeats: true) { [weak self] _ in
|
||||
Task { @MainActor [weak self] in self?.take() }
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user