방송 음소거 상태 유지하기

    방송 음소거 상태 유지하기


    The content is currently unavailable in English. You are viewing the default Korean version.
    Article summary

    Shoplive Player Flutter SDK 에서 소리 상태를 유지 할 수 있습니다

    음소거 버튼 클릭 시 콜백

    Parameter name

    Type

    Description

    name

    String

    로그 이름 (예: "video_muted", "video_unmuted")

    feature

    String

    기능 이름

    campaignKey

    String

    캠페인 키

    payload

    Map<String, dynamic>

    추가 데이터

    import 'package:shoplive_player/shoplive_player.dart';
    bool isMuted = false;
    _shopLivePlayer.log.listen((data) {
      switch (data.name) {
        case "video_muted":
          isMuted = true;
          print("Video muted");
          break;
        case "video_unmuted":
          isMuted = false;
          print("Video unmuted");
          break;
      }
    });

    음소거 설정 상태를 Shoplive Player로 전달

    void setMuteWhenPlayStart({required bool isMute})를 통해 음소거 시작할 수 있습니다.

    late final _shopLivePlayerPlugin = ShopLivePlayer();
    _shopLivePlayerPlugin.setMuteWhenPlayStart(isMute: false);


    What's Next