accessibilityPerformEscape()
Dismisses a modal view and returns the success or failure of the action.
Declaration
@MainActor func accessibilityPerformEscape() -> BoolReturn Value
YES if the modal view is successfully dismissed; otherwise, NO. By default, this method returns NO.
Discussion
Implement this method on an element or containing view that can be revealed modally or in a hierarchy. When a VoiceOver user performs a dismiss action, this method dismisses the view. For example, you might implement this method for a popover in order to give users a deliberate dismiss action to perform that closes the popover.