I can't fix it

This commit is contained in:
Hariharan Mudaliar 2025-10-02 21:02:52 +05:30
commit 44569d36b5
5 changed files with 162 additions and 20 deletions

View file

@ -337,9 +337,7 @@ struct NotchStatsView: View {
}
.frame(maxWidth: .infinity, maxHeight: .infinity)
.onAppear {
if enableStatsFeature && Defaults[.autoStartStatsMonitoring] && !statsManager.isMonitoring {
statsManager.startMonitoring()
}
// Note: Smart monitoring will handle starting/stopping based on notch state and current view
// Protect against hover interference during view transition
isResizingForStats = true
DispatchQueue.main.asyncAfter(deadline: .now() + 0.8) {

View file

@ -1586,11 +1586,10 @@ struct StatsSettings: View {
Section {
Defaults.Toggle("Enable system stats monitoring", key: .enableStatsFeature)
.onChange(of: enableStatsFeature) { _, newValue in
if newValue {
statsManager.startMonitoring()
} else {
if !newValue {
statsManager.stopMonitoring()
}
// Note: Smart monitoring will handle starting when switching to stats tab
}
if enableStatsFeature {

View file

@ -130,9 +130,7 @@ struct StatsPanelView: View {
.cornerRadius(12)
.shadow(color: .black.opacity(0.4), radius: 20, x: 0, y: 10)
.onAppear {
if enableStatsFeature && !statsManager.isMonitoring {
statsManager.startMonitoring()
}
// Note: Smart monitoring will handle starting/stopping based on UI state
}
}
}