addedd preference manager to process app settings