Combine ResourceLoader::register() calls

Build an array of modules to register, then call register() once.

Change-Id: I2040ff12e2660260698bca783a7be50308687011