[SwiftUI] Simultaneous Gesture

RudinP·2025년 8월 22일
0

Study

목록 보기
345/352

두 제스처를 동시에 실행하기

  • gesture 모디파이어를 두 개 연달아 사용시 기본적으로 먼저 작성한 제스처가 먼저 인식됨.

simultaneously(with:)

  • 동시에 인식 가능
.gesture(rotation.gesture.simultaneously(with: magnification.gesture))  
  • 동일하게 속성으로 빼도 무방하다.
    var gestures: some Gesture {
        SimultaneousGesture(rotation.gesture, magnification.gesture)
    }
profile
iOS 개발자가 되기 위한 스터디룸...

0개의 댓글