Commit ccea1324 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen
Browse files

fs: win32: Directory: Store absolute pathes

parent e1c720b2
......@@ -57,10 +57,11 @@ void Directory::read() const
auto file = charset::FromWide( f.cFileName );
if ( file[0] == '.' )
continue;
auto path = m_path + file.get();
if ( ( f.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY ) != 0 )
m_dirs.emplace_back( m_fsFactory.createDirectory( file.get() ) );
m_dirs.emplace_back( m_fsFactory.createDirectory( path ) );
else
m_files.emplace_back( std::make_shared<File>( file.get() ) );
m_files.emplace_back( std::make_shared<File>( path ) );
} while ( FindNextFile( h, &f ) != 0 );
FindClose( h );
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment