Adding a Symbolic Link in the Application Bundle

前端 未结 2 2052
隐瞒了意图╮
隐瞒了意图╮ 2020-12-11 21:02

Apple specifies in the UILocalNotification class reference that the audio file must be from the application bundle. However, some smart geek has found his way a

2条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-11 21:26

    If you place a symlink to ../../Documents/blabla.caf inside a folder, and then add the folder to the project (making sure that you have "Create folder references..." set on import instead of "Create groups...") then Xcode won't try to resolve the link during the build process.

    I've verified that the link itself works fine in the app, though I'm not sure off the top of my head if UILocalNotification will accept folder/blabla.caf in its soundName property.

提交回复
热议问题