I\'m building a calculator app, when I tap on the buttons there is a short animation. The problem is the buttons do not respond while they are animating, which makes the app
Call different method of UIView:
func myButton () {
sender.layer.backgroundColor = firstColor
sender.setTitleColor(UIColor.white, for: UIControlState.normal)
UIView.animate(withDuration: 0.5,
delay: 0.0,
options: .allowUserInteraction,
animations: {
sender.layer.backgroundColor = secondColor },
completion: nil)
}