Corrected all tests for the new event system.

- Also refactored android classes.