diff options
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2016-05-18 00:06:33 +0200 |
---|---|---|
committer | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> | 2016-05-21 18:09:56 +0200 |
commit | 8fc9c0312660aa8b74a1251f02dfedc84da5b96b (patch) | |
tree | 490fc1f96a96654b59c933c864aa792161399cbb /src/citra_qt | |
parent | Appveyor: Restore working directory after test_script (#1835) (diff) | |
download | yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.tar yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.tar.gz yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.tar.bz2 yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.tar.lz yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.tar.xz yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.tar.zst yuzu-8fc9c0312660aa8b74a1251f02dfedc84da5b96b.zip |
Diffstat (limited to '')
-rw-r--r-- | src/citra_qt/main.cpp | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/citra_qt/main.cpp b/src/citra_qt/main.cpp index a85c94a4b..9d47014aa 100644 --- a/src/citra_qt/main.cpp +++ b/src/citra_qt/main.cpp @@ -272,7 +272,15 @@ bool GMainWindow::InitializeSystem() { } bool GMainWindow::LoadROM(const std::string& filename) { - Loader::ResultStatus result = Loader::LoadFile(filename); + std::unique_ptr<Loader::AppLoader> app_loader = Loader::GetFileLoader(filename); + if (!app_loader) { + LOG_CRITICAL(Frontend, "Failed to obtain loader for %s!", filename.c_str()); + QMessageBox::critical(this, tr("Error while loading ROM!"), + tr("The ROM format is not supported.")); + return false; + } + + Loader::ResultStatus result = app_loader->Load(); if (Loader::ResultStatus::Success != result) { LOG_CRITICAL(Frontend, "Failed to load ROM!"); System::Shutdown(); |