SwiftUI โฉ Gestures โฉ GestureState
@GestureState will reset to the original value when the gesture ends.
@GestureState
Since @GestureState property will reset itself, we need another @State property to save the final state.
@State
Long Press
Drag
long press + drag - use custom enum for its gesture state.
Paul โฉ What is the @GestureState property wrapper? - mentioned "transaction".
NSScreencast โฉ SwiftUI Gestures
SwiftUI โฉ Gestures โฉ GestureState (struct)
is Property Wrappers.
used by Long Press, Drag.
Last updated 2 years ago