Skip to content

Commit

Permalink
Cleanup, add the new strings to en_US.ini
Browse files Browse the repository at this point in the history
  • Loading branch information
hrydgard committed Oct 26, 2023
1 parent b71e44c commit e0ada6e
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
6 changes: 3 additions & 3 deletions Core/Util/GameDB.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

GameDB g_gameDB;

void SplitCSVLine(const std::string_view str, const char delim, std::vector<std::string_view> &result) {
static void SplitCSVLine(const std::string_view str, std::vector<std::string_view> &result) {
result.clear();

int indexCommaToLeftOfColumn = 0;
Expand Down Expand Up @@ -67,7 +67,7 @@ bool GameDB::LoadFromVFS(VFSInterface &vfs, const char *filename) {
// Split the string into views of each line, keeping the original.
std::vector<std::string_view> lines = splitSV(contents_, '\n', false);

SplitCSVLine(lines[0], ',', columns_);
SplitCSVLine(lines[0], columns_);

const size_t titleColumn = GetColumnIndex("Title");
const size_t foreignTitleColumn = GetColumnIndex("Foreign Title");
Expand All @@ -78,7 +78,7 @@ bool GameDB::LoadFromVFS(VFSInterface &vfs, const char *filename) {
std::vector<std::string_view> items;
for (size_t i = 1; i < lines.size(); i++) {
auto &lineString = lines[i];
SplitCSVLine(lineString, ',', items);
SplitCSVLine(lineString, items);
if (items.size() != columns_.size()) {
// Bad line
ERROR_LOG(SYSTEM, "Bad line in CSV file: %s", std::string(lineString).c_str());
Expand Down
8 changes: 4 additions & 4 deletions UI/GameScreen.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -323,14 +323,14 @@ void GameScreen::render() {
}
tvVerified_->SetVisibility(UI::V_VISIBLE);
if (found) {
tvVerified_->SetText(ga->T("Verified by the ReDump project"));
tvVerified_->SetText(ga->T("ISO OK according to the Redump project"));
tvVerified_->SetLevel(NoticeLevel::SUCCESS);
} else {
tvVerified_->SetText(ga->T("CRC does not match, bad or modified ISO"));
tvVerified_->SetText(ga->T("CRC checksum does not match, bad or modified ISO"));
tvVerified_->SetLevel(NoticeLevel::ERROR);
}
} else {
tvVerified_->SetText(ga->T("Game ID not in database"));
tvVerified_->SetText(ga->T("Game ID unknown - not in the Redump database"));
tvVerified_->SetVisibility(UI::V_VISIBLE);
tvVerified_->SetLevel(NoticeLevel::WARN);
}
Expand All @@ -339,7 +339,7 @@ void GameScreen::render() {
if (tvVerified_) {
std::vector<GameDBInfo> dbInfos;
if (!g_gameDB.GetGameInfos(info->id_version, &dbInfos)) {
tvVerified_->SetText(ga->T("Game ID not in database"));
tvVerified_->SetText(ga->T("Game ID unknown - not in the ReDump database"));
tvVerified_->SetVisibility(UI::V_VISIBLE);
tvVerified_->SetLevel(NoticeLevel::WARN);
} else if (info->gameSizeUncompressed != 0) { // don't do this check if info still pending
Expand Down
2 changes: 1 addition & 1 deletion UI/GameScreen.h
Original file line number Diff line number Diff line change
Expand Up @@ -88,5 +88,5 @@ class GameScreen : public UIDialogScreenWithGameBackground {
std::vector<Path> saveDirs;
std::string CRC32string;

bool isHomebrew_;
bool isHomebrew_ = false;
};
5 changes: 5 additions & 0 deletions assets/lang/en_US.ini
Original file line number Diff line number Diff line change
Expand Up @@ -524,18 +524,23 @@ ZIP file detected (Require WINRAR) = File is compressed (ZIP).\nPlease decompres
[Game]
Asia = Asia
Calculate CRC = Calculate CRC
Click "Calculate CRC" to verify ISO = Click "Calculate CRC" to verify ISO
ConfirmDelete = Delete
CRC checksum does not match, bad or modified ISO = CRC checksum does not match, bad or modified ISO
Create Game Config = Create game config
Create Shortcut = Create shortcut
Delete Game = Delete game
Delete Game Config = Delete game config
Delete Save Data = Delete savedata
Europe = Europe
File size incorrect, bad or modified ISO = File size incorrect, bad or modified ISO
Game = Game
Game ID unknown - not in the ReDump database = Game ID unknown - not in the ReDump database
Game Settings = Game settings
Homebrew = Homebrew
Hong Kong = Hong Kong
InstallData = Data install
ISO OK according to the ReDump project = ISO OK according to the ReDump project
Japan = Japan
Korea = Korea
MB = MB
Expand Down

0 comments on commit e0ada6e

Please sign in to comment.