This enables the guards placed in `padeditor.disable` to work. On `window.unload` the pad's connection would get closed which would lead to the editor becomming disabled. If the editor had already been `disposed` then the call to `disable` would raise the exception:
`Uncaught TypeError: Cannot call method 'ace_setProperty' of null`
Create a lazily-defined local reference for pad on initialization in each pad module in order to avoid circular dependency. At some point in the future this dependency should instead be injected into each module on initialization.