func addTapForView() ->(Observable<UITapGestureRecognizer>){
let ges = UITapGestureRecognizer()
self.addGestureRecognizer(ges)
return ges.rx.event.throttle(1.5, latest: true, scheduler: MainScheduler.instance)
}
使用RXSwift为UIView的Extension添加点击事件,并设置在短时间内防重复点击的效果。