Use File::LoadFile() instead of custom implementaions

This PR replace many file loading implementations with call of unified File::LoadFile().
Some of the replaced code parts are incorrect or have unchecked function calls.
Each file in the individual commit for easy revert.