Split parsing of menus/config.txt to reduce duplicate code

As described here: https://github.com/clintbellanger/flare-engine/pull/1296#issuecomment-66765456