DiscExtractor: Don't hardcode names in ExportApploader and ExportDOL

This commit is contained in:
JosJuice
2017-06-17 16:53:55 +02:00
parent 89c901780e
commit baf3a3b188
3 changed files with 12 additions and 10 deletions

View File

@ -283,11 +283,11 @@ void FilesystemPanel::OnExtractHeaderData(wxCommandEvent& event)
bool ret = false;
if (event.GetId() == ID_EXTRACT_APPLOADER)
{
ret = DiscIO::ExportApploader(*m_opened_iso, partition, WxStrToStr(path));
ret = DiscIO::ExportApploader(*m_opened_iso, partition, WxStrToStr(path) + "/apploader.img");
}
else if (event.GetId() == ID_EXTRACT_DOL)
{
ret = DiscIO::ExportDOL(*m_opened_iso, partition, WxStrToStr(path));
ret = DiscIO::ExportDOL(*m_opened_iso, partition, WxStrToStr(path) + "/boot.dol");
}
if (!ret)
@ -437,8 +437,9 @@ void FilesystemPanel::ExtractDirectories(const std::string& full_path,
{
if (full_path.empty()) // Root
{
DiscIO::ExportApploader(*m_opened_iso, filesystem.GetPartition(), output_folder);
DiscIO::ExportDOL(*m_opened_iso, filesystem.GetPartition(), output_folder);
DiscIO::ExportApploader(*m_opened_iso, filesystem.GetPartition(),
output_folder + "/apploader.img");
DiscIO::ExportDOL(*m_opened_iso, filesystem.GetPartition(), output_folder + "/boot.dol");
}
std::unique_ptr<DiscIO::FileInfo> file_info = filesystem.FindFileInfo(full_path);