feat: refresh open_recent palette when the project is done loading the file list

This commit is contained in:
CJ van den Berg 2025-08-05 10:23:53 +02:00
parent 4ca455cbba
commit 67fc1581d3
Signed by: neurocyte
GPG key ID: 8EB1E1BB660E3FB9
3 changed files with 16 additions and 10 deletions

View file

@ -341,10 +341,10 @@ const Process = struct {
project.walk_tree_entry(path, mtime) catch |e| self.logger.err("walk_tree_entry", e);
} else if (try cbor.match(m.buf, .{ "walk_tree_done", tp.extract(&project_directory) })) {
if (self.projects.get(project_directory)) |project|
project.walk_tree_done() catch |e| return from.forward_error(e, @errorReturnTrace()) catch error.ClientFailed;
project.walk_tree_done(self.parent.ref()) catch |e| return from.forward_error(e, @errorReturnTrace()) catch error.ClientFailed;
} else if (try cbor.match(m.buf, .{ "git", tp.extract(&context), tp.more })) {
const project: *Project = @ptrFromInt(context);
project.process_git(m) catch {};
project.process_git(self.parent.ref(), m) catch {};
} else if (try cbor.match(m.buf, .{ "update_mru", tp.extract(&project_directory), tp.extract(&path), tp.extract(&row), tp.extract(&col) })) {
self.update_mru(project_directory, path, row, col) catch |e| return from.forward_error(e, @errorReturnTrace()) catch error.ClientFailed;
} else if (try cbor.match(m.buf, .{ "child", tp.extract(&project_directory), tp.extract(&language_server), "notify", tp.extract(&method), tp.extract_cbor(&params_cb) })) {