diff --git a/src/tui.zig b/src/tui.zig index 9580b14..34835e1 100644 --- a/src/tui.zig +++ b/src/tui.zig @@ -1044,7 +1044,7 @@ pub const App = struct { ctx.queueRefresh() catch |err| std.log.debug("queueRefresh failed: {t}", .{err}); return ctx.consumeAndRedraw(); }, - .tab_1, .tab_2, .tab_3, .tab_4, .tab_5, .tab_6, .tab_7, .tab_8 => { + .tab_1, .tab_2, .tab_3, .tab_4, .tab_5, .tab_6, .tab_7, .tab_8, .tab_9 => { const idx = @intFromEnum(action) - @intFromEnum(keybinds.Action.tab_1); if (idx < tabs.len) { const target = tabs[idx]; diff --git a/src/tui/keybinds.zig b/src/tui/keybinds.zig index 733ab48..02632fd 100644 --- a/src/tui/keybinds.zig +++ b/src/tui/keybinds.zig @@ -15,6 +15,7 @@ pub const Action = enum { tab_6, tab_7, tab_8, + tab_9, scroll_down, scroll_up, scroll_top, @@ -128,6 +129,7 @@ pub const global_default_bindings = [_]Binding{ .{ .action = .tab_6, .key = .{ .codepoint = '6' } }, .{ .action = .tab_7, .key = .{ .codepoint = '7' } }, .{ .action = .tab_8, .key = .{ .codepoint = '8' } }, + .{ .action = .tab_9, .key = .{ .codepoint = '9' } }, .{ .action = .scroll_down, .key = .{ .codepoint = 'd', .mods = .{ .ctrl = true } } }, .{ .action = .scroll_up, .key = .{ .codepoint = 'u', .mods = .{ .ctrl = true } } }, .{ .action = .scroll_top, .key = .{ .codepoint = 'g' } }, @@ -166,6 +168,7 @@ pub const action_labels = std.enums.EnumArray(Action, []const u8).init(.{ .tab_6 = "Tab 6", .tab_7 = "Tab 7", .tab_8 = "Tab 8", + .tab_9 = "Tab 9", .scroll_down = "Half page down", .scroll_up = "Half page up", .scroll_top = "Scroll to top",