Cleanup

Mot much to say, this patch does some cleanup like fixing spelling, enforcing coding standards, changing usage of deprecated methods/properties, etc...