You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
raise errror after touch click display screen on pc #2250
display screen is ok, but trying to control device from pc raise an error:
INFO: Renderer: direct3d
INFO: Initial texture: 2608x720
[server] ERROR: Could not invoke method
java.lang.NoSuchMethodException: injectInputEvent [class android.view.InputEvent, int]
at java.lang.Class.getMethod(Class.java:2068)
at java.lang.Class.getMethod(Class.java:1690)
at com.genymobile.scrcpy.wrappers.InputManager.getInjectInputEventMethod(InputManager.java:28)
at com.genymobile.scrcpy.wrappers.InputManager.injectInputEvent(InputManager.java:35)
at com.genymobile.scrcpy.Device.injectEvent(Device.java:169)
at com.genymobile.scrcpy.Device.injectEvent(Device.java:173)
at com.genymobile.scrcpy.Controller.injectTouch(Controller.java:215)
at com.genymobile.scrcpy.Controller.handleEvent(Controller.java:94)
at com.genymobile.scrcpy.Controller.control(Controller.java:71)
at com.genymobile.scrcpy.Server$2.run(Server.java:100)
at java.lang.Thread.run(Thread.java:764)
[server] ERROR: Could not invoke method
java.lang.NoSuchMethodException: injectInputEvent [class android.view.InputEvent, int]
at java.lang.Class.getMethod(Class.java:2068)
at java.lang.Class.getMethod(Class.java:1690)
at com.genymobile.scrcpy.wrappers.InputManager.getInjectInputEventMethod(InputManager.java:28)
at com.genymobile.scrcpy.wrappers.InputManager.injectInputEvent(InputManager.java:35)
at com.genymobile.scrcpy.Device.injectEvent(Device.java:169)
at com.genymobile.scrcpy.Device.injectEvent(Device.java:173)
at com.genymobile.scrcpy.Controller.injectTouch(Controller.java:215)
at com.genymobile.scrcpy.Controller.handleEvent(Controller.java:94)
at com.genymobile.scrcpy.Controller.control(Controller.java:71)
at com.genymobile.scrcpy.Server$2.run(Server.java:100)
at java.lang.Thread.run(Thread.java:764)
Activity
[-]raise errror after touch click display screen on [/-][+]raise errror after touch click display screen on pc[/+]rom1v commentedon Apr 13, 2021
Which device/system? The ROM changed this function so it differs from "standard" Android (AOSP).
Workaround for NoSuchMethodException: injectInputEvent (fixes Genymob…
thomasrebele commentedon Jan 15, 2022
I had the same problem with a Yotaphone 2 (YD201). It seems that the method has an additional parameter:
I couldn't find the meaning of the additional parameter. Passing 0 seems to work fine. Pull-request: #2946
Great project, it helps a lot to gain access to the phone after breaking the screen (replacing the "spider app" with a permanent black screen).
Fix NoSuchMethodException for injectInputEvent()
Fix NoSuchMethodException for injectInputEvent()
rom1v commentedon Apr 16, 2022
Please test #3190 :)
Fix NoSuchMethodException for injectInputEvent()