#NEWLINE# def dispatchEventImpl( event , element , listener ) : #NEWLINE# #INDENT# global sCaptureElem , currentEvent #NEWLINE# if ( element == sCaptureElem ) : #NEWLINE# #INDENT# if ( eventGetType ( event ) == 'losecapture' ) : #NEWLINE# #INDENT# sCaptureElem = None #NEWLINE# #UNINDENT# #UNINDENT# prevCurrentEvent = currentEvent #NEWLINE# currentEvent = event #NEWLINE# listener . onBrowserEvent ( event ) #NEWLINE# currentEvent = prevCurrentEvent