Implement new RequestHandler API
Merge pull request #512 from lucasr/request-handler

Support custom bitmap loading with a new RequestHandler API