summaryrefslogtreecommitdiff
path: root/src/ninep
diff options
context:
space:
mode:
Diffstat (limited to 'src/ninep')
-rw-r--r--src/ninep/ctl.zig3
-rw-r--r--src/ninep/events.zig3
-rw-r--r--src/ninep/pane.zig3
3 files changed, 6 insertions, 3 deletions
diff --git a/src/ninep/ctl.zig b/src/ninep/ctl.zig
index a3c1ab9e..25fe4037 100644
--- a/src/ninep/ctl.zig
+++ b/src/ninep/ctl.zig
@@ -6,6 +6,7 @@
//! own would say any better: `get`, `lock` and `unlock`.
const std = @import("std");
const pardes = @import("../pardes.zig");
+const look = @import("../look.zig");
const panes = @import("../panes.zig");
const config = @import("../config.zig");
const fs = @import("../fs.zig");
@@ -58,7 +59,7 @@ fn activeSerial(p: *Pardes) ?u32 {
fn run(p: *Pardes, id: usize, exec: bool, text: []const u8) void {
const context = p.panes[id].?.serial;
const before = Serials.snapshot(p);
- if (exec) _ = p.execute(id, text) else p.lookAt(id, text);
+ if (exec) _ = p.execute(id, text) else look.lookAt(p, id, text);
const after = Serials.snapshot(p);
var created = false;
for (after.list[0..after.len]) |serial| if (!before.has(serial)) {
diff --git a/src/ninep/events.zig b/src/ninep/events.zig
index 0e8d7bb7..d4d7fcad 100644
--- a/src/ninep/events.zig
+++ b/src/ninep/events.zig
@@ -2,6 +2,7 @@
//! bounded queues that park a read until something happens.
const std = @import("std");
const pardes = @import("../pardes.zig");
+const look = @import("../look.zig");
const tree = @import("tree.zig");
const pane_files = @import("pane.zig");
@@ -461,7 +462,7 @@ pub fn writeEvent(p: *Pardes, req: Req, id: usize) Reply {
const text = p.scratch.allocator().dupe(u8, whole[lo..hi]) catch continue;
switch (r.action) {
.body_exec, .tag_exec => _ = p.execute(live, text),
- .body_look, .tag_look => p.lookAt(live, text),
+ .body_look, .tag_look => look.lookAt(p, live, text),
else => unreachable,
}
}
diff --git a/src/ninep/pane.zig b/src/ninep/pane.zig
index 24398445..4110380a 100644
--- a/src/ninep/pane.zig
+++ b/src/ninep/pane.zig
@@ -3,6 +3,7 @@
//! mark and scroll, errors, event, look and exec. Terminals add pty/ (pty.zig).
const std = @import("std");
const pardes = @import("../pardes.zig");
+const look = @import("../look.zig");
const panes = @import("../panes.zig");
const modal = @import("../modal.zig");
const config = @import("../config.zig");
@@ -564,7 +565,7 @@ pub fn nameBuffer(p: *Pardes, id: usize, full: []const u8, preserve_tag: bool) !
f.context_revision = null;
pane.context_rows = 0;
pane.wrap_n = 0;
- p.invalidateLookHover(id);
+ look.invalidateLookHover(p, id);
p.emit(.{ .watch = .{ .pane = @intCast(id), .on = false } });
events.noteLog(p, .rename, pane);
}