Beispiel #1
0
EditBox::~EditBox(void)
{
    CC_SAFE_DELETE(_editBoxImpl);
#if CC_ENABLE_SCRIPT_BINDING
    unregisterScriptEditBoxHandler();
#endif
}
Beispiel #2
0
void CCEditBox::registerScriptEditBoxHandler(int handler)
{
    unregisterScriptEditBoxHandler();
    if (m_pEditBoxImpl)
    {
        m_pEditBoxImpl->registerScriptEditBoxHandler(handler);
    }
}
CCEditBox::~CCEditBox() {
    // unregister self
    for(std::vector<CCEditBox*>::iterator iter = sActiveEditBoxes->begin(); iter != sActiveEditBoxes->end(); iter++) {
        if(*iter == this) {
            sActiveEditBoxes->erase(iter);
            break;
        }
    }
    
    // release others
    CC_SAFE_DELETE(m_pEditBoxImpl);
    unregisterScriptEditBoxHandler();
}
Beispiel #4
0
CCEditBox::~CCEditBox(void)
{
    CC_SAFE_DELETE(m_pEditBoxImpl);
    unregisterScriptEditBoxHandler();
}
void CCEditBox::registerScriptEditBoxHandler(ccScriptFunction handler)
{
    unregisterScriptEditBoxHandler();
    m_nScriptEditBoxHandler = handler;
}
Beispiel #6
0
void EditBox::registerScriptEditBoxHandler(int handler)
{
    unregisterScriptEditBoxHandler();
    _scriptEditBoxHandler = handler;
}
Beispiel #7
0
void CCEditBox::registerScriptEditBoxHandler(int handler)
{
    unregisterScriptEditBoxHandler();
    m_nScriptEditBoxHandler = handler;
}