Controller/Dialog/Modal: allow extension of promiseGenerator

promiseGenerator is a good enough concept to let subclasses extend. This
way the downstream can offer a different Modal.init experience without
much work.
Controller/Dialog/Modal: tests for the static init
Merge pull request #59 from Aintaer/modal-generator

Controller/Dialog/Modal: allow extension of promiseGenerator