feat(tasks): mark task buffers as clean when task exits

This commit is contained in:
CJ van den Berg 2025-01-26 20:18:31 +01:00
parent a28f1db4c7
commit 304a62dfdc
Signed by: neurocyte
GPG key ID: 8EB1E1BB660E3FB9
3 changed files with 18 additions and 2 deletions

View file

@ -1317,6 +1317,10 @@ pub fn store_to_file_and_clean(self: *Self, file_path: []const u8) StoreToFileEr
self.file_utf8_sanitized = false;
}
pub fn mark_clean(self: *Self) void {
self.last_save = self.root;
}
pub fn is_dirty(self: *const Self) bool {
return if (!self.file_exists)
self.root.length() > 0