EventObject* ProgressEventObject::Clone(EventObject*pObj) { if (NULL == pObj) { ClassClosure *pClass = toplevel()->getBuiltinExtensionClass(abcclass_flash_events_ProgressEvent); pObj = (EventObject *)pClass->createInstance(pClass->ivtable(), pClass->prototype); } register ProgressEventObject *pEvent = (ProgressEventObject *)pObj; pEvent->m_bytesLoaded = m_bytesLoaded; pEvent->m_bytesToal = m_bytesToal; return EventObject::Clone(pObj); }
EventObject* FocusEventObject::Clone(EventObject*pObj) { if (NULL == pObj) { ClassClosure *pClass = toplevel()->getBuiltinExtensionClass(abcclass_flash_events_FocusEvent); pObj = (EventObject *)pClass->createInstance(pClass->ivtable(), pClass->prototype); } register FocusEventObject *pEvent = (FocusEventObject *)pObj; pEvent->m_pRelatedObject = m_pRelatedObject; pEvent->m_shiftKey = m_shiftKey; pEvent->m_keyCode = m_keyCode; return EventObject::Clone(pObj); }
EventObject* KeyboardEventObject::Clone(EventObject*pObj) { if (NULL == pObj) { ClassClosure *pClass = toplevel()->getBuiltinExtensionClass(abcclass_flash_events_KeyboardEvent); pObj = (EventObject *)pClass->createInstance(pClass->ivtable(), pClass->prototype); } register KeyboardEventObject *pEvent = (KeyboardEventObject *)pObj; pEvent->m_charCode = m_charCode; pEvent->m_keyCode = m_keyCode; pEvent->m_keyLocation = m_keyLocation; pEvent->m_ctrlKey = m_ctrlKey; pEvent->m_altKey = m_altKey; pEvent->m_shiftKey = m_shiftKey; return EventObject::Clone(pObj); }