mirror of
https://github.com/stenzek/duckstation.git
synced 2026-02-13 18:04:32 +00:00
Qt: Allow command line boot of device path
Untested.
This commit is contained in:
@@ -18,6 +18,7 @@
|
||||
#include "core/system.h"
|
||||
#include "core/system_private.h"
|
||||
|
||||
#include "util/cd_image.h"
|
||||
#include "util/gpu_device.h"
|
||||
#include "util/imgui_manager.h"
|
||||
#include "util/ini_settings_interface.h"
|
||||
@@ -1766,7 +1767,8 @@ bool MiniHost::ParseCommandLineParametersAndInitializeConfig(int argc, char* arg
|
||||
|
||||
// Check the file we're starting actually exists.
|
||||
|
||||
if (autoboot && !autoboot->path.empty() && !FileSystem::FileExists(autoboot->path.c_str()))
|
||||
if (autoboot && !autoboot->path.empty() && !FileSystem::FileExists(autoboot->path.c_str()) &&
|
||||
!CDImage::IsDeviceName(autoboot->path.c_str()))
|
||||
{
|
||||
Host::ReportFatalError("Error", fmt::format("File '{}' does not exist.", autoboot->path));
|
||||
return false;
|
||||
|
||||
@@ -44,6 +44,7 @@
|
||||
#include "common/threading.h"
|
||||
|
||||
#include "util/audio_stream.h"
|
||||
#include "util/cd_image.h"
|
||||
#include "util/http_downloader.h"
|
||||
#include "util/imgui_manager.h"
|
||||
#include "util/ini_settings_interface.h"
|
||||
@@ -3310,7 +3311,8 @@ bool QtHost::ParseCommandLineParametersAndInitializeConfig(QApplication& app,
|
||||
LoadResources();
|
||||
|
||||
// Check the file we're starting actually exists.
|
||||
if (autoboot && !autoboot->path.empty() && !FileSystem::FileExists(autoboot->path.c_str()))
|
||||
if (autoboot && !autoboot->path.empty() && !FileSystem::FileExists(autoboot->path.c_str()) &&
|
||||
!CDImage::IsDeviceName(autoboot->path.c_str()))
|
||||
{
|
||||
QMessageBox::critical(
|
||||
nullptr, qApp->translate("QtHost", "Error"),
|
||||
|
||||
Reference in New Issue
Block a user