Skip to content

Commit

Permalink
fixed show-in-explorer functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
mrDIMAS committed Aug 6, 2022
1 parent 1678f13 commit 34df077
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion editor/src/asset/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,9 @@ impl ContextMenu {
if message.destination() == self.delete {
Log::verify(std::fs::remove_file(&item.path))
} else if message.destination() == self.show_in_explorer {
show_in_explorer(&item.path)
if let Ok(canonical_path) = item.path.canonicalize() {
show_in_explorer(&canonical_path)
}
} else if message.destination() == self.open {
open_in_explorer(&item.path)
} else if message.destination() == self.copy_path {
Expand Down

0 comments on commit 34df077

Please sign in to comment.