add GraphicsServices private framework into IOS

二次信任 提交于 2019-12-22 12:41:45

问题


actually I need to lock my iPhone programmatically, I have searched in the internet, also got some ideas, that is, using GraphicsServices.framework and GSEventLockDevices() method.. here is the thing: how can I add a private framework to my project? I knew it's jailbreaking, but no problem.

Could anyone help me to add a private framework to Xcode and lock the device programmatically?


回答1:


If you missed to import certain framework means, you may get like this kind of error.. When I met like this kind of problem, i have followed this way..

1) Select the project in the project navigation window which will show project summary on right

2) Select 4th tab build phases

3) Select Link binary with library option

4) Add framework for which you are getting

5) Move the framework from main folder to the frameworks folder

6) Build it again and errors are gone.

Hope this helps :)




回答2:


Check out the private framework headers: https://github.com/rpetrich/iphoneheaders

First copy a Private Frameworks Your Project. and add a #import "GSEvent.h"

GSEvent Header already in your project. So, as a relative path must be



来源:https://stackoverflow.com/questions/11771948/add-graphicsservices-private-framework-into-ios

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!