jjochen / JJFloatingActionButton

Floating Action Button for iOS
https://jjochen.github.io/JJFloatingActionButton
MIT License
374 stars 75 forks source link

Press-and-hold ability #266

Closed austboston closed 9 months ago

austboston commented 4 years ago

This is awesome, thanks for sharing! Is there someway to have the button perform an action when simply tapped, but open the menu when it is tapped and held? Similar to the floating button on Twitter. Any ideas? Thanks! Austin Blake

jjochen commented 4 years ago

you could remove the tap action

actionButton.removeTarget(actionButton, action: nil, for: .touchUpInside)

and handle the opening and closing of the button yourself.

jjochen commented 9 months ago

Hope that helped. Closing this for now.