Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the localizations #1099

Merged
merged 2 commits into from
Dec 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lang
Submodule lang updated 1 files
+35 −33 pegasus_ja.ts
2 changes: 1 addition & 1 deletion src/backend/providers/pegasus_favorites/Favorites.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Favorites::Favorites(QObject* parent)
{}

Favorites::Favorites(QString db_path, QObject* parent)
: Provider(QLatin1String("pegasus_favorites"), QStringLiteral("Favorites"), PROVIDER_FLAG_INTERNAL | PROVIDER_FLAG_HIDE_PROGRESS, parent)
: Provider(QLatin1String("pegasus_favorites"), QStringLiteral("Pegasus Favorites"), PROVIDER_FLAG_INTERNAL | PROVIDER_FLAG_HIDE_PROGRESS, parent)
, m_db_path(std::move(db_path))
{}

Expand Down
2 changes: 1 addition & 1 deletion src/backend/providers/pegasus_media/MediaProvider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ namespace providers {
namespace media {

MediaProvider::MediaProvider(QObject* parent)
: Provider(QLatin1String("pegasus_media"), QStringLiteral("Media"), parent)
: Provider(QLatin1String("pegasus_media"), QStringLiteral("Pegasus Media"), parent)
{}

Provider& MediaProvider::run(SearchContext& sctx)
Expand Down
2 changes: 1 addition & 1 deletion src/backend/providers/pegasus_metadata/PegasusProvider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ namespace providers {
namespace pegasus {

PegasusProvider::PegasusProvider(QObject* parent)
: Provider(QLatin1String("pegasus_metafiles"), QStringLiteral("Metafiles"), PROVIDER_FLAG_INTERNAL, parent)
: Provider(QLatin1String("pegasus_metafiles"), QStringLiteral("Pegasus Metafiles"), PROVIDER_FLAG_INTERNAL, parent)
{}

Provider& PegasusProvider::run(SearchContext& sctx)
Expand Down
2 changes: 1 addition & 1 deletion src/backend/providers/pegasus_playtime/PlaytimeStats.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ PlaytimeStats::PlaytimeStats(QObject* parent)
{}

PlaytimeStats::PlaytimeStats(QString db_path, QObject* parent)
: Provider(QLatin1String("pegasus_playtime"), QStringLiteral("Playtime"), PROVIDER_FLAG_INTERNAL | PROVIDER_FLAG_HIDE_PROGRESS, parent)
: Provider(QLatin1String("pegasus_playtime"), QStringLiteral("Pegasus Playtime"), PROVIDER_FLAG_INTERNAL | PROVIDER_FLAG_HIDE_PROGRESS, parent)
, m_db_path(std::move(db_path))
{}

Expand Down
44 changes: 22 additions & 22 deletions tests/backend/providers/pegasus/test_PegasusProvider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ private slots:

void test_PegasusProvider::empty()
{
QTest::ignoreMessage(QtInfoMsg, "Metafiles: No metadata files found");
QTest::ignoreMessage(QtInfoMsg, "Pegasus Metafiles: No metadata files found");

providers::SearchContext sctx({ QStringLiteral(":/empty") });
providers::pegasus::PegasusProvider().run(sctx);
Expand All @@ -149,7 +149,7 @@ void test_PegasusProvider::empty()

void test_PegasusProvider::simple()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/simple/metadata.pegasus.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/simple/metadata.pegasus.txt"));

providers::SearchContext sctx({QStringLiteral(":/simple")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -194,13 +194,13 @@ void test_PegasusProvider::simple()

void test_PegasusProvider::with_meta()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Metafiles: `%1`, line 62: Duplicate file entry detected: `horse.ext`", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Metafiles: `%1`, line 65: Failed to parse the rating value", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Metafiles: `%1`, line 67: Incorrect date format, should be YYYY, YYYY-MM or YYYY-MM-DD", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Metafiles: `%1`, line 68: Incorrect date format, should be YYYY, YYYY-MM or YYYY-MM-DD", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Metafiles: `%1`, line 70: Duplicate file entry detected: `horse.ext`", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Metafiles: `%1`, line 71: Unrecognized game property `asd`, ignored", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Pegasus Metafiles: `%1`, line 62: Duplicate file entry detected: `horse.ext`", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Pegasus Metafiles: `%1`, line 65: Failed to parse the rating value", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Pegasus Metafiles: `%1`, line 67: Incorrect date format, should be YYYY, YYYY-MM or YYYY-MM-DD", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Pegasus Metafiles: `%1`, line 68: Incorrect date format, should be YYYY, YYYY-MM or YYYY-MM-DD", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Pegasus Metafiles: `%1`, line 70: Duplicate file entry detected: `horse.ext`", ":/with_meta/metadata.pegasus.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG("Pegasus Metafiles: `%1`, line 71: Unrecognized game property `asd`, ignored", ":/with_meta/metadata.pegasus.txt"));

providers::SearchContext sctx({QStringLiteral(":/with_meta")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -331,7 +331,7 @@ void test_PegasusProvider::with_meta()

void test_PegasusProvider::custom_assets()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/custom_assets/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/custom_assets/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/custom_assets")});
providers::pegasus::PegasusProvider().run(sctx);
Expand All @@ -348,7 +348,7 @@ void test_PegasusProvider::custom_assets()

void test_PegasusProvider::custom_assets_multi()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/custom_assets_multi/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/custom_assets_multi/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/custom_assets_multi")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -378,7 +378,7 @@ void test_PegasusProvider::custom_assets_multi()

void test_PegasusProvider::custom_directories()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/custom_dirs/coll/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/custom_dirs/coll/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/custom_dirs/coll")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -407,7 +407,7 @@ void test_PegasusProvider::custom_directories()

void test_PegasusProvider::multifile()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/multifile/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/multifile/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/multifile")});
providers::pegasus::PegasusProvider().run(sctx);
Expand All @@ -425,9 +425,9 @@ void test_PegasusProvider::multifile()

void test_PegasusProvider::multicoll()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/multicoll/c1/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/multicoll/c2/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/multicoll/games/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/multicoll/c1/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/multicoll/c2/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/multicoll/games/metadata.txt"));

providers::SearchContext sctx({
QStringLiteral(":/multicoll/c1"),
Expand Down Expand Up @@ -514,7 +514,7 @@ void test_PegasusProvider::nonASCII()
}


const QString ignored_msg = QStringLiteral("Metafiles: Found `%1`")
const QString ignored_msg = QStringLiteral("Pegasus Metafiles: Found `%1`")
.arg(QDir::toNativeSeparators(tempdir.path() + QStringLiteral("/metadata.txt")));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(ignored_msg));

Expand Down Expand Up @@ -553,7 +553,7 @@ void test_PegasusProvider::nonASCII()

void test_PegasusProvider::relative_files_only()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/relative_files/coll/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/relative_files/coll/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/relative_files/coll")});
providers::pegasus::PegasusProvider().run(sctx);
Expand All @@ -575,7 +575,7 @@ void test_PegasusProvider::relative_files_only()

void test_PegasusProvider::relative_files_with_dirs()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/relative_files_with_dirs/coll/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/relative_files_with_dirs/coll/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/relative_files_with_dirs/coll")});
providers::pegasus::PegasusProvider().run(sctx);
Expand All @@ -596,7 +596,7 @@ void test_PegasusProvider::relative_files_with_dirs()

void test_PegasusProvider::autoparenting()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/autoparenting/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/autoparenting/metadata.txt"));

providers::SearchContext sctx({QStringLiteral(":/autoparenting")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -642,8 +642,8 @@ void test_PegasusProvider::autoparenting()

void test_PegasusProvider::entryless_games()
{
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Metafiles: Found `%1`", ":/entryless/metadata.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG2("Metafiles: `%1`, line 5: Game file `%2` doesn't seem to exist", ":/entryless/metadata.txt", ":/entryless/test.ext"));
QTest::ignoreMessage(QtInfoMsg, PATHMSG("Pegasus Metafiles: Found `%1`", ":/entryless/metadata.txt"));
QTest::ignoreMessage(QtWarningMsg, PATHMSG2("Pegasus Metafiles: `%1`, line 5: Game file `%2` doesn't seem to exist", ":/entryless/metadata.txt", ":/entryless/test.ext"));
QTest::ignoreMessage(QtWarningMsg, "The collection 'My Games' has no valid games, ignored");

providers::SearchContext sctx({QStringLiteral(":/entryless")});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ private slots:
void test_PegasusMediaProvider::asset_search()
{
const QString display_path = QDir::toNativeSeparators(QStringLiteral(":/asset_search/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Metafiles: Found `%1`").arg(display_path)));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Pegasus Metafiles: Found `%1`").arg(display_path)));

providers::SearchContext sctx({QStringLiteral(":/asset_search")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -127,7 +127,7 @@ void test_PegasusMediaProvider::asset_search()
void test_PegasusMediaProvider::asset_search_by_title()
{
const QString display_path = QDir::toNativeSeparators(QStringLiteral(":/asset_search_by_title/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Metafiles: Found `%1`").arg(display_path)));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Pegasus Metafiles: Found `%1`").arg(display_path)));

providers::SearchContext sctx({QStringLiteral(":/asset_search_by_title")});
providers::pegasus::PegasusProvider().run(sctx);
Expand All @@ -152,7 +152,7 @@ void test_PegasusMediaProvider::asset_search_by_title()
void test_PegasusMediaProvider::asset_search_multifile()
{
const QString display_path = QDir::toNativeSeparators(QStringLiteral(":/asset_search_multifile/metadata.txt"));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Metafiles: Found `%1`").arg(display_path)));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Pegasus Metafiles: Found `%1`").arg(display_path)));

providers::SearchContext sctx({QStringLiteral(":/asset_search_multifile")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down Expand Up @@ -185,7 +185,7 @@ void test_PegasusMediaProvider::separate_media_dirs()
// NOTE: see issue 407

const QString display_path = QDir::toNativeSeparators(QStringLiteral(":/separate_media_dirs/metadata/metadata.pegasus.txt"));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Metafiles: Found `%1`").arg(display_path)));
QTest::ignoreMessage(QtInfoMsg, qUtf8Printable(QStringLiteral("Pegasus Metafiles: Found `%1`").arg(display_path)));

providers::SearchContext sctx({QStringLiteral(":/separate_media_dirs/metadata")});
providers::pegasus::PegasusProvider().run(sctx);
Expand Down
4 changes: 2 additions & 2 deletions tests/benchmarks/pegasus_provider/bench_PegasusProvider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ void bench_PegasusProvider::find_in_empty_dir()
providers::pegasus::PegasusProvider provider;

QBENCHMARK {
QTest::ignoreMessage(QtInfoMsg, "Metafiles: No metadata files found");
QTest::ignoreMessage(QtInfoMsg, "Pegasus Metafiles: No metadata files found");
provider.run(sctx);
}
}
Expand All @@ -52,7 +52,7 @@ void bench_PegasusProvider::find_in_filled_dir()
providers::SearchContext sctx({QStringLiteral(":/filled")});
providers::pegasus::PegasusProvider provider;

const QString msg = QStringLiteral("Metafiles: Found `%1`")
const QString msg = QStringLiteral("Pegasus Metafiles: Found `%1`")
.arg(QDir::toNativeSeparators(QStringLiteral(":/filled/metadata.pegasus.txt")));

QBENCHMARK {
Expand Down