Elaborated loading of file in chunks; fixed up callbacks