mpmedialibrary

Can I add a music library to the Xcode iOS Simulator?

一笑奈何 提交于 2019-11-30 11:44:20
I'm trying to create a music player for iPhone and iPad. I get it working perfectly on my iPhone and iPad because those actually have a music library. However I want to use fastlane and some other tools with tests so I need to be able to see/add a music library to my simulator as well. I've navigated to my emulator folder. /Users/maikohermans/Library/Developer/CoreSimulator/Devices/8A14CCDB../Data However I have no clue where to look and if I even should look here to add the music. I hope someone can help me out here on how to do this. I've searched this but it seems like nobody asked this

Request authorization to Media Library programmatically fails

一笑奈何 提交于 2019-11-30 09:37:20
iOS 10 now requires the user's permission to access the Media Library. We check if we have access to the Media Library before we use it, and if not we then use [MPMediaLibrary requestAuthorization: to request authorization again from the user. I'm expecting this to show the same popup request to access the Media Library that we get at app startup, but nothing happens. It is simply returning with the MPMediaLibraryAuthorizationStatusDenied status from before. The docs for requestAuthorization are incomplete at this time, so I can't tell if I'm just using this incorrectly, or there is something

Can I add a music library to the Xcode iOS Simulator?

末鹿安然 提交于 2019-11-29 17:31:11
问题 I'm trying to create a music player for iPhone and iPad. I get it working perfectly on my iPhone and iPad because those actually have a music library. However I want to use fastlane and some other tools with tests so I need to be able to see/add a music library to my simulator as well. I've navigated to my emulator folder. /Users/maikohermans/Library/Developer/CoreSimulator/Devices/8A14CCDB../Data However I have no clue where to look and if I even should look here to add the music. I hope

Request authorization to Media Library programmatically fails

余生长醉 提交于 2019-11-29 14:29:29
问题 iOS 10 now requires the user's permission to access the Media Library. We check if we have access to the Media Library before we use it, and if not we then use [MPMediaLibrary requestAuthorization: to request authorization again from the user. I'm expecting this to show the same popup request to access the Media Library that we get at app startup, but nothing happens. It is simply returning with the MPMediaLibraryAuthorizationStatusDenied status from before. The docs for requestAuthorization

Can i access iPod Library on simulator?

≡放荡痞女 提交于 2019-11-28 08:32:36
I am trying some code to open the iPod Library using the simulator but the app crashes with this error: MPMediaLibrary: Unable to launch iPod library server: application not found Do I need an actual iPhone to test this code? Yes you need to test on a device to access the media library. JosephH I've had some success using MPMediaLibrary / MPMediaQuery on the simulator (not playing music, but at least able to query for items) and xcode 4.6.3 I used iFunBox to copy these files from my device: 'Raw File System'/iTunes_Control/iTunes/MediaLibrary.sqlitedb 'Raw File System'/iTunes_Control/iTunes

Can i access iPod Library on simulator?

北城余情 提交于 2019-11-27 02:18:14
问题 I am trying some code to open the iPod Library using the simulator but the app crashes with this error: MPMediaLibrary: Unable to launch iPod library server: application not found Do I need an actual iPhone to test this code? 回答1: Yes you need to test on a device to access the media library. 回答2: I've had some success using MPMediaLibrary / MPMediaQuery on the simulator (not playing music, but at least able to query for items) and xcode 4.6.3 I used iFunBox to copy these files from my device: