cocos3.10 ccui.layout/ccui.button 如何设置touch priority

local node = display.newLayer()
local tmp = ccui.Layout:create():addTo(node):onTouch(function() print(“111111”) end)
node:registerScriptTouchHandler(function() return true end,false, -1, true)
node:setTouchEnabled(false)
cc.Director:getInstance():setNotificationNode(node)

这样可以虽然可以避免场景上的按钮响应touch事件,但是如果tmp对象同样也不能影响touch事件了

看了下ccui.layout也不能设置touchpriority,这样的话,如果想要让他响应事件需要怎么处理?

为什么每次提问都要自己来答

暂时用cc.EventListenerTouchOneByOne来处理了
反正也就只有简单的弹窗,不会有复杂的东西,所以暂时是够用了