Merge pull request #8899 from JosJuice/convert-dialog-wswitch
DolphinQt: Fix some warnings in ConvertDialog
This commit is contained in:
commit
4ddd4ff835
|
@ -457,12 +457,12 @@ void ConvertDialog::Convert()
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
std::future<bool> good;
|
std::future<bool> success;
|
||||||
|
|
||||||
switch (format)
|
switch (format)
|
||||||
{
|
{
|
||||||
case DiscIO::BlobType::PLAIN:
|
case DiscIO::BlobType::PLAIN:
|
||||||
good = std::async(std::launch::async, [&] {
|
success = std::async(std::launch::async, [&] {
|
||||||
const bool good =
|
const bool good =
|
||||||
DiscIO::ConvertToPlain(blob_reader.get(), original_path, dst_path.toStdString(),
|
DiscIO::ConvertToPlain(blob_reader.get(), original_path, dst_path.toStdString(),
|
||||||
&CompressCB, &progress_dialog);
|
&CompressCB, &progress_dialog);
|
||||||
|
@ -472,7 +472,7 @@ void ConvertDialog::Convert()
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case DiscIO::BlobType::GCZ:
|
case DiscIO::BlobType::GCZ:
|
||||||
good = std::async(std::launch::async, [&] {
|
success = std::async(std::launch::async, [&] {
|
||||||
const bool good =
|
const bool good =
|
||||||
DiscIO::ConvertToGCZ(blob_reader.get(), original_path, dst_path.toStdString(),
|
DiscIO::ConvertToGCZ(blob_reader.get(), original_path, dst_path.toStdString(),
|
||||||
file->GetPlatform() == DiscIO::Platform::WiiDisc ? 1 : 0,
|
file->GetPlatform() == DiscIO::Platform::WiiDisc ? 1 : 0,
|
||||||
|
@ -484,7 +484,7 @@ void ConvertDialog::Convert()
|
||||||
|
|
||||||
case DiscIO::BlobType::WIA:
|
case DiscIO::BlobType::WIA:
|
||||||
case DiscIO::BlobType::RVZ:
|
case DiscIO::BlobType::RVZ:
|
||||||
good = std::async(std::launch::async, [&] {
|
success = std::async(std::launch::async, [&] {
|
||||||
const bool good = DiscIO::ConvertToWIAOrRVZ(
|
const bool good = DiscIO::ConvertToWIAOrRVZ(
|
||||||
blob_reader.get(), original_path, dst_path.toStdString(),
|
blob_reader.get(), original_path, dst_path.toStdString(),
|
||||||
format == DiscIO::BlobType::RVZ, compression, compression_level, block_size,
|
format == DiscIO::BlobType::RVZ, compression, compression_level, block_size,
|
||||||
|
@ -493,10 +493,14 @@ void ConvertDialog::Convert()
|
||||||
return good;
|
return good;
|
||||||
});
|
});
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
ASSERT(false);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
progress_dialog.GetRaw()->exec();
|
progress_dialog.GetRaw()->exec();
|
||||||
if (!good.get())
|
if (!success.get())
|
||||||
{
|
{
|
||||||
ModalMessageBox::critical(this, tr("Error"),
|
ModalMessageBox::critical(this, tr("Error"),
|
||||||
tr("Dolphin failed to complete the requested action."));
|
tr("Dolphin failed to complete the requested action."));
|
||||||
|
|
Loading…
Reference in New Issue