You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am developing something that requires a non-standard/generic gesture that covers multiple views. Think about something similar to a swipe-keyboard where each key is a sub-view. One touch down, a lot of finger movement, and. touch-up
I'm pretty confident I can make Pan Gesture at higher levels, and if I know where views are laid-out, I can manage it all in the gesture recognizer. I may do this if there's not a better way.
I'm hoping there's a way to have the main gesture handler delegate touch-events to the views/sub-components and they in turn might trigger events and/or state changes. The closest I have here is to create a gesture-subview-handler that maps to the each actual laid-out view (and know the layouts), and have event delegated to them if appropriate. This involves keep parallel heirarchies keeping them up-to-date with regards to layout. Not pretty in my book.
Is there a pattern or better approach to this that I'm missing?
Thanks
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I am developing something that requires a non-standard/generic gesture that covers multiple views. Think about something similar to a swipe-keyboard where each key is a sub-view. One touch down, a lot of finger movement, and. touch-up
I'm pretty confident I can make Pan Gesture at higher levels, and if I know where views are laid-out, I can manage it all in the gesture recognizer. I may do this if there's not a better way.
I'm hoping there's a way to have the main gesture handler delegate touch-events to the views/sub-components and they in turn might trigger events and/or state changes. The closest I have here is to create a gesture-subview-handler that maps to the each actual laid-out view (and know the layouts), and have event delegated to them if appropriate. This involves keep parallel heirarchies keeping them up-to-date with regards to layout. Not pretty in my book.
Is there a pattern or better approach to this that I'm missing?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions