Skip to content

Commit 5732511

Browse files
committed
oh this is much better
1 parent 41fcac8 commit 5732511

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/MiniTreasureRoom.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ void MiniTreasureRoom::show() {
4949
setPosition({0, dir->getWinSize().height + 5});
5050
this->setVisible(true);
5151
if (auto pl = CCScene::get()->getChildByType<PauseLayer*>(0)) {
52-
CCTouchDispatcher::get()->findHandler(pl)->setPriority(-501);
52+
CCTouchDispatcher::get()->setPriority(-501, pl);
5353
}
5454
stopAllActions();
5555
runAction(CCEaseBounceOut::create(CCMoveTo::create(0.5, {0, 0})));
@@ -63,7 +63,7 @@ void MiniTreasureRoom::onBack(CCObject* sender) {
6363
stopAllActions();
6464
runAction(CCSequence::createWithTwoActions(CCMoveTo::create(0.3, {0, CCDirector::sharedDirector()->getWinSize().height + 5}), CCCallFunc::create(this, callfunc_selector(MiniTreasureRoom::transitionFinished))));
6565
if (auto pl = CCScene::get()->getChildByType<PauseLayer*>(0)) {
66-
CCTouchDispatcher::get()->findHandler(pl)->setPriority(-502);
66+
CCTouchDispatcher::get()->setPriority(-502, pl);
6767
}
6868
}
6969
bool MiniTreasureRoom::ccTouchBegan(CCTouch* touch, CCEvent* event) {

0 commit comments

Comments
 (0)