Convert relative paths to absolute when opening containing folder of an iso.
Fixes issue 5879.
This commit is contained in:
parent
ad05d568b9
commit
482360906b
|
@ -19,6 +19,7 @@
|
||||||
|
|
||||||
#include <wx/imaglist.h>
|
#include <wx/imaglist.h>
|
||||||
#include <wx/fontmap.h>
|
#include <wx/fontmap.h>
|
||||||
|
#include <wx/filename.h>
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <memory>
|
#include <memory>
|
||||||
|
@ -982,9 +983,11 @@ void CGameListCtrl::OnOpenContainingFolder(wxCommandEvent& WXUNUSED (event))
|
||||||
const GameListItem *iso = GetSelectedISO();
|
const GameListItem *iso = GetSelectedISO();
|
||||||
if (!iso)
|
if (!iso)
|
||||||
return;
|
return;
|
||||||
std::string path;
|
|
||||||
SplitPath(iso->GetFileName(), &path, 0, 0);
|
wxString strPath(iso->GetFileName().c_str(), wxConvUTF8);
|
||||||
WxUtils::Explore(path.c_str());
|
wxFileName path = wxFileName::FileName(strPath);
|
||||||
|
path.MakeAbsolute();
|
||||||
|
WxUtils::Explore(path.GetPath().char_str());
|
||||||
}
|
}
|
||||||
|
|
||||||
void CGameListCtrl::OnOpenSaveFolder(wxCommandEvent& WXUNUSED (event))
|
void CGameListCtrl::OnOpenSaveFolder(wxCommandEvent& WXUNUSED (event))
|
||||||
|
|
Loading…
Reference in New Issue