license export function eventTargetPatch ( _global , api ) { if ( ( Zone as any ) [ api . symbol ( 'patchEventTarget' ) ] ) { return ; } const { eventNames , zoneSymbolEventNames , TRUE_STR , FALSE_STR , ZONE_SYMBOL_PREFIX } = api . getGlobalObjects ( ) ! ; for ( let i = 0 ; i < eventNames . length ; i ++ ) { const eventName = eventNames [ i ] ; const falseEventName = eventName + FALSE_STR ; const trueEventName = eventName + TRUE_STR ; const symbol = ZONE_SYMBOL_PREFIX + falseEventName ; const symbolCapture = ZONE_SYMBOL_PREFIX + trueEventName ; zoneSymbolEventNames [ eventName ] = { } ; zoneSymbolEventNames [ eventName ] [ FALSE_STR ] = symbol ; zoneSymbolEventNames [ eventName ] [ TRUE_STR ] = symbolCapture ; } const EVENT_TARGET = _global [ 'EventTarget' ] ; if ( ! EVENT_TARGET || ! EVENT_TARGET . prototype ) { return ; } api . patchEventTarget ( _global , [ EVENT_TARGET && EVENT_TARGET . prototype ] ) ; return true ; } export function patchEvent ( global , api ) { api . patchEventPrototype ( global , api ) ; }