fix for dialogs with a custom view