summaryrefslogtreecommitdiff
path: root/dev/gui
diff options
context:
space:
mode:
Diffstat (limited to 'dev/gui')
-rw-r--r--dev/gui/gui.zig8
1 files changed, 8 insertions, 0 deletions
diff --git a/dev/gui/gui.zig b/dev/gui/gui.zig
index a478db03..7a87c110 100644
--- a/dev/gui/gui.zig
+++ b/dev/gui/gui.zig
@@ -2648,6 +2648,7 @@ const Shell = struct {
.open_link = openLink,
.start = host_io.startDetached,
.lsp = lsp,
+ .lsp_open = lspOpen,
.pipe = pipe,
.search = search,
.hand_over = handOver,
@@ -3223,6 +3224,13 @@ fn lsp(ctx: ?*anyopaque, req: host_io.Lsp.Request) void {
s.core.reportError(req.pane, "lsp", error.WorkersUnavailable);
}
+/// Not held for `threads_ok`: the boot's file and a restored session's are
+/// opened before `start`.
+fn lspOpen(ctx: ?*anyopaque, pane: pardes.Pane.Id) void {
+ const s = shellOf(ctx);
+ s.queue.openLsp(s.core, pane);
+}
+
fn pipe(ctx: ?*anyopaque, id: u32) void {
const s = shellOf(ctx);
if (s.threads_ok) return selection_pipe.start(s.io, s.gpa, s.core, &s.queue.pipe_tasks, id, s.queue, Queue.pushPipe);