Refactored to reduce functions in airwm.js (SRP)

Reduced the number of anonymous function, espcially where it did not
make sense to use anonymous functions. A lot of SRP refactoring.
Extracted eventMask. Fixed tabbing and spaces as metioned in gitter.

Signed-off-by: Martin Jorn Rogalla <martin@martinrogalla.com>
Merge pull request #31 from AirWM/refFunctionLength

Refactor: functions in airwm.js