~rockorager/comlink

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch
2 2

[PATCH] ui: add /redraw command and default binding to redraw screen

Details
Message ID
<20240719190826.84975-1-greg@gpanders.com>
DKIM signature
pass
Download raw message
Patch: +10 -0
This is useful if the screen state becomes garbled for any reason (e.g.
error messages printing to stderr).
---
 src/App.zig | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/App.zig b/src/App.zig
index f5b22f9..fe53fbc 100644
--- a/src/App.zig
+++ b/src/App.zig
@@ -154,6 +154,13 @@ pub fn init(alloc: std.mem.Allocator) !App {
        },
        .command = .@"next-channel",
    });
    try app.binds.append(.{
        .key = .{
            .codepoint = 'l',
            .mods = .{ .ctrl = true },
        },
        .command = .redraw,
    });

    // Get our system tls certs
    try app.bundle.rescan(alloc);
@@ -299,6 +306,7 @@ pub fn run(self: *App) !void {
                                .quit => self.should_quit = true,
                                .@"next-channel" => self.nextChannel(),
                                .@"prev-channel" => self.prevChannel(),
                                .redraw => self.vx.queueRefresh(),
                                else => {},
                            }
                            break;
@@ -1274,6 +1282,7 @@ pub const Command = enum {
    names,
    part,
    close,
    redraw,

    /// if we should append a space when completing
    pub fn appendSpace(self: Command) bool {
@@ -1403,6 +1412,7 @@ pub fn handleCommand(self: *App, buffer: Buffer, cmd: []const u8) !void {
            );
            return self.queueWrite(client, msg);
        },
        .redraw => self.vx.queueRefresh(),
    }
}

-- 
2.45.2
Details
Message ID
<D2TRD29KOC34.2DP1K6FOCGP94@partin.io>
In-Reply-To
<20240719190826.84975-1-greg@gpanders.com> (view parent)
DKIM signature
pass
Download raw message
Reviewed-by: Tristan Partin <tristan@partin.io>

-- 
Tristan Partin
https://tristan.partin.io
Details
Message ID
<D2UJIXPQ3GS5.23AQI26993234@timculverhouse.com>
In-Reply-To
<20240719190826.84975-1-greg@gpanders.com> (view parent)
DKIM signature
pass
Download raw message
On Fri Jul 19, 2024 at 2:08 PM CDT, Gregory Anders wrote:
> This is useful if the screen state becomes garbled for any reason (e.g.
> error messages printing to stderr).
> ---

Applied! Thanks!

-- 
Tim
Reply to thread Export thread (mbox)