diff options
| author | 2021-01-03 13:18:02 -0500 | |
|---|---|---|
| committer | 2021-01-03 13:18:04 -0500 | |
| commit | 86592b274e228708cf0f9e1f4063e917f1bb3bd5 (patch) | |
| tree | 5b18fb291f5655be3b6e9495efc7c7410b0bbfd8 /src/core/loader/loader.cpp | |
| parent | Merge pull request #5278 from MerryMage/cpuopt_unsafe_inaccurate_nan (diff) | |
| download | yuzu-86592b274e228708cf0f9e1f4063e917f1bb3bd5.tar.gz yuzu-86592b274e228708cf0f9e1f4063e917f1bb3bd5.tar.xz yuzu-86592b274e228708cf0f9e1f4063e917f1bb3bd5.zip | |
main: Resolve error string not displaying
During the transition to make the error dialog translatable, I
accidentally got rid of the conversion to ResultStatus, which prevented
operator<< from being invoked during formatting.
This adds a function to directly retrieve the result status string
instead so that it displays again.
Diffstat (limited to 'src/core/loader/loader.cpp')
| -rw-r--r-- | src/core/loader/loader.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/loader/loader.cpp b/src/core/loader/loader.cpp index d91c15561..e4f5fd40c 100644 --- a/src/core/loader/loader.cpp +++ b/src/core/loader/loader.cpp | |||
| @@ -185,6 +185,10 @@ constexpr std::array<const char*, 66> RESULT_MESSAGES{ | |||
| 185 | "The INI file contains more than the maximum allowable number of KIP files.", | 185 | "The INI file contains more than the maximum allowable number of KIP files.", |
| 186 | }; | 186 | }; |
| 187 | 187 | ||
| 188 | std::string GetResultStatusString(ResultStatus status) { | ||
| 189 | return RESULT_MESSAGES.at(static_cast<std::size_t>(status)); | ||
| 190 | } | ||
| 191 | |||
| 188 | std::ostream& operator<<(std::ostream& os, ResultStatus status) { | 192 | std::ostream& operator<<(std::ostream& os, ResultStatus status) { |
| 189 | os << RESULT_MESSAGES.at(static_cast<std::size_t>(status)); | 193 | os << RESULT_MESSAGES.at(static_cast<std::size_t>(status)); |
| 190 | return os; | 194 | return os; |