Skip to content

Commit a1db348

Browse files
author
Ravbug
committed
Reorder some things
1 parent 0271c0e commit a1db348

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

source/globals.cpp

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,14 +26,11 @@ void reveal_in_explorer(const std::filesystem::path& path) {
2626
#if defined __APPLE__
2727
RevealFile(path);
2828
#else
29+
if (std::filesystem::exists(path)) {
2930
#if defined __linux__
3031
std::string command = "xdg-open \"" + path.string() + "\"";
3132
launch_process(command);
32-
3333
#elif defined _WIN32
34-
//do not surround the paths in quotes, it will not work
35-
#endif
36-
if (std::filesystem::exists(path)) {
3734

3835
PIDLIST_ABSOLUTE pidl;
3936
SFGAOF attributes;
@@ -50,9 +47,10 @@ void reveal_in_explorer(const std::filesystem::path& path) {
5047
}
5148
}
5249
else {
53-
wxMessageBox("The project at " + path.string() + " could not be found.", "Cannot Reveal Project", wxOK | wxICON_ERROR);
50+
wxMessageBox("The item at " + path.string() + " could not be found.", "Cannot Reveal Item", wxOK | wxICON_ERROR);
5451
}
5552
#endif
53+
#endif
5654
}
5755

5856
long wxListCtrl_get_selected(wxListCtrl* listCtrl) {

0 commit comments

Comments
 (0)