Skip to content

Commit 48328f9

Browse files
committed
?
1 parent 530e074 commit 48328f9

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ui/MLRSongCell.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,10 @@ bool MLRSongCell::init(const SongData& songData, const bool isEven, const bool i
7676
cocos2d::CCLabelBMFont* extraInfoLabl = nullptr;
7777
if (Utils::getBool("showExtraInfoLabel")) {
7878
extraInfoLabl = cocos2d::CCLabelBMFont::create("PLACEHOLDER SO NOTHING CRASHES", "chatFont.fnt");
79-
extraInfoLabl->setString(fmt::format("{} | {} sec | {} MB", songData.fileExtension, songData.songLength / 1000, songData.songFileSize / 1000).c_str());
79+
extraInfoLabl->setString(fmt::format("{} | {:.2f} sec | {:.2f} MB", songData.fileExtension, songData.songLength / 1000000.f, songData.songFileSize / 1000000.f).c_str());
8080
extraInfoLabl->setAnchorPoint({.0f, .5f});
81-
extraInfoLabl->setPosition({songNameLabel->getPositionX() + songNameLabel->getContentWidth() + 2.5f, (this->getContentHeight() / 2.f) + 1.f});
81+
extraInfoLabl->setPosition({songNameLabel->getPositionX() + songNameLabel->getScaledContentWidth() + 2.5f, (this->getContentHeight() / 2.f) + 1.f});
82+
extraInfoLabl->limitLabelWidth(356.f * (.5 / compactModeFactor), std::clamp<float>((.75f / compactModeFactor), .3, .75), .001f);
8283
}
8384

8485
CCLayerColor* divider = CCLayerColor::create({0, 0, 0, 127}, 356.f, .5f);

0 commit comments

Comments
 (0)