1.7.10 Port

Initial port to 1.7.10, Project wide code cleanup and auto-formatting.