解析推送通知的自定义声音播放默认的声音

解析推送通知的自定义声音播放默认的声音

本文介绍了解析推送通知的自定义声音播放默认的声音的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我发送解析推送通知该应用程序接收,但要求不播放声音,而不是默认的声音播放。声音已被保存在文件夹中的应用程序。我可以检查在iTunes它们的存在。在某些时候,这是工作,但由于某种原因停止播放请求的声音。如果我记录推送通知用户信息字典中的声音名称是正确的有:

I send a parse push notification which the app receives, but the sound requested does not play, instead the default sound plays. The sounds have been saved by the app in the documents folder. I can check in iTunes that they are there. At some point this was working, but for some reason it has stopped playing the requested sounds. If I log the push notification user info dictionary the sound name is correctly there:

2015-01-11 12:17:41.356 My App[239:60b] didReceiveRemoteNotification, userInfo: {
    aps =     {
        alert = "XXX says FOO from the console!";
        sound = "w8nmridutW_v1.mp3";
    };
}

任何想法?

推荐答案

有可能不支持您所使用的音频格式。当时它时,它正在一个不同的文件?
请与苹果文档。

It is possible that the audio format that you use is not supported. Was it a different file when it was working ?Check with the apple documentation.

这篇关于解析推送通知的自定义声音播放默认的声音的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-02 15:02