diff options
| author | 2018-09-19 18:55:33 -0400 | |
|---|---|---|
| committer | 2018-09-19 18:57:26 -0400 | |
| commit | 05d49962b69f6597116246776828c2bbc8a98582 (patch) | |
| tree | 368b814f5954608acda1cdbba3eb5cc589c93b3e /src | |
| parent | Reworked incorrect nifm stubs (#1355) (diff) | |
| download | yuzu-05d49962b69f6597116246776828c2bbc8a98582.tar.gz yuzu-05d49962b69f6597116246776828c2bbc8a98582.tar.xz yuzu-05d49962b69f6597116246776828c2bbc8a98582.zip | |
control_metadata: Move language name array definition to the cpp file
This was used in two different translation units
(deconstructed_rom_directory and patch_manager). This means we'd be
pointlessly duplicating the whole array twice due to it being defined
within the header.
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/file_sys/control_metadata.cpp | 8 | ||||
| -rw-r--r-- | src/core/file_sys/control_metadata.h | 7 |
2 files changed, 9 insertions, 6 deletions
diff --git a/src/core/file_sys/control_metadata.cpp b/src/core/file_sys/control_metadata.cpp index e76bf77bf..b47c95d11 100644 --- a/src/core/file_sys/control_metadata.cpp +++ b/src/core/file_sys/control_metadata.cpp | |||
| @@ -8,6 +8,14 @@ | |||
| 8 | 8 | ||
| 9 | namespace FileSys { | 9 | namespace FileSys { |
| 10 | 10 | ||
| 11 | const std::array<const char*, 15> LANGUAGE_NAMES = { | ||
| 12 | "AmericanEnglish", "BritishEnglish", "Japanese", | ||
| 13 | "French", "German", "LatinAmericanSpanish", | ||
| 14 | "Spanish", "Italian", "Dutch", | ||
| 15 | "CanadianFrench", "Portugese", "Russian", | ||
| 16 | "Korean", "Taiwanese", "Chinese", | ||
| 17 | }; | ||
| 18 | |||
| 11 | std::string LanguageEntry::GetApplicationName() const { | 19 | std::string LanguageEntry::GetApplicationName() const { |
| 12 | return Common::StringFromFixedZeroTerminatedBuffer(application_name.data(), 0x200); | 20 | return Common::StringFromFixedZeroTerminatedBuffer(application_name.data(), 0x200); |
| 13 | } | 21 | } |
diff --git a/src/core/file_sys/control_metadata.h b/src/core/file_sys/control_metadata.h index 8a510bf46..319bae821 100644 --- a/src/core/file_sys/control_metadata.h +++ b/src/core/file_sys/control_metadata.h | |||
| @@ -66,12 +66,7 @@ enum class Language : u8 { | |||
| 66 | Default = 255, | 66 | Default = 255, |
| 67 | }; | 67 | }; |
| 68 | 68 | ||
| 69 | static constexpr std::array<const char*, 15> LANGUAGE_NAMES = { | 69 | extern const std::array<const char*, 15> LANGUAGE_NAMES; |
| 70 | "AmericanEnglish", "BritishEnglish", "Japanese", | ||
| 71 | "French", "German", "LatinAmericanSpanish", | ||
| 72 | "Spanish", "Italian", "Dutch", | ||
| 73 | "CanadianFrench", "Portugese", "Russian", | ||
| 74 | "Korean", "Taiwanese", "Chinese"}; | ||
| 75 | 70 | ||
| 76 | // A class representing the format used by NX metadata files, typically named Control.nacp. | 71 | // A class representing the format used by NX metadata files, typically named Control.nacp. |
| 77 | // These store application name, dev name, title id, and other miscellaneous data. | 72 | // These store application name, dev name, title id, and other miscellaneous data. |