Fixed crash, moved program defs to seperate file

Fixed crash when loading application settings.
Moved program definitions to a separate file so resetting application
settings by deleting the file does not affect program definitions.