Refactor settings and add constants
Load settings from mainpage
Some preliminar work towards oauth