I am trying to make a simple change to the default behaviour of dijit/Dialog. I want the dialog to close when the underlay (background) is clicked.
I did this once on a previous incarnation of Dojo but am struggling to do it with the new AMD/requireJs style.
If I load the dijit/DialogUnderlay module when my application starts, I can monkey patch it but my changes only seem to affect the instance I have required, not all instances. Presumably require() only provides a copy.
Do I need to extend dijitDialog and use my child class? Is there a simpler way of doing what I want?