Lesson1 - timer

2018-03-16  本文已影响10人  茗涙

效果图

QQ20180316-115847-HD.gif

项目代码地址

问题1:为button添加点击事件报错

playButton.addTarget(self, action: #selector(playButtonAction), for: UIControlEvents.touchUpInside)

func resetButtonAction() {
 }

错误提示
Argument of '#selector' refers to instance method 'playButtonAction()' that is not exposed to Objective-C
Add '@objc' to expose this instance method to Objective-C

@objc func resetButtonAction() {
 }

原因

这篇文章讲的还可以

上一篇下一篇

猜你喜欢

热点阅读