jsbindings/jscontroller-jsbindings.cpp
/**
 * @brief Callback invoked when an object of AAMP_JSController is finalized
 *
 * @param[in] thisObj JSObject being finalized
 */
@brief Callback invoked when an object of AAMP_JSController is finalized
@param[in] thisObj JSObject being finalized
@brief Callback invoked when an object of AAMP_JSController is finalized @param [ in ] thisObj JSObject being finalized
void AAMP_JSController_finalize(JSObjectRef thisObj)
{
	LOG("[AAMP_JSController] AAMP_finalize: object=%p\n", thisObj);
	AAMP_JSController *aampObj = (AAMP_JSController*) JSObjectGetPrivate(thisObj);
	if (aampObj == NULL)
		return;
	if (aampObj->_ctx != NULL)
	{
		if (aampObj->_listeners.size() > 0)
		{
			AAMP_JSEventListener::RemoveAllEventListener(aampObj);
		}
	}
	JSObjectSetPrivate(thisObj, NULL);
	delete aampObj;
}
void AAMP_JSController_finalize ( JSObjectRef thisObj ) { LOG ( " \n " , thisObj ) ; AAMP_JSController * aampObj = ( AAMP_JSController * ) JSObjectGetPrivate ( thisObj ) ; if ( aampObj == NULL ) return ; if ( aampObj -> _ctx != NULL ) { if ( aampObj -> _listeners . size ( ) > 0 ) { AAMP_JSEventListener :: RemoveAllEventListener ( aampObj ) ; } } JSObjectSetPrivate ( thisObj , NULL ) ; delete aampObj ; }
@brief Callback invoked when an object of AAMP_JSController is finalized
 @param[in] thisObj JSObject being finalized
@brief Callback invoked when an object of AAMP_JSController is finalized @param [ in ] thisObj JSObject being finalized