Allow different controller formats

This change allows for the controller of the dialog to be specified inline similar to how this can be done when defining a new directive.