Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Sources/KeyPathAppKit/App.swift
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
class AppDelegate: NSObject, NSApplicationDelegate {
static func isOneShotProbeEnvironment(_ environment: [String: String] = ProcessInfo.processInfo.environment)
-> Bool
{

Check warning on line 123 in Sources/KeyPathAppKit/App.swift

View workflow job for this annotation

GitHub Actions / code-quality

Opening braces should be preceded by a single space and on the same line as the declaration (opening_brace)
OneShotProbeEnvironment.isActive(environment)
}

Expand Down Expand Up @@ -235,7 +235,7 @@
SingleInstanceCoordinator.activateExistingAndTerminateIfNeeded(
bundleIdentifier: bundleIdentifier
)
{

Check warning on line 238 in Sources/KeyPathAppKit/App.swift

View workflow job for this annotation

GitHub Actions / code-quality

Opening braces should be preceded by a single space and on the same line as the declaration (opening_brace)
AppLogger.shared.info("🪟 [AppDelegate] Duplicate normal app launch detected; exiting early")
return
}
Expand Down Expand Up @@ -309,6 +309,9 @@
// after the UI app quits. Only ServiceLifecycleCoordinator.stopKanata()
// should broadcast service state changes.
DistributedNotificationBridge.stop()
// Flush pending KindaVim telemetry so counters aren't lost on quit (up to one
// ~5s flush interval would otherwise be dropped — see #690). No-op when disabled.
KindaVimTelemetryStore.shared.flushNow()
kanataManager?.cleanupSync()
AppLogger.shared.info("✅ [AppDelegate] Cleanup complete, app terminating")
}
Expand Down Expand Up @@ -469,7 +472,7 @@
private func handleSubsequentActivation() {
if !LiveKeyboardOverlayController.shared.isVisible,
LiveKeyboardOverlayController.shared.canAutoShow
{

Check warning on line 475 in Sources/KeyPathAppKit/App.swift

View workflow job for this annotation

GitHub Actions / code-quality

Opening braces should be preceded by a single space and on the same line as the declaration (opening_brace)
LiveKeyboardOverlayController.shared.showForStartup()
AppLogger.shared.debug("🪟 [AppDelegate] Subsequent activation - showing overlay")
} else if !LiveKeyboardOverlayController.shared.isVisible {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,9 @@ final class KindaVimTelemetryStore {

deinit {
flushTask?.cancel()
// No final flush from deinit — the @MainActor restriction makes
// it impractical, and the `flushNow()` API + app-deactivation
// hook (TODO in a follow-up) covers correctness for the cases
// that matter (Pack Detail viewing, app quit).
// No final flush from deinit — the @MainActor restriction makes it
// impractical. Correctness is covered by the `flushNow()` API: called
// when viewing Pack Detail and from applicationWillTerminate on app quit (#690).
}

// MARK: - Opt-in gate
Expand Down
4 changes: 0 additions & 4 deletions Sources/KeyPathAppKit/UI/Gallery/PackDetailView+Helpers.swift
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
for setting in pack.quickSettings {
if quickSettingValues[setting.id] == nil,
let defaultVal = setting.defaultSliderValue
{

Check warning on line 43 in Sources/KeyPathAppKit/UI/Gallery/PackDetailView+Helpers.swift

View workflow job for this annotation

GitHub Actions / code-quality

Opening braces should be preceded by a single space and on the same line as the declaration (opening_brace)
quickSettingValues[setting.id] = defaultVal
}
}
Expand Down Expand Up @@ -74,10 +74,6 @@
}
return 20
}

func copyValidationErrorsToClipboard() {
// Placeholder for future implementation
}
}

// MARK: - Undo snapshot
Expand Down
Loading