UIButton delayed state change

后端 未结 5 1741
庸人自扰
庸人自扰 2020-12-31 03:31

I have a UIButton subview inside of a UITableViewCell.

When this button is touched, the user must hold the button for about a half second f

5条回答
  •  梦谈多话
    2020-12-31 03:56

    I just change the image from within the target action method:

    [sender setBackgroundImage:[UIImage imageNamed:@"highlighted-image.png"] forState:UIControlStateNormal];
    

    It changes the background image instantly.

提交回复
热议问题