nvrsion: Add: Fix “semantic computer use” to depend on “virtual computer use” in SettingsView and Project.swift.
Nucleic-Promote: 1 Co-authored-by: Nucleic <[email protected]>
This commit is contained in:
@@ -512,6 +512,11 @@ private struct MacVMSettingsTab: View {
|
||||
.disabled(!serviceEnabled || !supported)
|
||||
Toggle("Virtual computer use", isOn: $computerUseByDefault)
|
||||
.disabled(!serviceEnabled || !supported)
|
||||
.onChange(of: computerUseByDefault) { _, isOn in
|
||||
// Semantic computer use builds on virtual computer use — turning the base off
|
||||
// turns the dependent off too, so it can't linger enabled on its own.
|
||||
if !isOn { axAgentEnabled = false }
|
||||
}
|
||||
if computerUseByDefault {
|
||||
Text("Uses virtual drivers to work in the background, without opening a window, "
|
||||
+ "capturing your mouse, or locking your keyboard. Requires no additional setup.")
|
||||
|
||||
@@ -615,9 +615,10 @@ public enum MacVMSettings {
|
||||
}
|
||||
|
||||
/// Whether the base image installs the optional in-guest semantic AX agent (the by-identity
|
||||
/// control add-on; see ``axAgentEnabledKey``). Only meaningful while the service is on.
|
||||
/// control add-on; see ``axAgentEnabledKey``). Builds on virtual computer use, so it requires
|
||||
/// both the service and ``computerUseByDefault`` to be on.
|
||||
public static var axAgentEnabled: Bool {
|
||||
serviceEnabled && defaults.bool(forKey: axAgentEnabledKey)
|
||||
computerUseByDefault && defaults.bool(forKey: axAgentEnabledKey)
|
||||
}
|
||||
|
||||
/// Whether the guest-screen monitor should auto-open for every session VM as it boots (see
|
||||
|
||||
Reference in New Issue
Block a user