Skip to content

Commit 1ba39c7

Browse files
committed
Remove a feature flag
1 parent a7d1e74 commit 1ba39c7

File tree

3 files changed

+3
-17
lines changed

3 files changed

+3
-17
lines changed

Core/Sources/HostApp/DebugView.swift

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ final class DebugSettings: ObservableObject {
2525
var restartXcodeInspectorIfAccessibilityAPIIsMalfunctioningNoTimer
2626
@AppStorage(\.toastForTheReasonWhyXcodeInspectorNeedsToBeRestarted)
2727
var toastForTheReasonWhyXcodeInspectorNeedsToBeRestarted
28-
@AppStorage(\.observeToAXNotificationOnAnotherThread)
29-
var observeToAXNotificationOnAnotherThread
3028
@AppStorage(\.observeToAXNotificationWithDefaultMode)
3129
var observeToAXNotificationWithDefaultMode
3230
init() {}
@@ -120,14 +118,8 @@ struct DebugSettingsView: View {
120118
UserDefaults.shared.set(nil, forKey: "ChatModels")
121119
UserDefaults.shared.set(nil, forKey: "EmbeddingModels")
122120
}
123-
124-
Group {
125-
Toggle(
126-
isOn: $settings.observeToAXNotificationOnAnotherThread
127-
) {
128-
Text("Observe to AXNotification on background thread")
129-
}
130121

122+
Group {
131123
Toggle(
132124
isOn: $settings.observeToAXNotificationWithDefaultMode
133125
) {
@@ -136,6 +128,7 @@ struct DebugSettingsView: View {
136128
}
137129
}
138130
}
131+
.frame(maxWidth: .infinity)
139132
.padding()
140133
}
141134
}

Tool/Sources/AXNotificationStream/AXNotificationStream.swift

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,7 @@ public final class AXNotificationStream: AsyncSequence {
5858
let mode: CFRunLoopMode = UserDefaults.shared
5959
.value(for: \.observeToAXNotificationWithDefaultMode) ? .defaultMode : .commonModes
6060

61-
let runLoop: CFRunLoop = UserDefaults.shared
62-
.value(for: \.observeToAXNotificationOnAnotherThread)
63-
? DispatchQueue.global(qos: .userInteractive).sync { CFRunLoopGetCurrent() }
64-
: CFRunLoopGetMain()
61+
let runLoop: CFRunLoop = CFRunLoopGetMain()
6562

6663
var cont: Continuation!
6764
stream = Stream { continuation in

Tool/Sources/Preferences/Keys.swift

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -605,10 +605,6 @@ public extension UserDefaultPreferenceKeys {
605605
)
606606
}
607607

608-
var observeToAXNotificationOnAnotherThread: FeatureFlag {
609-
.init(defaultValue: false, key: "FeatureFlag-observeToAXNotificationOnAnotherThread")
610-
}
611-
612608
var observeToAXNotificationWithDefaultMode: FeatureFlag {
613609
.init(defaultValue: false, key: "FeatureFlag-observeToAXNotificationWithDefaultMode")
614610
}

0 commit comments

Comments
 (0)