Modified to work in xcode project.
Cleanup & Refactor
Settings change