PullRefreshView
@MainActor
open class PullRefreshView : UIView
下拉刷新视图,默认高度60。如果indicatorView为自定义指示器时会自动隐藏标题和箭头,仅显示指示器视图
-
全局高度设置
Declaration
Swift
@MainActor public static var height: CGFloat
-
当前高度,默认全局高度
Declaration
Swift
@MainActor open var height: CGFloat { get set }
-
原始边距
Declaration
Swift
@MainActor open var originalInset: UIEdgeInsets
-
箭头颜色
Declaration
Swift
@MainActor open var arrowColor: UIColor? { get set }
-
文本颜色
Declaration
Swift
@MainActor open var textColor: UIColor? { get set }
-
指示器颜色
Declaration
Swift
@MainActor open var indicatorColor: UIColor? { get set }
-
指示器偏移
Declaration
Swift
@MainActor open var indicatorPadding: CGFloat { get set }
-
是否显示标题文本
Declaration
Swift
@MainActor open var showsTitleLabel: Bool { get set }
-
是否显示箭头视图
Declaration
Swift
@MainActor open var showsArrowView: Bool { get set }
-
是否改变透明度,默认true
Declaration
Swift
@MainActor open var shouldChangeAlpha: Bool
-
是否是用户触发
Declaration
Swift
@MainActor open var userTriggered: Bool
-
自定义状态改变句柄
Declaration
Swift
@MainActor open var stateBlock: ((_ view: PullRefreshView, _ state: PullRefreshState) -> Void)?
-
自定义进度句柄
Declaration
Swift
@MainActor open var progressBlock: ((_ view: PullRefreshView, _ progress: CGFloat) -> Void)?
-
自定义下拉刷新句柄
Declaration
Swift
@MainActor open var pullRefreshBlock: (() -> Void)?
-
自定义下拉刷新目标和动作
Declaration
Swift
@MainActor open weak var target: AnyObject?
-
Undocumented
Declaration
Swift
@MainActor open var action: Selector?
-
绑定滚动视图
Declaration
Swift
@MainActor open weak var scrollView: UIScrollView?
-
是否已监听
Declaration
Swift
@MainActor open var isObserving: Bool
-
下拉刷新状态
Declaration
Swift
@MainActor open var state: PullRefreshState { get set }
-
标题文本
Declaration
Swift
@MainActor open lazy var titleLabel: UILabel { get set }
-
副标题文本
Declaration
Swift
@MainActor open lazy var subtitleLabel: UILabel { get set }
-
指示器视图
Declaration
Swift
@MainActor open lazy var indicatorView: UIView & IndicatorViewPlugin { get set }
-
Undocumented
Declaration
Swift
@MainActor override public init(frame: CGRect)
-
Undocumented
Declaration
Swift
@MainActor public required init?(coder: NSCoder)
-
Undocumented
Declaration
Swift
@MainActor override open func willMove(toSuperview newSuperview: UIView?)
-
Undocumented
Declaration
Swift
@MainActor override open func layoutSubviews()
-
Undocumented
Declaration
Swift
override open func observeValue(forKeyPath keyPath: String?, of object: Any?, change: [NSKeyValueChangeKey : Any]?, context: UnsafeMutableRawPointer?)
-
拖动手势状态监听回调方法
Declaration
Swift
@objc @MainActor open func gestureRecognizerStateChanged(_ gestureRecognizer: UIPanGestureRecognizer)
-
重置滚动视图contentInset
Declaration
Swift
@MainActor open func resetScrollViewContentInset(animated: Bool = true)
-
自定义各状态的标题
Declaration
Swift
@MainActor open func setTitle(_ title: String?, for state: PullRefreshState)
-
自定义各状态的副标题
Declaration
Swift
@MainActor open func setSubtitle(_ subtitle: String?, for state: PullRefreshState)
-
自定义各状态的视图
Declaration
Swift
@MainActor open func setCustomView(_ view: UIView?, for state: PullRefreshState)
-
自定义动画视图,自动绑定下拉刷新动画
Declaration
Swift
@MainActor open func setAnimationView(_ animationView: UIView & ProgressViewPlugin & IndicatorViewPlugin)
-
开始加载动画
Declaration
Swift
@MainActor open func startAnimating()
-
停止加载动画
Declaration
Swift
@MainActor open func stopAnimating()
-
是否正在执行动画
Declaration
Swift
@MainActor open var isAnimating: Bool { get }