I just want to push the button inside the popup

I just want to push the button inside the popup.

and other question

all button ignore or block?

plz…

I solved it this way.

and other question

all button ignore or block?

plz…

Easiest way I think is to setTouchEnabled(false) for node of your popup.

cocos creator 2.0 version?

can’t find setTouchEnabled()

try
(the node you want to disable).getComponent(cc.Button).interactable = false

I just found a way on how disable all the buttons behind the popup (since I was also working on this). All you have to do is to add a node with BlockInputEvents component under the pop-up node.

Yeah. You can create a node that fills all screen and put in a layer behind the popup with zIndex, then i recomend make an static function to access to this node and play with activate and desactivate.
The node must have an script that takes the events and stop the propagation

try
https://docs.cocos.com/creator/manual/en/components/block-input-events.html

add a BlockInputEvents component to the popup

2 Likes

Just add button component to pink box, when someone clicks in any area of pink it will stop propagating the click event to the nodes under it, thus buttons under it will not respond…