HackStudio: Fix failure to open files

Use FileSystemPath to figure out that "./foo.cpp" == "foo.cpp"
This commit is contained in:
Andreas Kling 2019-12-26 10:19:44 +01:00
parent 64842fd0ac
commit 22776589f0
Notes: sideshowbarker 2024-07-19 10:39:34 +09:00

View file

@ -203,7 +203,7 @@ bool Project::add_file(const String& filename)
ProjectFile* Project::get_file(const String& filename)
{
for (auto& file : m_files) {
if (file.name() == filename)
if (FileSystemPath(file.name()).string() == FileSystemPath(filename).string())
return &file;
}
return nullptr;