feat(tabs): start work on a tabbar widget

This commit is contained in:
CJ van den Berg 2025-01-23 22:32:08 +01:00
parent 1d947ab499
commit d7b48b40f1
Signed by: neurocyte
GPG key ID: 8EB1E1BB660E3FB9
7 changed files with 196 additions and 2 deletions

View file

@ -39,6 +39,7 @@ file_exists: bool = true,
file_eol_mode: EolMode = .lf,
last_save_eol_mode: EolMode = .lf,
file_utf8_sanitized: bool = false,
hidden: bool = false,
undo_history: ?*UndoNode = null,
redo_history: ?*UndoNode = null,

View file

@ -31,6 +31,7 @@ pub fn open_file(self: *Self, file_path: []const u8) Buffer.LoadFromFileError!*B
break :blk buffer;
};
buffer.update_last_used_time();
buffer.hidden = false;
return buffer;
}
@ -44,6 +45,7 @@ pub fn open_scratch(self: *Self, file_path: []const u8, content: []const u8) Buf
break :blk buffer;
};
buffer.update_last_used_time();
buffer.hidden = false;
return buffer;
}