more tidy up
move more stuff out of legacy files and to where they should be