Skip to content

非公式 / UnofficialCloudflare, Inc. 非提携。アカウント情報は入力しないでください。Not affiliated with Cloudflare, Inc. Do not enter Cloudflare credentials here.Official docsこのサイトについてプライバシー

RtkEndMeetingControlBarButton

最終更新 Markdown で表示Agent セットアップ

ミーティングを終了する、または退出するコントロールバーボタンです。 終了前に、確認ダイアログを表示することもできます。

イニシャライザーのパラメーター

パラメーター 型 必須 デフォルト 説明
meeting RealtimeKitClient ✅ - RealtimeKit クライアントのインスタンス
alertViewController UIViewController ✅ - 確認アラートの表示に使うビューコントローラー
onClick ((RtkEndMeetingControlBarButton, RtkLeaveDialog.RtkLeaveDialogAlertButtonType) -> Void)? ❌ nil ユーザーが退出または終了を確定したあとに呼ばれるクロージャーです。ボタンと選択したアクションの種類を受け取ります
appearance RtkControlBarButtonAppearance ❌ - ボタンの外観設定

プロパティ

プロパティ 型 必須 デフォルト 説明
shouldShowAlertOnClick Bool ❌ true ミーティング終了前に確認アラートを表示するかどうか

使用例

基本的な使い方

import RealtimeKitUI

let endButton = RtkEndMeetingControlBarButton(
    meeting: rtkClient,
    alertViewController: self
)
view.addSubview(endButton)

確認ダイアログなし

import RealtimeKitUI

let endButton = RtkEndMeetingControlBarButton(
    meeting: rtkClient,
    alertViewController: self,
    onClick: { button, actionType in
        print("Action: \(actionType)")
    }
)
endButton.shouldShowAlertOnClick = false
view.addSubview(endButton)

役に立ちましたか?