Fixed warnings and removed deprecations following Apples latest standards.