Skip to content

Commit

Permalink
backup
Browse files Browse the repository at this point in the history
Signed-off-by: Erymanthus[#5074] | (u/)RayDeeUx <[email protected]>
  • Loading branch information
RayDeeUx committed Aug 15, 2024
1 parent 8204944 commit 01303e2
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 12 deletions.
2 changes: 1 addition & 1 deletion src/MenuLayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class $modify(MenuLoopMLHook, MenuLayer) {

std::string notifString;
auto prefix = Mod::get()->getSettingValue<std::string>("customPrefix");
if (!prefix.empty() || prefix != "[Empty]")
if (prefix != "[Empty]")
notifString = fmt::format("{}: ", prefix);

if (Utils::getBool("useCustomSongs")) {
Expand Down
10 changes: 0 additions & 10 deletions src/Utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,6 @@ bool Utils::getBool(std::string setting) {
return geode::Mod::get()->getSettingValue<bool>(setting);
}

void Utils::keepCardAcrossScenes() {
if (const auto gm = GameManager::get()) {
if (const auto menuLayer = gm->m_menuLayer) {
if (const auto card = menuLayer->getChildByIDRecursive("now-playing"_spr)) {
geode::SceneManager::get()->keepAcrossScenes(card);
}
}
}
}

void Utils::removeCard() {
if (auto card = cocos2d::CCDirector::get()->getRunningScene()->getChildByIDRecursive("now-playing"_spr))
card->removeMeAndCleanup();
Expand Down
1 change: 0 additions & 1 deletion src/Utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ class Utils {
static int stoi(std::string);
static bool isSupportedExtension(std::string);
static bool getBool(std::string);
static void keepCardAcrossScenes();
static void removeCard();
static void setNewSong();
};

0 comments on commit 01303e2

Please sign in to comment.