a bug in CCLayer?

a bug in CCLayer?
0.0 0


When any CCTouchDelegate is added, CCTouchDispatcher will retain it until it’s removed. While in CCLayer, once enable touch through setIsTouchEnable, it will add itself to the sharedDispatcher. So if it’s not set disable later, it will remain in the sharedDispatcher.
Is it better if add a remove operation in the CCLayer distructor ?
Please tell me if I got confused somewhere. Thank you very much!


The release functions are written in CCLayer::onExit().
Layer’s onExit will be called at scene transition or replaceScene();


so if we manually switch a layer in our scene before replaceScene or transition, we also have to disable touch manually right?