summaryrefslogtreecommitdiff
path: root/src/ninep/pane.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/ninep/pane.zig')
-rw-r--r--src/ninep/pane.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ninep/pane.zig b/src/ninep/pane.zig
index 4595d02d..49fa46c6 100644
--- a/src/ninep/pane.zig
+++ b/src/ninep/pane.zig
@@ -146,7 +146,7 @@ pub fn dirtyOf(pane: *const Pane) bool {
pub fn nameOf(p: *Pardes, pane: *const Pane) []const u8 {
if (pane.file) |*f| return f.path;
if (pane.pdfPath()) |path| return path;
- if (pane.image) |state| return state.path;
+ if (pane.addon) |k| if (k.path.len > 0) return k.path;
const cwd = pane.cwdSlice();
// A shell given no directory was started in the session's, and is
// named by it until it says where it is (a `new` then, not a rename).
@@ -156,7 +156,7 @@ pub fn nameOf(p: *Pardes, pane: *const Pane) []const u8 {
pub fn kindOf(pane: *const Pane) []const u8 {
if (pane.file != null) return "text";
if (pane.pdfPath() != null) return "pdf";
- if (pane.image != null) return "image";
+ if (pane.addon) |k| return k.nameOf();
// A command's pane is no shell to type into: a script choosing a
// terminal by kind must not pick one.
if (pane.command != null) return "cmd";