diff --git a/src/duckstation-qt/qthost.cpp b/src/duckstation-qt/qthost.cpp index 47c472749..6b3814f1e 100644 --- a/src/duckstation-qt/qthost.cpp +++ b/src/duckstation-qt/qthost.cpp @@ -1266,7 +1266,7 @@ void EmuThread::changeDiscFromPlaylist(quint32 index) return; if (!System::SwitchMediaSubImage(index)) - Host::ReportFormattedErrorAsync("Error", "Failed to switch to subimage %u", index); + errorReported(tr("Error"), tr("Failed to switch to subimage %1").arg(index)); } void EmuThread::setCheatEnabled(quint32 index, bool enabled) diff --git a/src/util/host.cpp b/src/util/host.cpp index 423370689..735927236 100644 --- a/src/util/host.cpp +++ b/src/util/host.cpp @@ -125,22 +125,3 @@ void Host::ClearTranslationCache() s_translation_string_cache_pos = 0; s_translation_string_mutex.unlock(); } - -void Host::ReportFormattedErrorAsync(std::string_view title, const char* format, ...) -{ - std::va_list ap; - va_start(ap, format); - std::string message(StringUtil::StdStringFromFormatV(format, ap)); - va_end(ap); - ReportErrorAsync(title, message); -} - -bool Host::ConfirmFormattedMessage(std::string_view title, const char* format, ...) -{ - std::va_list ap; - va_start(ap, format); - std::string message = StringUtil::StdStringFromFormatV(format, ap); - va_end(ap); - - return ConfirmMessage(title, message); -} diff --git a/src/util/host.h b/src/util/host.h index 5caba2f43..8028975a2 100644 --- a/src/util/host.h +++ b/src/util/host.h @@ -31,11 +31,9 @@ void ReportFatalError(std::string_view title, std::string_view message); /// Displays an asynchronous error on the UI thread, i.e. doesn't block the caller. void ReportErrorAsync(std::string_view title, std::string_view message); -void ReportFormattedErrorAsync(std::string_view title, const char* format, ...); /// Displays a synchronous confirmation on the UI thread, i.e. blocks the caller. bool ConfirmMessage(std::string_view title, std::string_view message); -bool ConfirmFormattedMessage(std::string_view title, const char* format, ...); /// Returns the user agent to use for HTTP requests. std::string GetHTTPUserAgent();