0
我想要一个UIButton这样工作:首先点击它,运行start_method;点击它,运行stop_method;点击它再次运行start_method;第四次点击它,再次运行stop_method。这样一个循环。如何在一个UIButton中实现Start和Stop动作?
当我设置按钮:
[button addTarget:self action:@selector(start_method:) forControlEvents:UIControlEventTouchDown];
[button addTarget:self action:@selector(stop_method:) forControlEvents:UIControlEventTouchDownRepeat];
对此的反应,只要你点击它两个动作。
有什么建议吗?
简单而漂亮。为什么我不这样想! – Maadiah 2012-07-24 03:00:16
我很乐意提供帮助!我希望你的应用程序做得很好! – portforwardpodcast 2012-07-24 08:37:02