Cleanup the preferences window

Simplifies some code and removes many widgets