开发者

Using SystemSoundID in UIViewController without Application Delegate?

开发者 https://www.devze.com 2023-03-25 10:50 出处:网络
I ha开发者_运维问答ve an experimental app for iPad with a UIViewController visible on launch connected to my AppDelegate... all good, when I use systemSoundID within this MainViewcontroller it works g

I ha开发者_运维问答ve an experimental app for iPad with a UIViewController visible on launch connected to my AppDelegate... all good, when I use systemSoundID within this MainViewcontroller it works great however when I try to use systemSoundID in my 3 other ViewController classes, which are connected to my MainViewController but not to AppDelegate they don't work???

I dont understand the significance of the AppDelegate here??

Is there a way to make SystemSoundID work in my other ViewController classes?


Have you imported audiotoolbox header files in other 3 viewControllers. Try to import header files in other view controllers and then play systemSound.

0

精彩评论

暂无评论...
验证码 换一张
取 消