收藏
回答

iOS手机,小程序背景音乐下拉状态栏,音乐就暂停了?只有苹果手机有问题

下面是app.js设置的背景音乐

createBgm() {
    this.globalData.bgrAudioContext = wx.createInnerAudioContext();
    this.globalData.bgrAudioContext.autoplay = true;
    this.globalData.bgrAudioContext.src = this.globalData.bgm_src;
    this.globalData.bgrAudioContext.loop = true;
    this.globalData.bgrAudioContext.play();
    this.globalData.bg_is_play = true;
  },
回答关注问题邀请回答
收藏

2 个回答

登录 后发表内容
问题标签