isCancel property

bool isCancel
final

Marks the action as the cancel button.

Maps to UIAlertAction.Style.cancel, which UIKit positions itself regardless of where the action sits in the list.

At most one action in a call may set this: UIKit raises NSInternalInconsistencyException when a second .cancel action is added, which is a crash, not a layout quirk.

Unlike a plain dismissal, a cancel action still reports its value — an alert cannot be dismissed by tapping outside, so pressing cancel is a deliberate answer and the caller is told about it.

Implementation

final bool isCancel;