From 5b30230e1808c48b8b9c51295b599b8bbf8fff57 Mon Sep 17 00:00:00 2001 From: xfg <853299701@qq.com> Date: Mon, 29 Jun 2020 09:09:01 +0800 Subject: [PATCH] 2.3.2 --- FWSegmentedControl.podspec | 2 +- FWSegmentedControl/FWSegmentedControl.swift | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/FWSegmentedControl.podspec b/FWSegmentedControl.podspec index a4415a1..fbb366e 100644 --- a/FWSegmentedControl.podspec +++ b/FWSegmentedControl.podspec @@ -16,7 +16,7 @@ Pod::Spec.new do |s| # s.name = "FWSegmentedControl" - s.version = "2.3.1" + s.version = "2.3.2" s.summary = "滑动分段控制,多样式、灵活、便利是其最大的优势。" # This description is used to generate tags and improve search results. diff --git a/FWSegmentedControl/FWSegmentedControl.swift b/FWSegmentedControl/FWSegmentedControl.swift index 6ebdafb..a4ce383 100644 --- a/FWSegmentedControl/FWSegmentedControl.swift +++ b/FWSegmentedControl/FWSegmentedControl.swift @@ -123,10 +123,10 @@ public struct SCBorderType : OptionSet { static var right = SCBorderType(rawValue: 1 << 4) } -/// 滑动或者选中回调 +/// 选中下标改变时的回调 public typealias SCIndexChangeBlock = (_ index: Int) -> Void -/// 已经选中了某个index后再次点击的回调 -public typealias SCIndexSecondClickedBlock = (_ index: Int) -> Void +/// 点击某Item的回调 +public typealias SCIndexClickedBlock = (_ index: Int) -> Void /// 标题NSAttributedString回调 public typealias SCTitleFormatterBlock = (_ segmentedControl: FWSegmentedControl, _ title: String, _ index: Int, _ selected: Bool) -> NSAttributedString @@ -250,8 +250,8 @@ open class FWSegmentedControl: UIControl { /// 滑动或者选中回调 @objc public var indexChangeBlock: SCIndexChangeBlock? - /// 已经选中了某个index后再次点击的回调 - @objc public var indexSecondClickedBlock: SCIndexSecondClickedBlock? + /// 已经选中了某个Item后,再次点击该Item的回调 + @objc public var indexSecondClickedBlock: SCIndexClickedBlock? /// 标题NSAttributedString回调 @objc public var titleFormatterBlock: SCTitleFormatterBlock? @@ -677,7 +677,7 @@ extension FWSegmentedControl { /// - Parameter index: 对应下标 /// - Parameter animated: 是否需要动画 @objc open func setSelectedSegmentIndex(index: Int, animated: Bool) { - self.setSelectedSegmentIndex(index: index, animated: animated, notify: true) + self.setSelectedSegmentIndex(index: index, animated: animated, notify: false) } fileprivate func setSelectedSegmentIndex(index: Int, animated: Bool, notify: Bool) {