mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2025-04-29 22:24:26 +02:00
Merge pull request #3373 from Trial97/fix_crash2
Show warning when adding new resources with no instances
This commit is contained in:
commit
6404d81ada
@ -1027,6 +1027,14 @@ void MainWindow::processURLs(QList<QUrl> urls)
|
||||
continue;
|
||||
}
|
||||
|
||||
if (APPLICATION->instances()->count() <= 0) {
|
||||
CustomMessageBox::selectable(this, tr("No instance!"),
|
||||
tr("No instance available to add the resource to.\nPlease create a new instance before "
|
||||
"attempting to install this resource again."),
|
||||
QMessageBox::Critical)
|
||||
->show();
|
||||
continue;
|
||||
}
|
||||
ImportResourceDialog dlg(localFileName, type, this);
|
||||
|
||||
if (dlg.exec() != QDialog::Accepted)
|
||||
|
Loading…
x
Reference in New Issue
Block a user