Move reveal_path to ForegroundPlatform

So that we can use spawn to use the OS API call.

Co-Authored-By: Antonio Scandurra <me@as-cii.com>
This commit is contained in:
Petros Amoiridis 2023-02-20 18:57:37 +02:00
parent efafd1d8d3
commit 4bb986b3be
No known key found for this signature in database
6 changed files with 57 additions and 24 deletions

View file

@ -792,8 +792,7 @@ impl ProjectPanel {
fn reveal_in_finder(&mut self, _: &RevealInFinder, cx: &mut ViewContext<Self>) {
if let Some((worktree, entry)) = self.selected_entry(cx) {
cx.platform()
.reveal_path(&worktree.abs_path().join(&entry.path));
cx.reveal_path(&worktree.abs_path().join(&entry.path));
}
}