| 87 | } |
| 88 | |
| 89 | MaaCtrlId RemoteController::post_click(int x, int y, int contact, int pressure) |
| 90 | { |
| 91 | ControllerPostClickReverseRequest req { |
| 92 | .controller_id = controller_id_, |
| 93 | .x = x, |
| 94 | .y = y, |
| 95 | .contact = contact, |
| 96 | .pressure = pressure, |
| 97 | }; |
| 98 | auto resp_opt = server_.send_and_recv<ControllerPostClickReverseResponse>(req); |
| 99 | if (!resp_opt) { |
| 100 | return MaaInvalidId; |
| 101 | } |
| 102 | return resp_opt->ctrl_id; |
| 103 | } |
| 104 | |
| 105 | MaaCtrlId RemoteController::post_swipe(int x1, int y1, int x2, int y2, int duration, int contact, int pressure) |
| 106 | { |
no outgoing calls
no test coverage detected