rotateDigitalCrown(delta:velocity:)
Simulates the user rotating the Digital Crown on an Apple Watch by the delta amount and speed you provide.
Declaration
func rotateDigitalCrown(delta rotationalDelta: CGFloat, velocity: XCUIGestureVelocity)Parameters
- rotationalDelta:
A float value that indicates the fraction of a full rotation of the Digital Crown.
- velocity:
A value that represents how fast to rotate the Digital Crown, in rotations per second.
Discussion
Provide a positive value for rotationalDelta to indicate scrolling upward or a negative value to indicate scrolling downward, regardless of the orientation of the watch. A rotationalDelta value of 1.0 indicates a full rotation of the Digital Crown. Specify a velocity in rotations per second; the system ignores the sign of the velocity you provide.