Repository navigation
Conversation
iOS recognises its system edge gestures from an edge flag on the touch, not from its position. FBSimulatorControl can set that flag, but HIDTouch and HIDSwipe carried only points, so no client could reach it. Both gain an optional `edge`, defaulting to NO_EDGE, carried through the companion and the Python client; `idb ui swipe` gains `--edge`.
|
Hi @ArloL! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks! |
Motivation
iOS recognises its system edge gestures (home, Notification Centre, back) from an edge flag on the touch, not from its position. FBSimulatorControl can set that flag since f04de8f and ede9a6a ("the CLI command follows"). But
HIDTouchandHIDSwipecarry only points, so no client can trigger these gestures. That rules out, for example, testing what an app does when the user swipes home mid-gesture.This adds an optional
edgetoHIDTouchandHIDSwipe, carried through the companion and the Python client, plusidb ui swipe --edge {top,left,bottom,right}. It defaults toNO_EDGE, so older clients and companions are unaffected.Test Plan
./build.sh buildsucceeds. The newHidRequestTranslationTestscases haven't run: I found no public target that buildsCompanionTests.idb ui swipe 201 873 201 437is a drag inside the app, and adding--edge bottomgoes to the home screen. A Python stream ofHIDTouch(…, edge=HIDEdge.BOTTOM)touches goes home too.Docs:
website/docs/idb/ui.mdx.