cocos2d/cocos2d-x — pull request #4427 by stubma (2013-12-04 04:16:08+00:00)
Title: reimplement CCLayerMultiplex to avoid potential memory leak

reimplement CCLayerMultiplex. Original code use addChild/removeChild to switch layer, but it has potential risk of leaking memory because onExit of sublayer may be lost. The new implementation controls visibility of every child layer, more safe than old implementation.