isSpringLoaded
A Boolean value that indicates whether spring loading is enabled for the button.
Declaration
var isSpringLoaded: Bool { get set }Discussion
The value of this property is true if spring loading is enabled for the button, and false if it is not. The default is false.
On pressure-sensitive systems, such as systems with the Force Touch trackpad, spring loading is a feature that allows a user to activate a button by dragging selected items over it and force clicking—pressing harder—without dropping the selected items. The user can then continue dragging the items, possibly to perform additional actions.
A practical example of this feature can be found in the Calendar app. A selected calendar event can be dragged over the Calendars button in the toolbar. Force clicking on the button displays the calendar list without releasing the selected event. The event can then be dropped onto a calendar in the list, which assigns it to that calendar.
If spring loading is enabled on a button and a user drags items over it, the button highlights to indicate that it responds to force clicking. If the user presses harder, additional highlighting occurs to indicate that the button was fully activated.
On systems that don’t support pressure sensitivity, simply hovering over the button for a short period of time is sufficient to activate the button.