mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2025-05-28 04:40:20 +02:00
Update launcher/ui/themes/CatPack.cpp
Co-authored-by: TheKodeToad <TheKodeToad@proton.me> Signed-off-by: Alexandru Ionut Tripon <alexandru.tripon97@gmail.com>
This commit is contained in:
parent
bb9df1684b
commit
e4306d5cb6
@ -132,7 +132,7 @@ QString JsonCatPack::path(QDate now)
|
||||
auto files = QDir(m_default_path).entryInfoList(supportedImageFormats, QDir::Files, QDir::Name);
|
||||
if (files.length() == 0)
|
||||
return "";
|
||||
auto idx = now.dayOfYear() % files.length();
|
||||
auto idx = (now.dayOfYear() - 1) % files.length();
|
||||
auto isRandom = dInfo.fileName().compare("random", Qt::CaseInsensitive) == 0;
|
||||
if (isRandom)
|
||||
idx = QRandomGenerator::global()->bounded(0, files.length());
|
||||
|
Loading…
x
Reference in New Issue
Block a user