1
Instrumentation m_Instrumentation = new Instrumentation();
m_Instrumentation.sendPointerSync(MotionEvent.obtain(
SystemClock.uptimeMillis()+555,
SystemClock.uptimeMillis()+600,
MotionEvent.ACTION_UP,500,1000, 0));
我想嘗試開發使用Android Studio的TeamViewer模擬器。雖然顯示的應用程序的UI,我想用sendPointerSync方法而應用程序是在後臺這段代碼工作得很好,它給我的留言:簽署Android Studio項目apk作爲系統應用使用權限INJECT_EVENTS
java.lang.SecurityException: Injecting to another application requires INJECT_EVENTS permission
我添加權限,它給人的消息:
Permissions with the protection level signature or signatureOrSystem are only granted to system apps. If an app is a regular non-system app, it will never be able to use these permissions.
我該如何將應用程序簽名爲系統應用程序?