Class

UIRefreshControl

A UIRefreshControl object provides a standard control that can be used to initiate the refreshing of a table view’s contents. You link a refresh control to a table through an associated table view controller object. The table view controller handles the work of adding the control to the table’s visual appearance and managing the display of that control in response to appropriate user gestures.

Overview

In addition to assigning a refresh control to a table view controller’s refreshControl property, you must configure the target and action of the control itself. The control does not initiate the refresh operation directly. Instead, it sends the valueChanged event when a refresh operation should occur. You must assign an action method to this event and use it to perform whatever actions are needed.

The UITableViewController object that owns a refresh control is also responsible for setting that control’s frame rectangle. Thus, you do not need to manage the size or position of a refresh control directly in your view hierarchy.

For information about basic view behaviors, see View Programming Guide for iOS.

Symbols

Initializing a Refresh Control

init()

Initializes and returns a standard refresh control.

Accessing the Control Attributes

var tintColor: UIColor!

The tint color for the refresh control.

var attributedTitle: NSAttributedString?

The styled title text to display in the refresh control.

Managing the Refresh Status

func beginRefreshing()

Tells the control that a refresh operation was started programmatically.

func endRefreshing()

Tells the control that a refresh operation has ended.

var isRefreshing: Bool

A Boolean value indicating whether a refresh operation has been triggered and is in progress.

Relationships

Inherits From