toDialogFactory

Use the OverlayDialogFactory in environment to return the OverlayDialogFactory bound to the type of the receiving Overlay.

It is rare to call this method directly. Instead the most common path is to rely on the default container View bound to BodyAndOverlaysScreen. If you need to build your own replacement for that View, you should be able to delegate most of the work to LayeredDialogSessions, which will call this method for you. And see OverlayDialogFactoryFinder to change the default binding BodyAndOverlaysScreen to your custom View.