详解iOS App中UISwitch开关组件的基本创建及使用方法

2020-01-15 14:33:22王振洲

复制代码
switchView.tintColor = [UIColor purpleColor];
添加触发事件
复制代码
[switchView addTarget:self action:@selector(switchAction:) forControlEvents:UIControlEventValueChanged];

注:相关教程知识阅读请移步到IOS开发频道。