| 24 | #include "base/Director.h" |
| 25 | |
| 26 | UILayer* UILayer::create() |
| 27 | { |
| 28 | UILayer* pRet = new UILayer(); |
| 29 | if (pRet->init()) |
| 30 | { |
| 31 | pRet->autorelease(); |
| 32 | return pRet; |
| 33 | } |
| 34 | else |
| 35 | { |
| 36 | delete pRet; |
| 37 | pRet = nullptr; |
| 38 | return nullptr; |
| 39 | } |
| 40 | } |
| 41 | |
| 42 | bool UILayer::init() |
| 43 | { |