Fixed 'all' auto profile assignment. More checks for unsaved profiles. Altered condition variable regarding distance events. Related to issue #68.