Skip to content

Commit 96897ae

Browse files
committed
fix build
1 parent 352e63f commit 96897ae

File tree

3 files changed

+10
-9
lines changed

3 files changed

+10
-9
lines changed

flake.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@
119119
echo '[workspace]' > Cargo.toml
120120
HOME="$WORK_DIR" ${pkgs.xvfb-run}/bin/xvfb-run -s "-screen 0 800x600x24" \
121121
${pkgs.cargo-nextest}/bin/cargo-nextest nextest run \
122+
--no-fail-fast \
122123
--archive-file ${kanata-switcher-test-archive}/archive.tar.zst \
123124
--workspace-remap . "$@"
124125
'';

src/daemon/main.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ struct Args {
186186

187187
/// Override SNI focus-only mode (true/false). When set, GSettings is not read.
188188
#[arg(long, value_enum, value_name = "true|false")]
189-
tray_focus_only: Option<TrayFocusOnly>,
189+
indicator_focus_only: Option<TrayFocusOnly>,
190190

191191
/// Install autostart desktop entry and exit
192192
#[arg(long, conflicts_with_all = ["uninstall_autostart", "restart", "pause", "unpause"])]
@@ -219,7 +219,7 @@ const AUTOSTART_PASSTHROUGH_OPTIONS: &[&str] = &[
219219
"install_gnome_extension",
220220
"no_install_gnome_extension",
221221
"no_indicator",
222-
"tray_focus_only",
222+
"indicator_focus_only",
223223
];
224224
const AUTOSTART_ONESHOT_OPTIONS: &[&str] = &[
225225
"restart",
@@ -365,10 +365,10 @@ fn autostart_passthrough_args(matches: &ArgMatches, args: &Args) -> Vec<String>
365365
"no_indicator" => {
366366
exec_args.push("--no-indicator".to_string());
367367
}
368-
"tray_focus_only" => {
368+
"indicator_focus_only" => {
369369
let value = args
370-
.tray_focus_only
371-
.expect("tray_focus_only missing after command-line input");
370+
.indicator_focus_only
371+
.expect("indicator_focus_only missing after command-line input");
372372
exec_args.push("--indicator-focus-only".to_string());
373373
exec_args.push(value.as_arg().to_string());
374374
}
@@ -3463,12 +3463,12 @@ fn start_sni_indicator(
34633463
control: SniControl,
34643464
status_broadcaster: StatusBroadcaster,
34653465
pause_broadcaster: PauseBroadcaster,
3466-
tray_focus_only: Option<TrayFocusOnly>,
3466+
indicator_focus_only: Option<TrayFocusOnly>,
34673467
) -> Option<ksni::Handle<SniIndicator>> {
34683468
println!("[SNI] Starting StatusNotifier indicator");
34693469
let initial_status = status_broadcaster.snapshot();
34703470
let mut settings = SniSettingsStore::new();
3471-
let show_focus_only = resolve_sni_focus_only(tray_focus_only, &mut settings);
3471+
let show_focus_only = resolve_sni_focus_only(indicator_focus_only, &mut settings);
34723472
let control_handle: Arc<dyn SniControlOps> = Arc::new(control);
34733473
let indicator = SniIndicator {
34743474
state: SniIndicatorState::new(initial_status, show_focus_only),
@@ -4792,7 +4792,7 @@ async fn run_once() -> Result<RunOutcome, Box<dyn std::error::Error + Send + Syn
47924792
control,
47934793
status_broadcaster.clone(),
47944794
pause_broadcaster.clone(),
4795-
args.tray_focus_only,
4795+
args.indicator_focus_only,
47964796
)
47974797
});
47984798
let _sni_guard = SniGuard::new(sni_handle);

src/daemon/tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ fn test_autostart_passthrough_args_skip_oneshot() {
281281
}
282282

283283
#[test]
284-
fn test_autostart_passthrough_args_tray_focus_only() {
284+
fn test_autostart_passthrough_args_indicator_focus_only() {
285285
let matches = Args::command().get_matches_from([
286286
"kanata-switcher",
287287
"--install-autostart",

0 commit comments

Comments
 (0)