some file renaming and code tweaks