From 256b88f633ababb3c91898e246c84cc000e589e3 Mon Sep 17 00:00:00 2001 From: dotCooCoo Date: Mon, 16 Nov 2026 15:54:10 -0800 Subject: [PATCH] Preferences: the keyboard-focus tests check the focused control's description description_frame now returns the description of the accessibility node that has the keyboard focus, instead of the descriptions of every node. The Units, General and Type keyboard-focus tests compare it with the row's sentence, so they fail when the sentence is set on a node other than the focused control. --- crates/ui-egui/src/prefs_dialog/tests.rs | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/crates/ui-egui/src/prefs_dialog/tests.rs b/crates/ui-egui/src/prefs_dialog/tests.rs index 26a3b33ec8..e7bc60942c 100644 --- a/crates/ui-egui/src/prefs_dialog/tests.rs +++ b/crates/ui-egui/src/prefs_dialog/tests.rs @@ -1632,8 +1632,8 @@ fn ok_refuses_a_typed_folder_outside_the_automation_roots_before_looking_at_it() /// One frame of the open Preferences dialog with `events`, a quarter second after the last. → The /// texts it painted where they show (a text its clip rectangle hides is left out), with their -/// rectangles, and the description of each accessibility node that has one. -fn description_frame(a: &mut VectorcraftApp, ctx: &egui::Context, events: Vec) -> (Vec<(String, egui::Rect)>, Vec) { +/// rectangles, and the description of the accessibility node with the keyboard focus, if it has one. +fn description_frame(a: &mut VectorcraftApp, ctx: &egui::Context, events: Vec) -> (Vec<(String, egui::Rect)>, Option) { let time = ctx.input(|i| i.time) + 0.25; let screen_rect = Some(egui::Rect::from_min_size(egui::Pos2::ZERO, egui::vec2(1200.0, 900.0))); let raw = egui::RawInput { screen_rect, events, time: Some(time), ..Default::default() }; @@ -1653,9 +1653,11 @@ fn description_frame(a: &mut VectorcraftApp, ctx: &egui::Context, events: Vec