Skip to content

RtkAudioButtonControlBar

Last updated View as MarkdownAgent setup

A control bar button that toggles the local microphone on and off. Checks microphone permissions before toggling.

Initializer parameters

Parameter Type Required Default Description
meeting RealtimeKitClient - The RealtimeKit client instance
onClick ((RtkAudioButtonControlBar) -> Void)? nil Closure called when the button is tapped
appearance RtkControlBarButtonAppearance - Appearance configuration for the button

Usage Examples

Basic Usage

import RealtimeKitUI

let audioButton = RtkAudioButtonControlBar(meeting: rtkClient)
view.addSubview(audioButton)

With tap handler

import RealtimeKitUI

let audioButton = RtkAudioButtonControlBar(
    meeting: rtkClient,
    onClick: { button in
        print("Audio toggled")
    }
)
view.addSubview(audioButton)

Was this helpful?