mirror of
https://github.com/PabloMK7/citra.git
synced 2024-11-20 06:24:17 +00:00
Use the QT_TRANSLATE_NOOP macro
This commit is contained in:
parent
cb36f9fad2
commit
2f8bd18296
1 changed files with 11 additions and 11 deletions
|
@ -74,20 +74,20 @@ static QString GetQStringShortTitleFromSMDH(const Loader::SMDH& smdh,
|
||||||
|
|
||||||
struct CompatStatus {
|
struct CompatStatus {
|
||||||
QString color;
|
QString color;
|
||||||
QString text;
|
const char* text;
|
||||||
QString tooltip;
|
const char* tooltip;
|
||||||
};
|
};
|
||||||
|
|
||||||
// When this is put in a class, MSVS builds crash when closing Citra
|
// When this is put in a class, MSVS builds crash when closing Citra
|
||||||
// clang-format off
|
// clang-format off
|
||||||
const static inline std::map<QString, CompatStatus> status_data = {
|
const static inline std::map<QString, CompatStatus> status_data = {
|
||||||
{ "0", { "#5c93ed", GameList::tr("Perfect"), GameList::tr("Game functions flawless with no audio or graphical glitches, all tested functionality works as intended without\nany workarounds needed.") } },
|
{ "0", { "#5c93ed", QT_TRANSLATE_NOOP("GameList", "Perfect"), QT_TRANSLATE_NOOP("GameList", "Game functions flawless with no audio or graphical glitches, all tested functionality works as intended without\nany workarounds needed.") } },
|
||||||
{ "1", { "#47d35c", GameList::tr("Great"), GameList::tr("Game functions with minor graphical or audio glitches and is playable from start to finish. May require some\nworkarounds.") } },
|
{ "1", { "#47d35c", QT_TRANSLATE_NOOP("GameList", "Great"), QT_TRANSLATE_NOOP("GameList", "Game functions with minor graphical or audio glitches and is playable from start to finish. May require some\nworkarounds.") } },
|
||||||
{ "2", { "#94b242", GameList::tr("Okay"), GameList::tr("Game functions with major graphical or audio glitches, but game is playable from start to finish with\nworkarounds.") } },
|
{ "2", { "#94b242", QT_TRANSLATE_NOOP("GameList", "Okay"), QT_TRANSLATE_NOOP("GameList", "Game functions with major graphical or audio glitches, but game is playable from start to finish with\nworkarounds.") } },
|
||||||
{ "3", { "#f2d624", GameList::tr("Bad"), GameList::tr("Game functions, but with major graphical or audio glitches. Unable to progress in specific areas due to glitches\neven with workarounds.") } },
|
{ "3", { "#f2d624", QT_TRANSLATE_NOOP("GameList", "Bad"), QT_TRANSLATE_NOOP("GameList", "Game functions, but with major graphical or audio glitches. Unable to progress in specific areas due to glitches\neven with workarounds.") } },
|
||||||
{ "4", { "#FF0000", GameList::tr("Intro/Menu"), GameList::tr("Game is completely unplayable due to major graphical or audio glitches. Unable to progress past the Start\nScreen.") } },
|
{ "4", { "#FF0000", QT_TRANSLATE_NOOP("GameList", "Intro/Menu"), QT_TRANSLATE_NOOP("GameList", "Game is completely unplayable due to major graphical or audio glitches. Unable to progress past the Start\nScreen.") } },
|
||||||
{ "5", { "#828282", GameList::tr("Won't Boot"), GameList::tr("The game crashes when attempting to startup.") } },
|
{ "5", { "#828282", QT_TRANSLATE_NOOP("GameList", "Won't Boot"), QT_TRANSLATE_NOOP("GameList", "The game crashes when attempting to startup.") } },
|
||||||
{ "99",{ "#000000", GameList::tr("Not Tested"), GameList::tr("The game has not yet been tested.") } }, };
|
{ "99",{ "#000000", QT_TRANSLATE_NOOP("GameList", "Not Tested"), QT_TRANSLATE_NOOP("GameList", "The game has not yet been tested.") } }, };
|
||||||
// clang-format on
|
// clang-format on
|
||||||
|
|
||||||
class GameListItem : public QStandardItem {
|
class GameListItem : public QStandardItem {
|
||||||
|
@ -157,8 +157,8 @@ public:
|
||||||
}
|
}
|
||||||
CompatStatus status = iterator->second;
|
CompatStatus status = iterator->second;
|
||||||
setData(compatiblity, CompatNumberRole);
|
setData(compatiblity, CompatNumberRole);
|
||||||
setText(status.text);
|
setText(QCoreApplication::translate("GameList", status.text));
|
||||||
setToolTip(status.tooltip);
|
setToolTip(QCoreApplication::translate("GameList", status.tooltip));
|
||||||
setData(CreateCirclePixmapFromColor(status.color), Qt::DecorationRole);
|
setData(CreateCirclePixmapFromColor(status.color), Qt::DecorationRole);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue