chore: Remove unintended changes from HotkeyManager and SettingsView
This commit is contained in:
parent
c83afac031
commit
fb94344537
@ -7,7 +7,6 @@ extension KeyboardShortcuts.Name {
|
||||
static let toggleMiniRecorder = Self("toggleMiniRecorder")
|
||||
static let toggleMiniRecorder2 = Self("toggleMiniRecorder2")
|
||||
static let pasteLastTranscription = Self("pasteLastTranscription")
|
||||
static let retryLastTranscription = Self("retryLastTranscription")
|
||||
}
|
||||
|
||||
@MainActor
|
||||
@ -134,18 +133,6 @@ class HotkeyManager: ObservableObject {
|
||||
}
|
||||
}
|
||||
|
||||
// Add retry last transcription shortcut
|
||||
if KeyboardShortcuts.getShortcut(for: .retryLastTranscription) == nil {
|
||||
let defaultRetryShortcut = KeyboardShortcuts.Shortcut(.r, modifiers: [.command, .option])
|
||||
KeyboardShortcuts.setShortcut(defaultRetryShortcut, for: .retryLastTranscription)
|
||||
}
|
||||
|
||||
KeyboardShortcuts.onKeyUp(for: .retryLastTranscription) { [weak self] in
|
||||
guard let self = self else { return }
|
||||
Task { @MainActor in
|
||||
LastTranscriptionService.retryLastTranscription(from: self.whisperState.modelContext, whisperState: self.whisperState)
|
||||
}
|
||||
}
|
||||
Task { @MainActor in
|
||||
try? await Task.sleep(nanoseconds: 100_000_000)
|
||||
self.setupHotkeyMonitoring()
|
||||
|
||||
@ -118,23 +118,6 @@ struct SettingsView: View {
|
||||
}
|
||||
}
|
||||
|
||||
SettingsSection(
|
||||
icon: "arrow.clockwise.circle.fill",
|
||||
title: "Retry Last Transcription",
|
||||
subtitle: "Configure shortcut to retry transcribing your most recent audio"
|
||||
) {
|
||||
HStack(spacing: 12) {
|
||||
Text("Retry Shortcut")
|
||||
.font(.system(size: 13, weight: .medium))
|
||||
.foregroundColor(.secondary)
|
||||
|
||||
KeyboardShortcuts.Recorder(for: .retryLastTranscription)
|
||||
.controlSize(.small)
|
||||
|
||||
Spacer()
|
||||
}
|
||||
}
|
||||
|
||||
SettingsSection(
|
||||
icon: "speaker.wave.2.bubble.left.fill",
|
||||
title: "Recording Feedback",
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user