Skip to content

Commit a896053

Browse files
committed
fix(dialogs): ios fix rollback
1 parent c08f387 commit a896053

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

src/dialogs/dialogs.ios.ts

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -251,14 +251,13 @@ function createAlertController(options: DialogOptions & MDCAlertControlerOptions
251251
alertController.accessoryView = createUIViewAutoSizeUIViewAutoSize(view);
252252

253253
// if no title or message disable contentInsets to be like android
254-
// TODO: do we really need this? need to find an exact usecase
255-
// if (!options.title && !options.message) {
256-
// if (alertController.view) {
257-
// (alertController.view as MDCAlertControllerView).contentInsets = UIEdgeInsetsZero;
258-
// } else {
259-
// alertController._disableContentInsets = true;
260-
// }
261-
// }
254+
if (!options.title && !options.message) {
255+
if (alertController.view) {
256+
(alertController.view as MDCAlertControllerView).contentInsets = UIEdgeInsetsZero;
257+
} else {
258+
alertController._disableContentInsets = true;
259+
}
260+
}
262261
view.viewController = alertController; // needed to prevent a crash in layoutChild
263262
}
264263
const dialogPresentationControllerDelegate = MDCDialogPresentationControllerDelegateImpl.initWithCallback(() => {

0 commit comments

Comments
 (0)