fix(on): assign handler function to variable

Eliminate anonymity of handler function by assigning it to variable.
chore(on): fix indentation
feat(dispose): provide dispose function to delete all MTObjects

This function destroys all MTObjects and all event listeners