Instance Method インスタンスメソッド

onExitCommand(perform:)

Sets up an action that triggers in response to receiving the exit command while the view has focus. ビューがフォーカスを持つ間に退出命令を受け取ることに答えて引き起こされるアクションを準備します。

Declaration 宣言

func onExitCommand(perform action: (() -> Void)?) -> some View

Discussion 議論

The user generates an exit command by pressing the Menu button on tvOS, or the escape key on macOS. ユーザは退出命令を、MenuボタンをtvOS上で、またはエスケープキーをmacOS上で押すことによって生成します。