我正在使用iOS 7,我的推送通知不播放声音.
奇怪的是,我发现我的应用程序的首选项>通知中心没有声音设置.以下是我的应用程序通知中心的屏幕截图:

以下是Skype的内容:

你看,我的应用程序没有"声音"部分.
有人可以帮忙吗?
更新:
现在我在我的应用程序中注册了声音.通知中心现在看起来像:

我的通知有声音.看起来不错.
但是在我输入我的应用程序的设置后,最初有一个像"Skype"这样的"声音"部分,但随后Preference应用程序崩溃了,之后,没有更多的"声音",如下所示:

可能是苹果公司的一个漏洞?
您尚未在应用中注册音频推送通知.只需在App Delegate中注册即可:
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
//Whatever you have already in your app delegate...
// Let device know you're going to be sending one of these types of notifications.
[[UIApplication sharedApplication] registerForRemoteNotificationTypes:
(UIRemoteNotificationTypeBadge | UIRemoteNotificationTypeSound | UIRemoteNotificationTypeAlert)];
return YES;
}
Run Code Online (Sandbox Code Playgroud)
这5种类型是:
这是文档:注册远程通知
希望有所帮助!
| 归档时间: |
|
| 查看次数: |
7920 次 |
| 最近记录: |