╭ changed ───────────────╮ │src/ui/widget/thread.zig│ ╰────────────────────────╯ ╭───────────╮ │← all files│ ╰───────────╯ ╭───────────────────────────────────────────────────────────────────────────────────────────────╮ │1258 .box => |*box| box, │ │1259 else => return false, │ │1260 }; │ │1261 - const selected = row.getFocus().child_id orelse return false; │ │1262 - const selected_index = row.children.getIndex(selected) orelse return false; │ │1263 - const target = if (right) selected_index + 1 else selected_index -| 1; │ │1264 - if (target == selected_index or target >= row.children.count()) return false;│ │1265 - root_focus.setFocus(row.children.keys()[target]); │ │1261 + if (!widget.moveInRow(row, root_focus, right)) return false; │ │1262 if (child.rect) |rect| self.scroll.scrollToRect(rect); │ │1263 return true; │ │1264 } │ ╰───────────────────────────────────────────────────────────────────────────────────────────────╯ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │2514 .arrow_up, .back_tab => if (formStep(form, cur, false)) |i| self.focusResolveChild(form, i, root_focus) else self.focusHeader(root_focus),│ │2515 .arrow_down, .tab => if (formStep(form, cur, true)) |i| self.focusResolveChild(form, i, root_focus), │ │2516 .arrow_left, .arrow_right => switch (child.widget) { │ │2521 - .box => |*row| { │ │2522 - const row_cid = row.getFocus().child_id orelse return; │ │2523 - const row_index = row.children.getIndex(row_cid) orelse return; │ │2524 - if (key == .arrow_left) { │ │2525 - if (row_index > 0) root_focus.setFocus(row.children.keys()[row_index - 1]); │ │2526 - } else if (row_index + 1 < row.children.count()) { │ │2527 - root_focus.setFocus(row.children.keys()[row_index + 1]); │ │2528 - } │ │2529 - }, │ │2517 + .box => |*row| _ = widget.moveInRow(row, root_focus, key == .arrow_right), │ │2518 else => try child.widget.input(allocator, key, root_focus), │ │2519 }, │ │2520 .enter => if (on_submit) try self.submitResolution(allocator), │ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯